diff options
author | Paul Mundt <lethal@linux-sh.org> | 2010-05-19 22:57:38 -0400 |
---|---|---|
committer | Paul Mundt <lethal@linux-sh.org> | 2010-05-19 22:57:38 -0400 |
commit | ffee72d4681c8777918268a96aef42bdeb6c367b (patch) | |
tree | 4baf91483886d561c198ed0524ab54b783273e86 /drivers/acpi/battery.c | |
parent | fb54d268329846aa13b2bc44a64d90e9b7131192 (diff) | |
parent | f72caf7e496465182eeda842ac66a5e75404ddf1 (diff) |
Merge branch 'master' of git://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux-2.6
Diffstat (limited to 'drivers/acpi/battery.c')
-rw-r--r-- | drivers/acpi/battery.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/drivers/acpi/battery.c b/drivers/acpi/battery.c index 5717bd300869..3026e3fa83ef 100644 --- a/drivers/acpi/battery.c +++ b/drivers/acpi/battery.c | |||
@@ -568,13 +568,13 @@ static int acpi_battery_update(struct acpi_battery *battery) | |||
568 | result = acpi_battery_get_status(battery); | 568 | result = acpi_battery_get_status(battery); |
569 | if (result) | 569 | if (result) |
570 | return result; | 570 | return result; |
571 | #ifdef CONFIG_ACPI_SYSFS_POWER | ||
572 | if (!acpi_battery_present(battery)) { | 571 | if (!acpi_battery_present(battery)) { |
572 | #ifdef CONFIG_ACPI_SYSFS_POWER | ||
573 | sysfs_remove_battery(battery); | 573 | sysfs_remove_battery(battery); |
574 | #endif | ||
574 | battery->update_time = 0; | 575 | battery->update_time = 0; |
575 | return 0; | 576 | return 0; |
576 | } | 577 | } |
577 | #endif | ||
578 | if (!battery->update_time || | 578 | if (!battery->update_time || |
579 | old_present != acpi_battery_present(battery)) { | 579 | old_present != acpi_battery_present(battery)) { |
580 | result = acpi_battery_get_info(battery); | 580 | result = acpi_battery_get_info(battery); |
@@ -880,7 +880,7 @@ static void acpi_battery_notify(struct acpi_device *device, u32 event) | |||
880 | #ifdef CONFIG_ACPI_SYSFS_POWER | 880 | #ifdef CONFIG_ACPI_SYSFS_POWER |
881 | /* acpi_battery_update could remove power_supply object */ | 881 | /* acpi_battery_update could remove power_supply object */ |
882 | if (battery->bat.dev) | 882 | if (battery->bat.dev) |
883 | kobject_uevent(&battery->bat.dev->kobj, KOBJ_CHANGE); | 883 | power_supply_changed(&battery->bat); |
884 | #endif | 884 | #endif |
885 | } | 885 | } |
886 | 886 | ||