linux-arm-kernel.lists.infradead.org archive mirror
 help / color / mirror / Atom feed
From: lorenzo.pieralisi@arm.com (Lorenzo Pieralisi)
To: linux-arm-kernel@lists.infradead.org
Subject: [PATCH v2 6/6] arm/imx6q: add suspend/resume support
Date: Tue, 20 Sep 2011 16:35:53 +0100	[thread overview]
Message-ID: <20110920153553.GA27018@e102568-lin.cambridge.arm.com> (raw)
In-Reply-To: <20110917083007.GA26572@S2100-06.ap.freescale.net>

On Sat, Sep 17, 2011 at 09:30:09AM +0100, Shawn Guo wrote:
> On Fri, Sep 16, 2011 at 03:45:39PM +0100, Lorenzo Pieralisi wrote:
> > Hi Shawn,
> > 
> > On Fri, Sep 16, 2011 at 07:09:00AM +0100, Shawn Guo wrote:
> > > Hi Lorenzo,
> > > 
> > > On Thu, Sep 15, 2011 at 05:28:29PM +0100, Lorenzo Pieralisi wrote:
> > > > On Thu, Sep 15, 2011 at 03:45:26PM +0100, Shawn Guo wrote:
> > > > > It adds suspend/resume support for imx6q.
> > > > > 
> > > > > Signed-off-by: Anson Huang <b20788@freescale.com>
> > > > > Signed-off-by: Shawn Guo <shawn.guo@linaro.org>
> > > > > ---

[...]

> One reason that I implemented pl310_resume as a function call is that
> I was trying to minimize the code that we have to put in .data section.
> Now I do not think it's a point that really matters.  So following your
> suggestion, here it is.  Please let me know it is not what you meant to
> see.
> 
> /*
>  * The following code is located into the .data section.  This is to
>  * allow pl310_pbase and pl310_aux_ctrl to be accessed with a relative
>  * load as we are running on physical address here.
>  */
>         .data
>         .align
> 
>         .macro  pl310_resume
>         adr     r2, pl310_pbase
>         ldmia   r2, {r0, r1}
>         str     r1, [r0, #L2X0_AUX_CTRL]        @ restore aux_ctrl
>         mov     r1, #0x1
>         str     r1, [r0, #L2X0_CTRL]            @ re-enable L2
>         .endm
> 
> ENTRY(v7_cpu_resume)
>         bl      v7_invalidate_l1
>         pl310_resume
>         b       cpu_resume
> ENDPROC(v7_cpu_resume)
> 
> .globl
> pl310_pbase:
>         .long   0
> pl310_aux_ctrl:
>         .long   0

Yes, it does look simpler and better to me, but I still think there are going
to be other platforms doing the same precise thing if they run secure,
so we may want to generalize it; let's discuss it and converge.

Thanks for reworking it,
Lorenzo

      parent reply	other threads:[~2011-09-20 15:35 UTC|newest]

Thread overview: 18+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2011-09-15 14:45 [PATCH v2 0/6] add initial imx6q support Shawn Guo
2011-09-15 14:45 ` [PATCH v2 1/6] arm/imx6q: add device tree source Shawn Guo
2011-09-15 14:45 ` [PATCH v2 2/6] arm/imx6q: add core definitions and low-level debug uart Shawn Guo
2011-09-19  9:35   ` Sascha Hauer
2011-09-19  9:45     ` Eric Miao
2011-09-19  9:55       ` Sascha Hauer
2011-09-19  9:58         ` Eric Miao
2011-09-19 14:21         ` Shawn Guo
2011-09-15 14:45 ` [PATCH v2 3/6] arm/imx6q: add core drivers clock, gpc, mmdc and src Shawn Guo
2011-09-15 14:45 ` [PATCH v2 4/6] arm/imx6q: add smp and cpu hotplug support Shawn Guo
2011-09-15 14:45 ` [PATCH v2 5/6] arm/imx6q: add device tree machine support Shawn Guo
2011-09-15 14:45 ` [PATCH v2 6/6] arm/imx6q: add suspend/resume support Shawn Guo
2011-09-15 16:28   ` Lorenzo Pieralisi
2011-09-16  6:09     ` Shawn Guo
2011-09-16 14:45       ` Lorenzo Pieralisi
2011-09-17  8:30         ` Shawn Guo
2011-09-17 12:32           ` Shawn Guo
2011-09-20 15:35           ` Lorenzo Pieralisi [this message]

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=20110920153553.GA27018@e102568-lin.cambridge.arm.com \
    --to=lorenzo.pieralisi@arm.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).