2008/3/7, Victor Lowther <[EMAIL PROTECTED]>: > On Thu, Mar 06, 2008 at 05:10:46PM +0100, Michael Biebl wrote: > > One downside of this might be, that other hooks/sleep_modules are > > interested in the quirk information. So they'd have to reparse the > > command line arguments. > > > > Actually, I was intending to just do that: > > Do the video quirk processing in uswsup. Imo it makes no sense to use > > vbetools when s2ram is already installed. So my plan was to add a > > [ $SLEEP_METHOD = "uswsusp" ] && return > > to 99video and simply pass the correct command line arguments to s2ram. > > > Hmmm... don't like that idea. IMAO, the hooks should not be aware of > what sleep method (kernel, tuxonice, uswsusp, whatever) is in use. How > about this instead: > > A new function disablehook(). This function, when called, will instruct
nitpick: could we make it disable_hook() please > run_hooks to skip running the hook with the same name as the first > parameter. would be nice if the number could be omitted. So you could only say disable_hook(video), which would skip all hooks matching ??video. > A before_hooks() function in the suspend module files. This function > (if it exists) will be called just before run_hooks starts processing > files. > > We can then modify uswsusp to call 'disablehook 99video' in its > before_hooks function. Whenever the system is using uswsusp, it will > not invoke 99video. > Sounds like a more flexible (and general) solution. Even if it is a bit more complex. Cheers, Michael -- Why is it that all of the instruments seeking intelligent life in the universe are pointed away from Earth? _______________________________________________ Pm-utils mailing list [email protected] http://lists.freedesktop.org/mailman/listinfo/pm-utils
