GNOME Bugzilla – Bug 497442
g-p-m shows two batteries when only one exists.
Last modified: 2009-03-04 14:46:36 UTC
Please describe the problem: When clicking on the g-p-m applet, it tells me that I have two batteries, when in fact, I only have one. They don't always show the same charge status either. This is on an IBM ThinkPad T43P Will attach debug output from g-p-m Steps to reproduce: 1. Click on g-p-m applet 2. 3. Actual results: Expected results: Does this happen every time? Yes Other information:
Created attachment 99221 [details] g-p-m debug output
Are you running a reall new kernel? Could you attach the output of lshal please. Thanks.
Created attachment 99341 [details] lshal output
I'm on kernel 2.6.24-rc2-git4
That's new :-) The kernel is reporting two battery devices, one from /proc/acpi/battery/X (old interface) and one from /sys/class/power_supply (new interface): udi = '/org/freedesktop/Hal/devices/computer_power_supply_0' battery.charge_level.current = 65260 (0xfeec) (int) battery.charge_level.last_full = 65260 (0xfeec) (int) battery.charge_level.percentage = 100 (0x64) (int) battery.charge_level.rate = 0 (0x0) (int) battery.current = 0 (0x0) (int) battery.present = true (bool) battery.rechargeable.is_charging = false (bool) battery.rechargeable.is_discharging = false (bool) battery.reporting.current = 65260 (0xfeec) (int) battery.reporting.design = 77760 (0x12fc0) (int) battery.reporting.last_full = 65260 (0xfeec) (int) battery.reporting.technology = 'Li-ion' (string) battery.reporting.unit = 'mWh' (string) battery.technology = 'lithium-ion' (string) battery.type = 'primary' (string) battery.vendor = 'SANYO' (string) battery.voltage.current = 12445 (0x309d) (int) info.capabilities = {'battery'} (string list) info.category = 'battery' (string) info.parent = '/org/freedesktop/Hal/devices/computer' (string) info.product = 'Li-ion' (string) info.udi = '/org/freedesktop/Hal/devices/computer_power_supply_0' (string) linux.hotplug_type = 2 (0x2) (int) linux.subsystem = 'power_supply' (string) linux.sysfs_path = '/sys/devices/LNXSYSTM:00/device:00/PNP0A08:00/device:01/PNP0C09:00/PNP0C0A:00/power_supply/BAT0' (string) udi = '/org/freedesktop/Hal/devices/acpi_BAT0' battery.alarm.design = 3263 (0xcbf) (int) battery.alarm.unit = 'mWh' (string) battery.charge_level.capacity_state = 'ok' (string) battery.charge_level.current = 65260 (0xfeec) (int) battery.charge_level.design = 77760 (0x12fc0) (int) battery.charge_level.granularity_1 = 1 (0x1) (int) battery.charge_level.granularity_2 = 1 (0x1) (int) battery.charge_level.last_full = 65260 (0xfeec) (int) battery.charge_level.low = 200 (0xc8) (int) battery.charge_level.percentage = 100 (0x64) (int) battery.charge_level.rate = 0 (0x0) (int) battery.charge_level.unit = 'mWh' (string) battery.charge_level.warning = 3263 (0xcbf) (int) battery.is_rechargeable = true (bool) battery.model = 'IBM-92P1077' (string) battery.present = true (bool) battery.rechargeable.is_charging = false (bool) battery.rechargeable.is_discharging = false (bool) battery.reporting.current = 65260 (0xfeec) (int) battery.reporting.design = 77760 (0x12fc0) (int) battery.reporting.granularity_1 = 1 (0x1) (int) battery.reporting.granularity_2 = 1 (0x1) (int) battery.reporting.last_full = 65260 (0xfeec) (int) battery.reporting.low = 200 (0xc8) (int) battery.reporting.rate = 0 (0x0) (int) battery.reporting.technology = 'LION' (string) battery.reporting.unit = 'mWh' (string) battery.reporting.warning = 3263 (0xcbf) (int) battery.serial = '113' (string) battery.technology = 'lithium-ion' (string) battery.type = 'primary' (string) battery.vendor = 'SANYO' (string) battery.voltage.current = 12445 (0x309d) (int) battery.voltage.design = 10800 (0x2a30) (int) battery.voltage.unit = 'mV' (string) info.capabilities = {'battery'} (string list) info.category = 'battery' (string) info.parent = '/org/freedesktop/Hal/devices/computer' (string) info.product = 'Battery Bay' (string) info.udi = '/org/freedesktop/Hal/devices/acpi_BAT0' (string) linux.acpi_path = '/proc/acpi/battery/BAT0' (string) linux.acpi_type = 0 (0x0) (int) linux.hotplug_type = 4 (0x4) (int) Solution: If you are defining CONFIG_POWER_SUPPLY in your .config then please unselect CONFIG_ACPI_BATTERY, or vice versa. Does that fix things?
Unloading the power_supply module reduces it to one battery. I'll talk to the openSUSE kernel devs and see what they want to do about this. Leaving this in NEEDINFO meanwhile.
Hi all, Same problem here since I upgraded to 2.6.24-rc5 yesterday on a Thinkpad T61. I removed CONFIG_ACPI_PROCFS_POWER and I now have only one battery again. Sadly, battery information is rather poor now. But I can live with this ;) Thanks
Mmmhhh... It seems that no power information is available while running on battery. This is lshal output while running on battery: udi = '/org/freedesktop/Hal/devices/computer_power_supply_0' battery.charge_level.current = 50570 (0xc58a) (int) battery.charge_level.last_full = 68760 (0x10c98) (int) battery.charge_level.percentage = 73 (0x49) (int) battery.charge_level.rate = 0 (0x0) (int) battery.current = 34961 (0x8891) (int) battery.present = true (bool) battery.rechargeable.is_charging = false (bool) battery.rechargeable.is_discharging = true (bool) battery.remaining_time = 9364 (0x2494) (int) battery.reporting.current = 50570 (0xc58a) (int) battery.reporting.design = 65520 (0xfff0) (int) battery.reporting.last_full = 68760 (0x10c98) (int) battery.reporting.technology = 'Li-ion' (string) battery.reporting.unit = 'mWh' (string) battery.technology = 'lithium-ion' (string) battery.type = 'primary' (string) battery.vendor = 'SANYO' (string) battery.voltage.current = 15566 (0x3cce) (int) info.capabilities = {'battery'} (string list) info.category = 'battery' (string) info.parent = '/org/freedesktop/Hal/devices/computer' (string) info.product = 'Li-ion' (string) info.udi = '/org/freedesktop/Hal/devices/computer_power_supply_0' (string) linux.hotplug_type = 2 (0x2) (int) linux.subsystem = 'power_supply' (string) linux.sysfs_path = '/sys/devices/LNXSYSTM:00/device:00/PNP0A08:00/device:01/PNP0C09:00/PNP0C0A:00/power_supply/BAT0' (string) Cheers,
CONFIG_POWER_SUPPLY is no longer used. I'm happy to close this bug.
(In reply to comment #9) > CONFIG_POWER_SUPPLY is no longer used. I'm happy to close this bug. > What does this mean exactly? Do you have disable CONFIG_POWER_SUPPLY in your kernel?