From patchwork Sat Jul 26 03:07:15 2014 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Shawn Guo X-Patchwork-Id: 4626671 Return-Path: X-Original-To: patchwork-linux-arm@patchwork.kernel.org Delivered-To: patchwork-parsemail@patchwork1.web.kernel.org Received: from mail.kernel.org (mail.kernel.org [198.145.19.201]) by patchwork1.web.kernel.org (Postfix) with ESMTP id 3C41A9F467 for ; Sat, 26 Jul 2014 03:10:48 +0000 (UTC) Received: from mail.kernel.org (localhost [127.0.0.1]) by mail.kernel.org (Postfix) with ESMTP id 568BE200F0 for ; Sat, 26 Jul 2014 03:10:47 +0000 (UTC) Received: from bombadil.infradead.org (bombadil.infradead.org [198.137.202.9]) (using TLSv1.2 with cipher DHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPS id 61CE7200ED for ; Sat, 26 Jul 2014 03:10:46 +0000 (UTC) Received: from localhost ([127.0.0.1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.80.1 #2 (Red Hat Linux)) id 1XAsLQ-0005xk-Qd; Sat, 26 Jul 2014 03:08:24 +0000 Received: from mail-bn1lp0145.outbound.protection.outlook.com ([207.46.163.145] helo=na01-bn1-obe.outbound.protection.outlook.com) by bombadil.infradead.org with esmtps (Exim 4.80.1 #2 (Red Hat Linux)) id 1XAsLO-0005vg-5l for linux-arm-kernel@lists.infradead.org; Sat, 26 Jul 2014 03:08:22 +0000 Received: from BN1PR0301MB0625.namprd03.prod.outlook.com (25.160.170.28) by BN1PR0301MB0772.namprd03.prod.outlook.com (25.160.78.153) with Microsoft SMTP Server (TLS) id 15.0.990.7; Sat, 26 Jul 2014 03:07:59 +0000 Received: from BN3PR0301CA0053.namprd03.prod.outlook.com (25.160.152.149) by BN1PR0301MB0625.namprd03.prod.outlook.com (25.160.170.28) with Microsoft SMTP Server (TLS) id 15.0.990.7; Sat, 26 Jul 2014 03:07:57 +0000 Received: from BY2FFO11FD001.protection.gbl (2a01:111:f400:7c0c::121) by BN3PR0301CA0053.outlook.office365.com (2a01:111:e400:401e::21) with Microsoft SMTP Server (TLS) id 15.0.995.14 via Frontend Transport; Sat, 26 Jul 2014 03:07:57 +0000 Received: from tx30smr01.am.freescale.net (192.88.168.50) by BY2FFO11FD001.mail.protection.outlook.com (10.1.14.123) with Microsoft SMTP Server (TLS) id 15.0.980.11 via Frontend Transport; Sat, 26 Jul 2014 03:07:56 +0000 Received: from dragon.ap.freescale.net ([10.192.185.114]) by tx30smr01.am.freescale.net (8.14.3/8.14.0) with ESMTP id s6Q37jMM005337; Fri, 25 Jul 2014 20:07:49 -0700 From: Shawn Guo To: Subject: [PATCH] ARM: imx: fix TLB missing of IOMUXC base address during suspend Date: Sat, 26 Jul 2014 11:07:15 +0800 Message-ID: <1406344035-7836-1-git-send-email-shawn.guo@freescale.com> X-Mailer: git-send-email 1.9.1 X-EOPAttributedMessage: 0 X-Forefront-Antispam-Report: CIP:192.88.168.50; CTRY:US; IPV:CAL; IPV:NLI; EFV:NLI; SFV:NSPM; SFS:(6009001)(189002)(199002)(83072002)(89996001)(21056001)(46102001)(26826002)(74662001)(44976005)(105606002)(85306003)(64706001)(86362001)(33646002)(110136001)(62966002)(48376002)(2351001)(95666004)(4396001)(107046002)(229853001)(104016003)(50466002)(79102001)(81542001)(36756003)(77156001)(83322001)(20776003)(47776003)(104166001)(85852003)(88136002)(76482001)(50986999)(99396002)(102836001)(97736001)(80022001)(50226001)(87286001)(19580395003)(31966008)(87936001)(93916002)(81342001)(6806004)(74502001)(106466001)(19580405001)(84676001)(68736004)(92726001)(77982001)(92566001); DIR:OUT; SFP:; SCL:1; SRVR:BN1PR0301MB0625; H:tx30smr01.am.freescale.net; FPR:; MLV:ovrnspm; PTR:InfoDomainNonexistent; MX:1; LANG:en; MIME-Version: 1.0 X-Microsoft-Antispam: BCL:0;PCL:0;RULEID: X-Forefront-PRVS: 02843AA9E0 Received-SPF: Fail (: domain of freescale.com does not designate 192.88.168.50 as permitted sender) receiver=; client-ip=192.88.168.50; helo=tx30smr01.am.freescale.net; Authentication-Results: spf=fail (sender IP is 192.88.168.50) smtp.mailfrom=Shawn.Guo@freescale.com; X-Microsoft-Antispam: BCL:0;PCL:0;RULEID: X-OriginatorOrg: freescale.com X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20140725_200822_357353_F6F7B1BB X-CRM114-Status: UNSURE ( 8.08 ) X-CRM114-Notice: Please train this message. X-Spam-Score: -0.0 (/) Cc: stable@vger.kernel.org, Anson Huang , Russell King , Shawn Guo , kernel@pengutronix.de X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.18-1 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+patchwork-linux-arm=patchwork.kernel.org@lists.infradead.org X-Spam-Status: No, score=-1.9 required=5.0 tests=BAYES_00,RP_MATCHES_RCVD, UNPARSEABLE_RELAY autolearn=unavailable version=3.3.1 X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on mail.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP After the suspend routine running in OCRAM puts DDR into self-refresh, it will access IOMUXC block to float DDR IO for power saving. A TLB missing of IOMUXC base address may happen in this case, and triggers an access to DDR, and thus hangs the system. The failure is discovered by running suspend/resume on a Cubox-i board. Though the issue is not Cubox-i specific, it can be hit the on the board quite easily with the 3.15 or 3.16 kernel. Fix the issue with a dummy access to IOMUXC block at the beginning of suspend routine, so that the address translation can be filled into TLB before DDR is put into self-refresh. Signed-off-by: Shawn Guo Cc: --- arch/arm/mach-imx/suspend-imx6.S | 2 ++ 1 file changed, 2 insertions(+) diff --git a/arch/arm/mach-imx/suspend-imx6.S b/arch/arm/mach-imx/suspend-imx6.S index fe123b079c05..87bdf7a629a5 100644 --- a/arch/arm/mach-imx/suspend-imx6.S +++ b/arch/arm/mach-imx/suspend-imx6.S @@ -172,6 +172,8 @@ ENTRY(imx6_suspend) ldr r6, [r11, #0x0] ldr r11, [r0, #PM_INFO_MX6Q_GPC_V_OFFSET] ldr r6, [r11, #0x0] + ldr r11, [r0, #PM_INFO_MX6Q_IOMUXC_V_OFFSET] + ldr r6, [r11, #0x0] /* use r11 to store the IO address */ ldr r11, [r0, #PM_INFO_MX6Q_SRC_V_OFFSET]