Better integration with power management scripts

Richard Hughes hughsient at gmail.com
Thu Apr 20 09:25:24 PDT 2006


On Thu, 2006-04-20 at 18:12 +0200, Stefan Seyfried wrote:
> On Tue, Apr 18, 2006 at 11:41:23AM +0100, Richard Hughes wrote:
> > Further to David's ideas, here are some of my ideas (shamelessly taken
> > from the ubuntu pmi and fedora pmscripts):
> > 
> > Create a /usr/share/hal/scripts/pm/hooks directory that distros and
> > vendors can dump files into that do things on resume and suspend, for
> > example:
> > 
> > * unloading certain modules and re-modprobing them if required
> > * stopping and starting certain services
> 
> How will you interact with the user if stopping a service / unloading
> a module fails?

We won't. If it's a broken module, it's a broken module.

> > * re-initialise the video of video cards as reqd.
> 
> Just use s2ram from the suspend project http://suspend.sf.net

Yes, that looks good. I'll ping the author and see what he thinks.
Presumably this has to took into the current infrastructure somewhere
too.

> > I think this is required as all the main distros have different ways of
> > doing this, for example pmi for ubuntu and pm-* for fedora, when all
> > this stuff is *really* simple and should be centralised in HAL so
> 
> Well, but then you will have to implement lots of stuff in HAL so we can
> decent usability and security for suspend.

Well, not all in HAL, if the actual hooks are outside HAL (see my other
mail) then not much has to change in HAL at all. I do think putting the
video resume hooks in HAL is one way or another is a good idea, as it
allows us to do matching based on fdi files on the hardware, rather than
hacking about lspci.

> > Comments? Please bear in mind the general idea is to make this easy for
> > a user to suspend and hibernate, not some political statement using HAL,
> > so please keep critique technical.
> 
> Well, using HAL for suspend is a pretty hot political topic, but anyway... :-)

I love politics!

Richard.



More information about the hal mailing list