Problem Suspending on Debian Etch (Solved)

Tim Dijkstra newsuser at famdijkstra.org
Wed Sep 27 14:47:23 PDT 2006


Op Wed, 27 Sep 2006 13:10:04 -0700
schreef jantzen <david.jantzen at comcast.net>:

> Hi Tim, thanks for getting back to back me to quickly.  I've been
> inspecting the hal-system-power-suspend script.  And I see that
> Etch actually installs both uswsusp (with s2both/s2disk/s2ram) and
> hibernate and it's scriptlets in the laptop profile.
> hal-system-power-suspend first finds and tries s2both, which fails on
> pre 2.6.17 kernels because, as I dimly understand it, it links into
> tools built directly into the new kernel for suspend/hibernate
> behavior.  

All kinds of suspend need some cooperation of the kernel. Some
(suspend2) even need a patched kernel. 

> So, the short answer is that it's borken because Debian testing
> supplies uswsusp and tqhe 2.6.16 kernel (or did three weeks ago when I
> installed). 

I thought it had 2.6.17 already, anyway etch will probably  be
released with 2.6.18. The uswsusp README says to use 2.6.17 or higher
kernels. Unfortunately I can't Depend: on a kernel version...

> Would it be possible for future versions of hal-system-power-suspend
> to check $? after each call to a power management system to see if
> the one that it found actually succeeded, and in the case of failure
> to continue looking for ways to suspend?  That would enable systems
> like mine to bonk on uswsusp and hibernate and hit the failsafe
> option.

Hmm, I would have thought it did... Anyway, as you can read in the post
of David in the thread, that script (h-s-p-s) is going away. It will be
replaced by a different set of scrips, very much like hibernate.

> In any case suspend at least works on my new primary work machine now.
> That's definitely a good thing.  

Very good.

> The last wrinkle is that it doesn't
> play nice with my Intel 3945 wifi driver, and locks the machine during
> suspend, so I have to unload the module first.  
Make sure to file a bug in the kernel's bugzilla, that needs to be
fixed.

> I'd really like to be
> able to automatically unload/load the module when suspending as with
> the hibernate package's scriptlets, but I don't see a facility in
> uswsusp to do that. I could put a hack in the
> hal-system-power-suspend script, but I'd really rather not.

I'm pretty sure you can make hibernate call s2disk and before that
remove that module.
 
> Do you know if the future of Linux power management is uswsusp?  If
> so, I'm a bit perplexed since the hibernate package seems far more
> mature and configurable with it's scriptlets approach.  

Yes uswsusp _is_ the future! ;) But seriously, hibernate and uswsusp
work on different layers in the stack. Hibernate is just a bunch
of scripts in the end it will ask the kernel to do hibernate or call the
uswsusp utilities to do the dirty work.

According to David (the HAL author) the future is _not_ hibernate, but
pm-utils (which has similar objectives). Future versions of HAL will
depend on pm-utils, which will make hibernate obsolete.
Unfortunately however pm-utils isn't in debian yet. In the mean time
it's probably best to use hibernate and tell it to use uswsusp.

I hope I didn't confuse you to much.

grts Tim




More information about the hal mailing list