aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorLen Brown <len.brown@intel.com>2010-12-24 21:43:16 -0500
committerLen Brown <len.brown@intel.com>2010-12-24 21:43:16 -0500
commitcde44d1740bcb3dcfecbf792a71826431e61686e (patch)
tree55dc8dace058affeff7cd4cd3575b2f03fe40f22
parent3138b32d5e0998ba3cbd1c74bdc1887d74c5279b (diff)
Revert "ACPI battery: update status upon sysfs query"
This reverts commit 3138b32d5e0998ba3cbd1c74bdc1887d74c5279b. as it caused a crash upon battery removal: https://bugzilla.kernel.org/show_bug.cgi?id=25302 Signed-off-by: Len Brown <len.brown@intel.com>
-rw-r--r--drivers/acpi/battery.c5
1 files changed, 0 insertions, 5 deletions
diff --git a/drivers/acpi/battery.c b/drivers/acpi/battery.c
index 9fb9d5ac939d..95649d373071 100644
--- a/drivers/acpi/battery.c
+++ b/drivers/acpi/battery.c
@@ -130,8 +130,6 @@ struct acpi_battery {
130 unsigned long flags; 130 unsigned long flags;
131}; 131};
132 132
133static int acpi_battery_update(struct acpi_battery *battery);
134
135#define to_acpi_battery(x) container_of(x, struct acpi_battery, bat); 133#define to_acpi_battery(x) container_of(x, struct acpi_battery, bat);
136 134
137inline int acpi_battery_present(struct acpi_battery *battery) 135inline int acpi_battery_present(struct acpi_battery *battery)
@@ -186,9 +184,6 @@ static int acpi_battery_get_property(struct power_supply *psy,
186 int ret = 0; 184 int ret = 0;
187 struct acpi_battery *battery = to_acpi_battery(psy); 185 struct acpi_battery *battery = to_acpi_battery(psy);
188 186
189 if (acpi_battery_update(battery))
190 return -ENODEV;
191
192 if (acpi_battery_present(battery)) { 187 if (acpi_battery_present(battery)) {
193 /* run battery update only if it is present */ 188 /* run battery update only if it is present */
194 acpi_battery_get_state(battery); 189 acpi_battery_get_state(battery);