aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/mfd/palmas.c
diff options
context:
space:
mode:
authorLaxman Dewangan <ldewangan@nvidia.com>2013-09-26 09:33:50 -0400
committerLee Jones <lee.jones@linaro.org>2013-10-23 11:21:36 -0400
commit7178347e1c675aefefce09357c988db0a9bf6e96 (patch)
treed645734b47ea155892ea627253552b8daef20610 /drivers/mfd/palmas.c
parent2d8edaf028ad2bc71c07c7338bfb0ef7cb46e78d (diff)
mfd: palmas: Reset pm_power_off if it is set for the device
If Palams supports the system power controller and pm_power_off is implemented through the Palmas driver then reset the pm_power_off in driver remove. This will avoid the call of Palmas driver after removal of driver. Signed-off-by: Laxman Dewangan <ldewangan@nvidia.com> Signed-off-by: Lee Jones <lee.jones@linaro.org>
Diffstat (limited to 'drivers/mfd/palmas.c')
-rw-r--r--drivers/mfd/palmas.c5
1 files changed, 5 insertions, 0 deletions
diff --git a/drivers/mfd/palmas.c b/drivers/mfd/palmas.c
index 3b63139fe563..6aab016f4c37 100644
--- a/drivers/mfd/palmas.c
+++ b/drivers/mfd/palmas.c
@@ -570,6 +570,11 @@ static int palmas_i2c_remove(struct i2c_client *i2c)
570 570
571 regmap_del_irq_chip(palmas->irq, palmas->irq_data); 571 regmap_del_irq_chip(palmas->irq, palmas->irq_data);
572 572
573 if (palmas == palmas_dev) {
574 pm_power_off = NULL;
575 palmas_dev = NULL;
576 }
577
573 return 0; 578 return 0;
574} 579}
575 580