From: abhilash.kv@ti.com (Abhilash K V)
To: linux-arm-kernel@lists.infradead.org
Subject: [PATCH 4/4] AM3517: Fix suspend-resume sequence
Date: Fri, 19 Aug 2011 17:25:27 +0530 [thread overview]
Message-ID: <1313754927-11992-5-git-send-email-abhilash.kv@ti.com> (raw)
In-Reply-To: <1313754927-11992-4-git-send-email-abhilash.kv@ti.com>
This patch fixes the crash seen while resuming with i2c devices
enabled. This crash was happening because the interface-clocks
were disabled in the suspend sequence, and not re-enabled on
resumption.
The current patch saves the value of the CM_ICLKEN1_CORE register
before zeroing it out, and restores upon resumption. In AM3517 the
interface clocks are enabled by the clock module ONLY during
initialization, so the suspend sequence (in arch/arm/mach-omap2/
sleep3517.S) has to manually turn it off before executing wfi
and then back on again on returning from wfi, to ensure that all
interface clocks are enabled when control returns to omap_sram_idle()
after waking up from idle.
Reviewed-by: Vaibhav Hiremath <hvaibhav@ti.com>
Reviewed-by: Sanjeev Premi <premi@ti.com>
Signed-off-by: Abhilash K V <abhilash.kv@ti.com>
---
arch/arm/mach-omap2/sleep3517.S | 5 ++++-
1 files changed, 4 insertions(+), 1 deletions(-)
diff --git a/arch/arm/mach-omap2/sleep3517.S b/arch/arm/mach-omap2/sleep3517.S
index 3fceefc..070a943 100644
--- a/arch/arm/mach-omap2/sleep3517.S
+++ b/arch/arm/mach-omap2/sleep3517.S
@@ -55,6 +55,9 @@ loop:
/* Disable SDRC and Control Module */
ldr r4, cm_iclken1_core
+ ldr r5, [r4]
+ str r5, iclk_core_enable
+ ldr r4, cm_iclken1_core
ldr r5, clk_core_disable
str r5, [r4]
wait_sdrc_ok:
@@ -108,7 +111,7 @@ wait_sdrc_ok:
clk_core_disable:
.word 0x0
iclk_core_enable:
- .word 0x42
+ .word 0x0
emif_phy_gate:
.word 0x2620
emif_phy_enable:
--
1.7.1
next prev parent reply other threads:[~2011-08-19 11:55 UTC|newest]
Thread overview: 13+ messages / expand[flat|nested] mbox.gz Atom feed top
2011-08-19 11:55 [PATCH 0/4] AM3517: Adding support for suspend/resume Abhilash K V
2011-08-19 11:55 ` [PATCH 1/4] AM3517 : " Abhilash K V
2011-08-19 11:55 ` [PATCH 2/4] AM3517: Add armv7-a flag for sleepam3517.S Abhilash K V
2011-08-19 11:55 ` [PATCH 3/4] pm34xx: Warning FIX related to ambiguous else loop Abhilash K V
2011-08-19 11:55 ` Abhilash K V [this message]
2011-08-19 19:53 ` [PATCH 4/4] AM3517: Fix suspend-resume sequence Russell King - ARM Linux
2011-08-30 23:00 ` [PATCH 3/4] pm34xx: Warning FIX related to ambiguous else loop Kevin Hilman
2011-08-19 19:56 ` [PATCH 1/4] AM3517 : support for suspend/resume Russell King - ARM Linux
2011-08-30 22:58 ` Kevin Hilman
2011-09-13 11:31 ` Koyamangalath, Abhilash
2011-09-13 18:24 ` Kevin Hilman
2011-09-14 13:00 ` Koyamangalath, Abhilash
2011-09-15 17:09 ` Kevin Hilman
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=1313754927-11992-5-git-send-email-abhilash.kv@ti.com \
--to=abhilash.kv@ti.com \
--cc=linux-arm-kernel@lists.infradead.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).