[Intrepid] Suspend fails when telling pm-utils to use uswsusp

Bug #287374 reported by Chow Loong Jin
16
Affects Status Importance Assigned to Milestone
pm-utils (Ubuntu)
Fix Released
Low
Unassigned
Intrepid
Fix Released
Undecided
Unassigned

Bug Description

Binary package hint: pm-utils

After setting SLEEP_MODULE in /etc/pm/config.d/00sleep_module to "uswsusp", suspend becomes impossible. This is a regression, because in Hardy, suspend was possible even when uswsusp was chosen as the suspend method.

The reason for this bug is that the uswsusp code in pm-utils tries to use s2ram to suspend, which does not exist, because its build was disabled (see Bug #134238). In previous versions, pm-utils fell back onto the kernel method when it could not find s2ram. This bug appeared in Bug #267141 when pm-utils auto-detected uswsusp and used it instead of the kernel method. The resolution for Bug #267141 in a patch provided by James Westby was to remove the auto-detection code completely, but that does not fix the issue I have highlighted.

And finally, there are two possible fixes (which I can see) for this:
1. Patch /usr/lib/pm-utils/module.d/uswsusp to fall back on kernel for check_suspend and do_suspend (The attached patch will do just that)
2. Re-enable the s2ram build in uswsusp

Related branches

Revision history for this message
Chow Loong Jin (hyperair) wrote :
Revision history for this message
James Westby (james-w) wrote :

Hi,

I think your patch is a sensible one. If we know s2ram isn't going
to be available we shouldn't bother checking for it.

I haven't reviewed the patch in detail yet, but I think it may be a
little too late for the release. I do however think it makes a reasonable
candidate for an SRU.

I'm subscribing the sponsors for main so that someone appropriate can
review the change.

Thanks,

James

It does break it for those that have recompiled uswsusp to have
an s2ram binary, but they will be an even smaller minority.

Changed in pm-utils:
importance: Undecided → Low
status: New → Confirmed
Revision history for this message
Chow Loong Jin (hyperair) wrote : Re: [Bug 287374] Re: [Intrepid] Suspend fails when telling pm-utils to use uswsusp

On Wed, 2008-10-22 at 09:12 +0000, James Westby wrote:
> Hi,
>
> I think your patch is a sensible one. If we know s2ram isn't going
> to be available we shouldn't bother checking for it.
>
> I haven't reviewed the patch in detail yet, but I think it may be a
> little too late for the release. I do however think it makes a reasonable
> candidate for an SRU.
>
> I'm subscribing the sponsors for main so that someone appropriate can
> review the change.
>
> Thanks,
>
> James
>
>
> It does break it for those that have recompiled uswsusp to have
> an s2ram binary, but they will be an even smaller minority.
>
>
> ** Changed in: pm-utils (Ubuntu)
> Importance: Undecided => Low
> Status: New => Confirmed
>
While we know that s2ram isn't going to be available by default, I think
we shouldn't break it for those who do have s2ram, or it would be a
regression for them. As of now this patch doesn't carry any negative
effects to either party, i.e. it uses s2ram if present, and uses kernel
if s2ram isn't.
--
Chow Loong Jin

Revision history for this message
James Westby (james-w) wrote :

On Wed, 2008-10-22 at 09:27 +0000, hyperair wrote:
> While we know that s2ram isn't going to be available by default, I think
> we shouldn't break it for those who do have s2ram, or it would be a
> regression for them. As of now this patch doesn't carry any negative
> effects to either party, i.e. it uses s2ram if present, and uses kernel
> if s2ram isn't.

Yes, sorry, I realised this after sending.

I think your patch is a good idea.

Thanks,

James

Revision history for this message
Chow Loong Jin (hyperair) wrote :

Here's an updated debdiff which includes this bug number.
--
Chow Loong Jin

Revision history for this message
Martin Pitt (pitti) wrote :

Accepted into intrepid-proposed, please test and give feedback here. Please see https://wiki.ubuntu.com/Testing/EnableProposed for documentation how to enable and use -proposed. Thank you in advance!

Changed in pm-utils:
status: New → Fix Committed
Revision history for this message
Chow Loong Jin (hyperair) wrote :

On Mon, 2008-11-03 at 12:51 +0000, Martin Pitt wrote:
> Accepted into intrepid-proposed, please test and give feedback here.
> Please see https://wiki.ubuntu.com/Testing/EnableProposed for
> documentation how to enable and use -proposed. Thank you in advance!
>
> ** Changed in: pm-utils (Ubuntu Intrepid)
> Status: New => Fix Committed
>
> ** Tags added: verification-needed
>
I've tested and can confirm that both suspend and hibernate are working,
with hibernate using s2disk.
--
Chow Loong Jin

Revision history for this message
Martin Pitt (pitti) wrote :

I verified that suspend/resume still works normally (without uswsusp, as installed by default) with this version.

Revision history for this message
Martin Pitt (pitti) wrote :

intrepid-proposed package copied to jaunty.

Changed in pm-utils:
status: Confirmed → Fix Released
Revision history for this message
Martin Pitt (pitti) wrote :

Copied to intrepid-updates.

Changed in pm-utils:
status: Fix Committed → Fix Released
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.