[PATCH] fix hald-addon-dell-backlight AC detection

Danny Kukawka danny.kukawka at web.de
Mon Mar 3 16:47:22 PST 2008


Hi,

this fixes fd.o bug #13669 and hald-addon-dell-backlight which uses a 
hardcoded udi to get AC adapter information. With the switch to sysfs 
power_supply devices for AC adapter the path is no longer valid. I changed 
the code to check all devices with ac_adapter capability and check then all 
AC adapter until a device has ac_adapter.present and then get the info about 
the adapter state from there.

See attached patch (untested atm, test it tomorrow/later today).

Danny

 addon-dell-backlight.cpp |   25 ++++++++++++++++++++-----
 1 file changed, 20 insertions(+), 5 deletions(-)
-------------- next part --------------
A non-text attachment was scrubbed...
Name: hal-fix-dell_backlight_addon.diff
Type: text/x-diff
Size: 1833 bytes
Desc: not available
Url : http://lists.freedesktop.org/archives/hal/attachments/20080304/7c717fe7/attachment.diff 


More information about the hal mailing list