<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 3.2//EN">
<HTML>
<HEAD>
<META HTTP-EQUIV="Content-Type" CONTENT="text/html; charset=iso-8859-1">
<META NAME="Generator" CONTENT="MS Exchange Server version 6.5.7226.0">
<TITLE>RE: Fedora power management</TITLE>
</HEAD>
<BODY>
<!-- Converted from text/plain format -->
<BR>

<P><FONT SIZE=2>David, (cc-ing to hal-devel)<BR>
<BR>
-----Original Message-----<BR>
From: David Zeuthen [<A HREF="mailto:david">mailto:david</A><at>fubar.dk]<BR>
Sent: Mon 15/11/2004 01:24<BR>
>On Fri, 2004-11-12 at 20:41 +0000, Hughes R Mr (UG - Electronic Eng)<BR>
>wrote:<BR>
>> Has this been done before? Or is it worth discussion? I thought I<BR>
>> would try you guys at f-d-l and then try the gnome people when I know<BR>
>> more good ideas/case studies.<BR>
>><BR>
><BR>
>I think a better approach might be to teach hal about ACPI (for x86 and<BR>
>others), PMU (for PowerMac's etc.) and provide an abstraction using the<BR>
>functionality already in hal (e.g. properties on hal device objects and<BR>
>callouts, device information files). This abstraction should be made<BR>
>sufficiently extensible such that it may support more than ACPI and PMU<BR>
>as well as the varying features on different laptops [1].<BR>
><BR>
<BR>
Sounds good to me, cleanest and most portable across architectures.<BR>
<BR>
> <A HREF="http://freedesktop.org/pipermail/hal/2004-July/000555.html">http://freedesktop.org/pipermail/hal/2004-July/000555.html</A><BR>
><BR>
>Nothing really happened, though. Now that FC3 is out I hope to find some<BR>
>time to do this for FC4 - it shouldn't be too difficult.<BR>
><BR>
<BR>
Well, if you need a hand...<BR>
<BR>
>An interesting question is how we allow the desktop session to say "put<BR>
>the system into standby". One trivial idea is to provide a 'system-<BR>
>suspend' command (through consolehelper or something), however I think<BR>
>that it might make more sense to make the hal daemon expose a D-BUS<BR>
>interface with the appropriate methods - e.g. perhaps just the method<BR>
>Suspend() on an interface org.freedesktop.Hal.Device.PowerManagement.<BR>
<BR>
org.freedesktop.Hal.Device.PowerManagement sounds good. Then battstat could<BR>
then just call on this interface to do the suspend, and do away with that<BR>
nasty textbox configuration option for suspending.<BR>
<BR>
>This method call should map to an appropriate script. That way we can<BR>
>leverage the D-BUS policy system for allowing/denying this action [2].<BR>
>Plus, that we'll need this in HAL anyway for other kind hardware/actions<BR>
>(e.g. Rename() and Eject() on storage volumes) and it makes it somewhat<BR>
>easier to use from e.g. GNOME applets.<BR>
<BR>
So in this unified-HAL theory, where would the brightness of an LCD panel live?<BR>
Would a "LCD panel" be varient of monitor in the HAL tree? How can this<BR>
information be added to HAL?<BR>
<BR>
Similarly, could we Implement an Eject() [to call cardctl eject?] on a PCMCIA<BR>
adaptor quite simply?<BR>
<BR>
><BR>
>Cheers,<BR>
>David<BR>
><BR>
>[1] : Some laptops doesn't turn off the display when the lid is closed<BR>
>(my Powerbook 12" for instance); tablets PC's probably don't have a lid<BR>
>at all etc.<BR>
><BR>
>[2] : which may be as simple as only allowing an authorized user at the<BR>
>console to perform the action.<BR>
<BR>
</FONT>
</P>

</BODY>
</HTML>