linuxppc-dev.lists.ozlabs.org archive mirror
 help / color / mirror / Atom feed
From: Scott Wood <scottwood@freescale.com>
To: Anton Vorontsov <cbouatmailru@gmail.com>
Cc: linuxppc-dev@ozlabs.org
Subject: Re: [PATCH v2] powerpc: Add hibernation support for FSL BookE processors
Date: Fri, 16 Apr 2010 10:48:09 -0500	[thread overview]
Message-ID: <4BC886B9.7080202@freescale.com> (raw)
In-Reply-To: <20100416054010.GA391@oksana.dev.rtsoft.ru>

Anton Vorontsov wrote:
> On Thu, Apr 15, 2010 at 03:05:08PM -0500, Scott Wood wrote:
>> Kumar Gala wrote:
>>> On Apr 15, 2010, at 1:45 PM, Anton Vorontsov wrote:
>>>> Kumar,
>>>>
>>>> According to patchwork, this is now delegated to you. Do you
>>>> have any objections to merge this?
>>> Would like Scott's Ack.
>> I think we need to save IACn, DACn, DBCRn,
> 
> Does the kernel actually need these registers? I mean, they're
> saved per thread anyway.
> 
>> PID0,
> 
> Kernel clears it early at boot, why would we save it?

What context are we in when we suspend, and what context is expected 
after resume?  If we're guaranteed not to be on a thread that cares 
about any of this, then OK.

>> and USPRG0.
> 
> Currently this isn't used at all.

Was thinking that it's up to userspace whether to use it or not -- 
though it ought to be saved on thread switch instead.

>> Might want to also save TLB1 contents, and maybe things like HIDn,
>> cache registers, etc. -- I don't think they're changeable post-boot
>> currently, but it'd be good to avoid surprises if that were to
>> change.
> 
> Hm. I don't really like the idea of doing things 'just in case',
> it just adds a code which functionality isn't tested, and which
> we will might never actually need.

The intent was to reduce dependencies between the suspend code and what 
the rest of the kernel does -- it's likely that someone adding some 
runtime manipulation of one of these things (e.g. hugetlbfs modifying 
TLB1) would not think to check suspend/hibernation code.  It would still 
be somewhat tested, in that you would see problems if you restored the 
wrong values (just not if you failed to restore at all).

We'll need to save/restore those things anyway for deep sleep -- but I'm 
not sure whether it'll be feasible to share code with hibernate (I 
recall trying on 83xx and giving up).  In any case, it can probably wait 
until 85xx deep sleep gets pushed out.

-Scott

  reply	other threads:[~2010-04-16 15:48 UTC|newest]

Thread overview: 18+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2010-02-24 21:38 [PATCH v2] powerpc: Add hibernation support for FSL BookE processors Anton Vorontsov
2010-04-15 18:45 ` Anton Vorontsov
2010-04-15 19:20   ` Kumar Gala
2010-04-15 19:36     ` Anton Vorontsov
2010-04-15 20:05     ` Scott Wood
2010-04-15 20:18       ` Scott Wood
2010-04-16 11:56         ` [PATCH v3] " Anton Vorontsov
2010-04-16 15:54           ` Scott Wood
2010-04-16 19:03             ` [PATCH v4] " Anton Vorontsov
2010-05-17 18:03               ` Kumar Gala
2010-05-17 18:12               ` Scott Wood
2010-05-17 18:56                 ` [PATCH v5] " Anton Vorontsov
2010-05-17 21:17                   ` Kumar Gala
2010-05-17 21:22                   ` Kumar Gala
2010-05-18  5:59                     ` Anton Vorontsov
2010-04-16  5:40       ` [PATCH v2] " Anton Vorontsov
2010-04-16 15:48         ` Scott Wood [this message]
2010-04-16 19:03           ` Anton Vorontsov

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=4BC886B9.7080202@freescale.com \
    --to=scottwood@freescale.com \
    --cc=cbouatmailru@gmail.com \
    --cc=linuxppc-dev@ozlabs.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).