public inbox for linux-acpi@vger.kernel.org
 help / color / mirror / Atom feed
From: "Rafael J. Wysocki" <rjw@sisk.pl>
To: Guilherme Salgado <gsalgado@gmail.com>
Cc: linux-acpi@vger.kernel.org
Subject: Re: Thinkpad suspend-to-disk regression
Date: Fri, 4 May 2007 11:07:45 +0200	[thread overview]
Message-ID: <200705041107.45968.rjw@sisk.pl> (raw)
In-Reply-To: <3d7cf86d0705031634j5dc116fbwf2870773713f3b92@mail.gmail.com>

On Friday, 4 May 2007 01:34, Guilherme Salgado wrote:
> On 5/3/07, Rafael J. Wysocki <rjw@sisk.pl> wrote:
> > On Thursday, 3 May 2007 15:45, Guilherme Salgado wrote:
> > > On 5/2/07, Rafael J. Wysocki <rjw@sisk.pl> wrote:
> > > > On Wednesday, 2 May 2007 19:28, Guilherme Salgado wrote:
> > > > > On 4/25/07, Rafael J. Wysocki <rjw@sisk.pl> wrote:
> > > > > > On Wednesday, 25 April 2007 04:25, Guilherme Salgado wrote:
> > > > > > > On 4/24/07, Rafael J. Wysocki <rjw@sisk.pl> wrote:
> > > > > > > > On Tuesday, 24 April 2007 20:29, Guilherme Salgado wrote:
> > > > > > > > > (I've already sent this to linux-acpi but got no response so far, so I
> > > > > > > > > thought it could be a good idea to send directly to you)
> > > > > > > > >
> > > > > > > > > Hi there,
> > > > > > > > >
> > > > > > > > > I recently noticed that my thinkpad T60 would lose the sound after
> > > > > > > > > being suspended to disk (https://launchpad.net/bugs/80893), requiring
> > > > > > > > > a cold restart to fix it. After some git-bisect work I found this
> > > > > > > > > regression was a consequence of
> > > > > > > > > http://git.kernel.org/?p=linux/kernel/git/lenb/linux-acpi-2.6.git;a=commitdiff;h=9185cfa92507d07ac787bc73d06c42222eec7239
> > > > > > > > > (patch inlined here)
> > > > > > > > >
> > > > > > > > > Is there any chance of fixing the regression this introduced without
> > > > > > > > > reverting it? Please let me know if you want any other info or have a
> > > > > > > > > patch for me to try.
> > > > > > > >
> > > > > > > > You don't need a patch, I think.  Please try
> > > > > > > >
> > > > > > > > # echo shutdown > /sys/power/disk
> > > > > > > >
> > > > > > > > before the suspend (assuming you use the built-in swsusp).  If that works,
> > > > > > > > just make your configuration scripts echo 'shutdown' to /sys/power/disk at
> > > > > > > > system startup.
> > > > > > > >
> > > > > > >
> > > > > > > I use Ubuntu's default /etc/acpi/hibernate.sh, which already sets
> > > > > > > /sys/power/disk to shutdown before echoing "disk" to /sys/power/state.
> > > > > >
> > > > > > In that case it's impossible that the commit you have identified causes the
> > > > > > problem to happen.
> > > > > >
> > > > > > It doesn't even touch the 'shutdown' code path.
> > > > >
> > > > > Is it be possible that the change to /sys/power/disk is not doing what
> > > > > it should? I think that's likely to be the case because I got a bunch
> > > > > of people to try a kernel with the patch reverted and it fixed the
> > > > > problem they were having.
> > > > >
> > > > > The most recent comments at https://bugs.launchpad.net/+bugs/80893 are
> > > > > all confirming that the kernel at
> > > > > http://rookery.ubuntu.com/~kyle/kernels/salgado/2007-04-25/ fixes
> > > > > their problem.
> > > > >
> > > > > I'd be glad to do anything to further debug this if you can give me
> > > > > some pointers.
> > > >
> > > > Well, the problem is that we have switched to the platform mode by default
> > > > and "echo shutdown > /sys/power/disk" before the suspend should get the old
> > > > behavior back
> > > >
> > >
> > > Right, that's why I asked if it'd be possible that echoing "shutdown"
> > > to /sys/power/disk could somehow be a no-op in this case.
> > >
> > > > Please try to apply the appended patch instead of reverting the entire commit
> > > > and see if the problem is still present.
> > > >
> > >
> > > That works just fine, yes. Are you willing to change the default back
> > > to PM_DISK_SHUTDOWN or should we find out why "echo shutdown >
> > > /sys/power/disk" is not having the same effect as changing the
> > > default, as it should?
> >
> > In fact, I'd rather would like to find out what's the reason for the
> > "echo shutdown > /sys/power/disk" not working.
> >
> 
> So do I, but I'm sort of short on ideas for how to debug this (IANAKD
> :-); that's why I asked if you'd have any pointers.

Hmm, can you try to start the hibernation manually?  I mean, do

# echo 5 > /proc/sys/kernel/printk
# echo shutdown > /sys/power/disk

and check what it shows:

# cat /sys/power/disk

If this is 'shutdown', then do

# echo disk > /sys/power/state

and see if that works.

If you've done it already, please let me know and I'll prepare a debug patch
for you.

> 
> > Besides, could you please check if the problems with the 'platform' mode
> > suspend persist with the appended patch applied?
> >
> 
> Yep, the problem persists, unfortunately.

OK, so much for that.  Thanks for testing.

Greetings,
Rafael

  reply	other threads:[~2007-05-04  9:03 UTC|newest]

Thread overview: 14+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
     [not found] <3d7cf86d0704241129i23da1b9fq93876573618e9dcd@mail.gmail.com>
     [not found] ` <200704250032.11108.rjw@sisk.pl>
2007-04-25  2:25   ` Thinkpad suspend-to-disk regression Guilherme Salgado
2007-04-25 12:47     ` Rafael J. Wysocki
2007-05-02 17:28       ` Guilherme Salgado
2007-05-02 19:37         ` Rafael J. Wysocki
2007-05-03 13:45           ` Guilherme Salgado
2007-05-03 17:23             ` Rafael J. Wysocki
2007-05-03 23:34               ` Guilherme Salgado
2007-05-04  9:07                 ` Rafael J. Wysocki [this message]
2007-05-04 12:37                   ` Guilherme Salgado
2007-05-04 13:33                     ` Joerg Platte
2007-05-04 13:39                       ` Guilherme Salgado
2007-05-04 16:08                         ` Guilherme Salgado
2007-05-04 20:55                           ` Rafael J. Wysocki
2007-04-21 15:30 Guilherme Salgado

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=200705041107.45968.rjw@sisk.pl \
    --to=rjw@sisk.pl \
    --cc=gsalgado@gmail.com \
    --cc=linux-acpi@vger.kernel.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