From patchwork Mon Nov 29 20:19:53 2010 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Nishanth Menon X-Patchwork-Id: 365262 X-Patchwork-Delegate: khilman@deeprootsystems.com Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by demeter1.kernel.org (8.14.4/8.14.3) with ESMTP id oATKK46L012363 for ; Mon, 29 Nov 2010 20:20:04 GMT Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1753354Ab0K2UUB (ORCPT ); Mon, 29 Nov 2010 15:20:01 -0500 Received: from bear.ext.ti.com ([192.94.94.41]:34784 "EHLO bear.ext.ti.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1753250Ab0K2UT4 (ORCPT ); Mon, 29 Nov 2010 15:19:56 -0500 Received: from dlep33.itg.ti.com ([157.170.170.112]) by bear.ext.ti.com (8.13.7/8.13.7) with ESMTP id oATKJtt8002538 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=NO); Mon, 29 Nov 2010 14:19:55 -0600 Received: from legion.dal.design.ti.com (localhost [127.0.0.1]) by dlep33.itg.ti.com (8.13.7/8.13.7) with ESMTP id oATKJsel007492; Mon, 29 Nov 2010 14:19:54 -0600 (CST) Received: from senorita (senorita.am.dhcp.ti.com [128.247.74.250]) by legion.dal.design.ti.com (8.11.7p1+Sun/8.11.7) with ESMTP id oATKJsf24549; Mon, 29 Nov 2010 14:19:54 -0600 (CST) Received: by senorita (Postfix, from userid 1000) id 9E97AC2AF; Mon, 29 Nov 2010 14:19:53 -0600 (CST) From: Nishanth Menon To: linux-omap Cc: Jean , Tony , Kevin , Vishwa Subject: [PATCH 5/5] OMAP3630: PM: Erratum i583: disable coreoff if < ES1.2 Date: Mon, 29 Nov 2010 14:19:53 -0600 Message-Id: <1291061993-4740-6-git-send-email-nm@ti.com> X-Mailer: git-send-email 1.6.3.3 In-Reply-To: <1291061993-4740-1-git-send-email-nm@ti.com> References: <1291061993-4740-1-git-send-email-nm@ti.com> Sender: linux-omap-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-omap@vger.kernel.org X-Greylist: IP, sender and recipient auto-whitelisted, not delayed by milter-greylist-4.2.3 (demeter1.kernel.org [140.211.167.41]); Mon, 29 Nov 2010 20:20:04 +0000 (UTC) diff --git a/arch/arm/mach-omap2/pm34xx.c b/arch/arm/mach-omap2/pm34xx.c index e0ade5f..6f33631 100644 --- a/arch/arm/mach-omap2/pm34xx.c +++ b/arch/arm/mach-omap2/pm34xx.c @@ -55,6 +55,7 @@ #define OMAP343X_CONTROL_REG_VALUE_OFFSET 0xc8 #define RTA_ERRATUM_i608 (1 << 0) +#define SDRC_WAKEUP_ERRATUM_i583 (1 << 1) static u16 pm34xx_errata; #define IS_PM34XX_ERRATUM(id) (pm34xx_errata & (id)) @@ -399,6 +400,17 @@ void omap_sram_idle(void) } /* CORE */ + /* + * Erratum i583: implementation for ES rev < Es1.2 on 3630 + * We cannot enable OFF mode in a stable form for previous + * revisions, transition instead to RET + */ + if (IS_PM34XX_ERRATUM(SDRC_WAKEUP_ERRATUM_i583) && + (core_next_state == PWRDM_POWER_OFF)) { + pwrdm_set_next_pwrst(core_pwrdm, PWRDM_POWER_RET); + core_next_state = PWRDM_POWER_RET; + } + if (core_next_state < PWRDM_POWER_ON) { omap_uart_prepare_idle(0); omap_uart_prepare_idle(1); @@ -991,6 +1003,8 @@ static void pm_errata_configure(void) /* Enable the l2 cache toggling in sleep logic */ if (cpu_is_omap3630()) enable_omap3630_toggle_l2_on_restore(); + if (cpu_is_omap3630() && (omap_rev() < OMAP3630_REV_ES1_2)) + pm34xx_errata |= SDRC_WAKEUP_ERRATUM_i583; } }