HAL shows to batteries for ACPI

Andrey Borzenkov arvidjaar at mail.ru
Sat Nov 29 01:45:09 PST 2008


kernel 2.6.28-rc6, Mandriva cooker, HAL hal-0.5.11-7mdv2009.0.src.rpm. After 
update to KDE4 I was surprised that battery monitor shows two batteries - it 
turned out, it is really HAL issue.

{pts/1}:~%> lshal | grep BAT
udi = '/org/freedesktop/Hal/devices/computer_power_supply_battery_BAT1_0'
  info.udi = 
'/org/freedesktop/Hal/devices/computer_power_supply_battery_BAT1_0'  
(string)
  linux.sysfs_path = 
'/sys/devices/LNXSYSTM:00/device:00/PNP0C0A:00/power_supply/BAT1'  (string)
udi = '/org/freedesktop/Hal/devices/computer_power_supply_battery_BAT1'
  info.udi = 
'/org/freedesktop/Hal/devices/computer_power_supply_battery_BAT1'(string)
  linux.sysfs_path = 
'/sys/devices/LNXSYSTM:00/device:00/PNP0C0A:00/power_supply/BAT1'  (string)

Wat is funny, both of them refer to the same physical device.

{pts/1}:~%> ll /sys/devices/LNXSYSTM:00/device:00/PNP0C0A:00/power_supply
итого 0
drwxr-xr-x 3 root root 0 2008-11-29 12:23 BAT1/
{pts/1}:~%> ll /sys/class/power_supply
итого 0
lrwxrwxrwx 1 root root 0 2008-11-29 12:43 ADP1 -> 
../../devices/LNXSYSTM:00/device:00/ACPI0003:00/power_supply/ADP1/
lrwxrwxrwx 1 root root 0 2008-11-29 12:43 BAT1 -> 
../../devices/LNXSYSTM:00/device:00/PNP0C0A:00/power_supply/BAT1/

Any idea?


More information about the hal mailing list