aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/power/wm97xx_battery.c
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/power/wm97xx_battery.c')
-rw-r--r--drivers/power/wm97xx_battery.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/drivers/power/wm97xx_battery.c b/drivers/power/wm97xx_battery.c
index 5071d85ec12d..156559e56fa5 100644
--- a/drivers/power/wm97xx_battery.c
+++ b/drivers/power/wm97xx_battery.c
@@ -147,7 +147,7 @@ static irqreturn_t wm97xx_chrg_irq(int irq, void *data)
147#ifdef CONFIG_PM 147#ifdef CONFIG_PM
148static int wm97xx_bat_suspend(struct device *dev) 148static int wm97xx_bat_suspend(struct device *dev)
149{ 149{
150 flush_scheduled_work(); 150 flush_work_sync(&bat_work);
151 return 0; 151 return 0;
152} 152}
153 153
@@ -273,7 +273,7 @@ static int __devexit wm97xx_bat_remove(struct platform_device *dev)
273 free_irq(gpio_to_irq(pdata->charge_gpio), dev); 273 free_irq(gpio_to_irq(pdata->charge_gpio), dev);
274 gpio_free(pdata->charge_gpio); 274 gpio_free(pdata->charge_gpio);
275 } 275 }
276 flush_scheduled_work(); 276 cancel_work_sync(&bat_work);
277 power_supply_unregister(&bat_ps); 277 power_supply_unregister(&bat_ps);
278 kfree(prop); 278 kfree(prop);
279 return 0; 279 return 0;