From: Kukjin Kim <kgene.kim@samsung.com>
To: 'Russell King - ARM Linux' <linux@arm.linux.org.uk>,
'Colin Cross' <ccross@google.com>
Cc: linux-omap@vger.kernel.org, 'Eric Miao' <eric.y.miao@gmail.com>,
linux-arm-kernel@lists.infradead.org
Subject: RE: [PATCH 2/6] ARM: pm: add generic CPU suspend/resume support
Date: Mon, 21 Feb 2011 18:58:25 +0900 [thread overview]
Message-ID: <000301cbd1ad$e67cb130$b3761390$%kim@samsung.com> (raw)
In-Reply-To: <20110220120039.GA14495@n2100.arm.linux.org.uk>
Russell King - ARM Linux wrote:
>
> Kukjin, could you test this update as well please?
>
No problem :)
It works fine with following.
Thanks.
Best regards,
Kgene.
--
Kukjin Kim <kgene.kim@samsung.com>, Senior Engineer,
SW Solution Development Team, Samsung Electronics Co., Ltd.
> Thanks.
>
> On Tue, Feb 15, 2011 at 11:04:53AM +0000, Russell King - ARM Linux wrote:
> > On Fri, Feb 11, 2011 at 06:50:57PM -0800, Colin Cross wrote:
> > > > +ENDPROC(cpu_resume_turn_mmu_on)
> > > > +cpu_resume_after_mmu:
> > > > + str r5, [r2, r4, lsl #2] @ restore old mapping
> > > > +#ifdef MULTI_CACHE
> > > > + ldr r10, =cpu_cache
> > > > + ldr pc, [r10, #CACHE_FLUSH_KERN_ALL]
> > > > +#else
> > > > + b __cpuc_flush_kern_all
> > > > +#endif
> >
> > I think we can eliminate this cache flush by delaying the cache enable
> > as below. Could you see whether Tegra 2 survives this please?
> > Thanks.
> >
> > diff --git a/arch/arm/kernel/sleep.S b/arch/arm/kernel/sleep.S
> > index bed1876..193be5f 100644
> > --- a/arch/arm/kernel/sleep.S
> > +++ b/arch/arm/kernel/sleep.S
> > @@ -4,6 +4,7 @@
> > #include <asm/assembler.h>
> > #include <asm/glue-cache.h>
> > #include <asm/glue-proc.h>
> > +#include <asm/system.h>
> > .text
> >
> > /*
> > @@ -81,25 +82,22 @@ ENTRY(cpu_resume_mmu)
> > str r3, [r2, r4, lsl #2] @ setup 1:1 mapping for mmu code
> > sub r2, r2, r1
> > ldr r3, =cpu_resume_after_mmu
> > + bic r1, r0, #CR_C @ ensure D-cache is disabled
> > b cpu_resume_turn_mmu_on
> > ENDPROC(cpu_resume_mmu)
> > .ltorg
> > .align 5
> > cpu_resume_turn_mmu_on:
> > - mcr p15, 0, r0, c1, c0, 0 @ turn on MMU, caches, etc
> > - mrc p15, 0, r0, c0, c0, 0 @ read id reg
> > - mov r0, r0
> > - mov r0, r0
> > + mcr p15, 0, r1, c1, c0, 0 @ turn on MMU, I-cache, etc
> > + mrc p15, 0, r1, c0, c0, 0 @ read id reg
> > + mov r1, r1
> > + mov r1, r1
> > mov pc, r3 @ jump to virtual address
> > ENDPROC(cpu_resume_turn_mmu_on)
> > cpu_resume_after_mmu:
> > str r5, [r2, r4, lsl #2] @ restore old mapping
> > -#ifdef MULTI_CACHE
> > - ldr r10, =cpu_cache
> > - ldr pc, [r10, #CACHE_FLUSH_KERN_ALL]
> > -#else
> > - b __cpuc_flush_kern_all
> > -#endif
> > + mcr p15, 0, r0, c1, c0, 0 @ turn on D-cache
> > + mov pc, lr
> >
> > /*
> > * Note: Yes, part of the following code is located into the .data
section.
--
To unsubscribe from this list: send the line "unsubscribe linux-omap" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
next prev parent reply other threads:[~2011-02-21 9:58 UTC|newest]
Thread overview: 30+ messages / expand[flat|nested] mbox.gz Atom feed top
2011-02-11 16:16 [PATCH] Generic CPU save/restore PM support Russell King - ARM Linux
2011-02-11 16:17 ` [PATCH 1/6] ARM: move cache/processor/fault glue to separate include files Russell King - ARM Linux
2011-02-12 2:52 ` Colin Cross
2011-02-12 9:48 ` Russell King - ARM Linux
2011-02-11 16:17 ` [PATCH 2/6] ARM: pm: add generic CPU suspend/resume support Russell King - ARM Linux
2011-02-12 2:50 ` Colin Cross
2011-02-15 11:04 ` Russell King - ARM Linux
2011-02-16 0:26 ` Colin Cross
2011-02-17 10:41 ` Lorenzo Pieralisi
2011-02-17 13:59 ` Russell King - ARM Linux
2011-02-17 20:05 ` Colin Cross
2011-02-17 23:36 ` Russell King - ARM Linux
2011-02-20 12:00 ` Russell King - ARM Linux
2011-02-21 9:58 ` Kukjin Kim [this message]
2011-02-15 1:21 ` Colin Cross
2011-02-15 4:11 ` Colin Cross
2011-02-15 10:50 ` Russell King - ARM Linux
2011-02-15 18:20 ` Colin Cross
2011-02-11 16:18 ` [PATCH 3/6] ARM: pm: convert PXA to generic " Russell King - ARM Linux
2011-02-11 16:18 ` [PATCH 4/6] ARM: pm: convert sa11x0 " Russell King - ARM Linux
2011-02-11 16:18 ` [PATCH 5/6] ARM: pm: convert samsung platforms " Russell King - ARM Linux
2011-02-17 12:09 ` Kukjin Kim
2011-02-17 14:06 ` Russell King - ARM Linux
2011-02-17 23:05 ` Kukjin Kim
2011-02-17 23:29 ` Russell King - ARM Linux
2011-02-17 23:46 ` Kukjin Kim
2011-02-11 16:19 ` [PATCH 6/6] ARM: pm: allow generic sleep code to be used with SMP CPU idle Russell King - ARM Linux
2011-02-12 2:52 ` Colin Cross
2011-02-13 21:59 ` Colin Cross
2011-02-14 16:01 ` Russell King - ARM Linux
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='000301cbd1ad$e67cb130$b3761390$%kim@samsung.com' \
--to=kgene.kim@samsung.com \
--cc=ccross@google.com \
--cc=eric.y.miao@gmail.com \
--cc=linux-arm-kernel@lists.infradead.org \
--cc=linux-omap@vger.kernel.org \
--cc=linux@arm.linux.org.uk \
/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