diff options
| -rw-r--r-- | drivers/regulator/da9210-regulator.c | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/drivers/regulator/da9210-regulator.c b/drivers/regulator/da9210-regulator.c index b3517830edb6..cfd6e8af67ec 100644 --- a/drivers/regulator/da9210-regulator.c +++ b/drivers/regulator/da9210-regulator.c | |||
| @@ -132,6 +132,8 @@ static irqreturn_t da9210_irq_handler(int irq, void *data) | |||
| 132 | if (error < 0) | 132 | if (error < 0) |
| 133 | goto error_i2c; | 133 | goto error_i2c; |
| 134 | 134 | ||
| 135 | mutex_lock(&chip->rdev->mutex); | ||
| 136 | |||
| 135 | if (val & DA9210_E_OVCURR) { | 137 | if (val & DA9210_E_OVCURR) { |
| 136 | regulator_notifier_call_chain(chip->rdev, | 138 | regulator_notifier_call_chain(chip->rdev, |
| 137 | REGULATOR_EVENT_OVER_CURRENT, | 139 | REGULATOR_EVENT_OVER_CURRENT, |
| @@ -155,6 +157,9 @@ static irqreturn_t da9210_irq_handler(int irq, void *data) | |||
| 155 | NULL); | 157 | NULL); |
| 156 | handled |= DA9210_E_VMAX; | 158 | handled |= DA9210_E_VMAX; |
| 157 | } | 159 | } |
| 160 | |||
| 161 | mutex_unlock(&chip->rdev->mutex); | ||
| 162 | |||
| 158 | if (handled) { | 163 | if (handled) { |
| 159 | /* Clear handled events */ | 164 | /* Clear handled events */ |
| 160 | error = regmap_write(chip->regmap, DA9210_REG_EVENT_B, handled); | 165 | error = regmap_write(chip->regmap, DA9210_REG_EVENT_B, handled); |
