Message ID | 1308732405-16664-7-git-send-email-kgene.kim@samsung.com (mailing list archive) |
---|---|
State | New, archived |
Headers | show |
On Wed, Jun 22, 2011 at 05:46:44PM +0900, Kukjin Kim wrote: > From: Jaecheol Lee <jc.lee@samsung.com> > > This patch adds save/restore for Power Control Register and > Diagnostic Register. NAK. Please see my further suspend consolidation patches posted earlier. I've also recently (last few days) moved these further forward and this code no longer exists in this file (all it contains is the early resume stuff.) My guess is that these two registers are samsung specific, and so they should be saved and restored by higher level code (eg, a syscore_ops for exynos4 specific stuff.)
Russell King - ARM Linux wrote: > > On Wed, Jun 22, 2011 at 05:46:44PM +0900, Kukjin Kim wrote: > > From: Jaecheol Lee <jc.lee@samsung.com> > > > > This patch adds save/restore for Power Control Register and > > Diagnostic Register. > > NAK. Please see my further suspend consolidation patches posted earlier. > I've also recently (last few days) moved these further forward and this > code no longer exists in this file (all it contains is the early > resume stuff.) > Oops :( OK, will re-work based on latest rmk/for-next :) > My guess is that these two registers are samsung specific, and so they > should be saved and restored by higher level code (eg, a syscore_ops > for exynos4 specific stuff.) Let me think again. Thanks. Best regards, Kgene. -- Kukjin Kim <kgene.kim@samsung.com>, Senior Engineer, SW Solution Development Team, Samsung Electronics Co., Ltd.
On Thu, Jun 23, 2011 at 03:39:02PM +0900, Kukjin Kim wrote: > Russell King - ARM Linux wrote: > > > > On Wed, Jun 22, 2011 at 05:46:44PM +0900, Kukjin Kim wrote: > > > From: Jaecheol Lee <jc.lee@samsung.com> > > > > > > This patch adds save/restore for Power Control Register and > > > Diagnostic Register. > > > > NAK. Please see my further suspend consolidation patches posted earlier. > > I've also recently (last few days) moved these further forward and this > > code no longer exists in this file (all it contains is the early > > resume stuff.) > > > Oops :( > OK, will re-work based on latest rmk/for-next :) The entire series is not in for-next yet, it's still being worked on. That's why I posted the patches again yesterday.
Russell King - ARM Linux wrote: > > On Thu, Jun 23, 2011 at 03:39:02PM +0900, Kukjin Kim wrote: > > Russell King - ARM Linux wrote: > > > > > Oops :( > > OK, will re-work based on latest rmk/for-next :) > > The entire series is not in for-next yet, it's still being worked on. > That's why I posted the patches again yesterday. OK, first of all, will test your yesterday patches on Samsung boards then will re-work this based on it. Thanks. Best regards, Kgene. -- Kukjin Kim <kgene.kim@samsung.com>, Senior Engineer, SW Solution Development Team, Samsung Electronics Co., Ltd.
diff --git a/arch/arm/mach-exynos4/sleep.S b/arch/arm/mach-exynos4/sleep.S index d55d38c..4fe13fc 100644 --- a/arch/arm/mach-exynos4/sleep.S +++ b/arch/arm/mach-exynos4/sleep.S @@ -42,6 +42,15 @@ ENTRY(s3c_cpu_save) stmfd sp!, { r3 - r12, lr } + + adr r0, sleep_save_misc + + mrc p15, 0, r2, c15, c0, 0 @ read power control register + str r2, [r0], #4 + + mrc p15, 0, r2, c15, c0, 1 @ read diagnostic register + str r2, [r0], #4 + ldr r3, =resume_with_mmu bl cpu_suspend @@ -56,6 +65,14 @@ ENTRY(s3c_cpu_save) b early_wakeup resume_with_mmu: + adr r0, sleep_save_misc + + ldr r1, [r0], #4 + mcr p15, 0, r1, c15, c0, 0 @ write power control register + + ldr r1, [r0], #4 + mcr p15, 0, r1, c15, c0, 1 @ write diagnostic register + mov r0, #1 early_wakeup: @@ -71,6 +88,11 @@ early_wakeup: .word 0x2bedf00d + /* To save more cpu register */ +sleep_save_misc: + .long 0 + .long 0 + /* * s3c_cpu_resume *