From patchwork Thu Nov 12 17:02:37 2009 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Tero Kristo X-Patchwork-Id: 59598 X-Patchwork-Delegate: khilman@deeprootsystems.com Received: from vger.kernel.org (vger.kernel.org [209.132.176.167]) by demeter.kernel.org (8.14.2/8.14.2) with ESMTP id nACHL8MW004172 for ; Thu, 12 Nov 2009 17:21:08 GMT Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1753765AbZKLRUA (ORCPT ); Thu, 12 Nov 2009 12:20:00 -0500 Received: (majordomo@vger.kernel.org) by vger.kernel.org id S1753551AbZKLRT7 (ORCPT ); Thu, 12 Nov 2009 12:19:59 -0500 Received: from smtp.nokia.com ([192.100.105.134]:43788 "EHLO mgw-mx09.nokia.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1753756AbZKLRT5 (ORCPT ); Thu, 12 Nov 2009 12:19:57 -0500 Received: from vaebh106.NOE.Nokia.com (vaebh106.europe.nokia.com [10.160.244.32]) by mgw-mx09.nokia.com (Switch-3.3.3/Switch-3.3.3) with ESMTP id nACHJuDQ026523; Thu, 12 Nov 2009 11:19:59 -0600 Received: from esebh102.NOE.Nokia.com ([172.21.138.183]) by vaebh106.NOE.Nokia.com with Microsoft SMTPSVC(6.0.3790.3959); Thu, 12 Nov 2009 19:19:57 +0200 Received: from mgw-sa01.ext.nokia.com ([147.243.1.47]) by esebh102.NOE.Nokia.com over TLS secured channel with Microsoft SMTPSVC(6.0.3790.3959); Thu, 12 Nov 2009 19:19:57 +0200 Received: from localhost.localdomain (sokoban.ntc.nokia.com [172.22.144.95]) by mgw-sa01.ext.nokia.com (Switch-3.3.3/Switch-3.3.3) with ESMTP id nACHJoNb020986; Thu, 12 Nov 2009 19:19:55 +0200 From: Tero Kristo To: linux-omap@vger.kernel.org Cc: khilman@deeprootsystems.com Subject: [PATCH 4/6] OMAP3: PM: Removed PER + CORE state hacking from omap_sram_idle Date: Thu, 12 Nov 2009 19:02:37 +0200 Message-Id: <1258045359-7962-5-git-send-email-tero.kristo@nokia.com> X-Mailer: git-send-email 1.5.4.3 In-Reply-To: <1258045359-7962-4-git-send-email-tero.kristo@nokia.com> References: <> <1258045359-7962-1-git-send-email-tero.kristo@nokia.com> <1258045359-7962-2-git-send-email-tero.kristo@nokia.com> <1258045359-7962-3-git-send-email-tero.kristo@nokia.com> <1258045359-7962-4-git-send-email-tero.kristo@nokia.com> X-OriginalArrivalTime: 12 Nov 2009 17:19:57.0218 (UTC) FILETIME=[5B6A6020:01CA63BC] X-Nokia-AV: Clean Sender: linux-omap-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-omap@vger.kernel.org diff --git a/arch/arm/mach-omap2/pm34xx.c b/arch/arm/mach-omap2/pm34xx.c index 7b52f30..c704756 100644 --- a/arch/arm/mach-omap2/pm34xx.c +++ b/arch/arm/mach-omap2/pm34xx.c @@ -81,7 +81,6 @@ static int (*_omap_save_secure_sram)(u32 *addr); static struct powerdomain *mpu_pwrdm, *neon_pwrdm; static struct powerdomain *core_pwrdm, *per_pwrdm; -static struct powerdomain *cam_pwrdm; static struct prm_setup_times_vc prm_setup_times_default = { .clksetup = 0xff, @@ -370,7 +369,6 @@ void omap_sram_idle(void) int core_next_state = PWRDM_POWER_ON; int core_prev_state, per_prev_state; u32 sdrc_pwr = 0; - int per_state_modified = 0; if (!_omap_sram_idle) return; @@ -409,19 +407,10 @@ void omap_sram_idle(void) if (per_next_state < PWRDM_POWER_ON) { omap_uart_prepare_idle(2); omap2_gpio_prepare_for_idle(per_next_state); - if (per_next_state == PWRDM_POWER_OFF) { - if (core_next_state == PWRDM_POWER_ON) { - per_next_state = PWRDM_POWER_RET; - pwrdm_set_next_pwrst(per_pwrdm, per_next_state); - per_state_modified = 1; - } else - omap3_per_save_context(); - } + if (per_next_state == PWRDM_POWER_OFF) + omap3_per_save_context(); } - if (pwrdm_read_pwrst(cam_pwrdm) == PWRDM_POWER_ON) - omap2_clkdm_deny_idle(mpu_pwrdm->pwrdm_clkdms[0]); - /* * Disable smartreflex before entering WFI. * Only needed if we are going to enter retention or off. @@ -540,8 +529,6 @@ void omap_sram_idle(void) omap3_gpio_restore_pad_context(1); omap2_gpio_resume_after_idle(); omap_uart_resume_idle(2); - if (per_state_modified) - pwrdm_set_next_pwrst(per_pwrdm, PWRDM_POWER_OFF); } /* Disable IO-PAD and IO-CHAIN wakeup */ @@ -1170,7 +1157,6 @@ static int __init omap3_pm_init(void) neon_pwrdm = pwrdm_lookup("neon_pwrdm"); per_pwrdm = pwrdm_lookup("per_pwrdm"); core_pwrdm = pwrdm_lookup("core_pwrdm"); - cam_pwrdm = pwrdm_lookup("cam_pwrdm"); omap_push_sram_idle(); #ifdef CONFIG_SUSPEND