diff options
author | Michał Mirosław <mirq-linux@rere.qmqm.pl> | 2020-08-10 07:33:32 +0300 |
---|---|---|
committer | Mark Brown <broonie@kernel.org> | 2020-09-07 20:35:25 +0300 |
commit | e9c142b0d2c08178a9e146d47d8fe397373bda3e (patch) | |
tree | 02f3ef2859f7d0e6cae992c3c340f6ce636c897a /drivers/regulator/lp8755.c | |
parent | 3bca239d6184df61a619d78764e0481242d844b4 (diff) |
regulator: remove locking around regulator_notifier_call_chain()
regulator_notifier_call_chain() doesn't need rdev lock and rdev's
existence is assumed in the code anyway. Remove the locks from drivers.
Signed-off-by: Michał Mirosław <mirq-linux@rere.qmqm.pl>
Acked-by: Adam Thomson <Adam.Thomson.Opensource@diasemi.com>
Reviewed-by: Dmitry Osipenko <digetx@gmail.com>
Link: https://lore.kernel.org/r/42393f66dcc4d80dcd9797be45216b4035aa96cb.1597032945.git.mirq-linux@rere.qmqm.pl
Signed-off-by: Mark Brown <broonie@kernel.org>
Diffstat (limited to 'drivers/regulator/lp8755.c')
-rw-r--r-- | drivers/regulator/lp8755.c | 6 |
1 files changed, 0 insertions, 6 deletions
diff --git a/drivers/regulator/lp8755.c b/drivers/regulator/lp8755.c index 8cc9963023f2..13c535711265 100644 --- a/drivers/regulator/lp8755.c +++ b/drivers/regulator/lp8755.c @@ -329,11 +329,9 @@ static irqreturn_t lp8755_irq_handler(int irq, void *data) if ((flag0 & (0x4 << icnt)) && (pchip->irqmask & (0x04 << icnt)) && (pchip->rdev[icnt] != NULL)) { - regulator_lock(pchip->rdev[icnt]); regulator_notifier_call_chain(pchip->rdev[icnt], LP8755_EVENT_PWR_FAULT, NULL); - regulator_unlock(pchip->rdev[icnt]); } /* read flag1 register */ @@ -349,22 +347,18 @@ static irqreturn_t lp8755_irq_handler(int irq, void *data) if ((flag1 & 0x01) && (pchip->irqmask & 0x01)) for (icnt = 0; icnt < LP8755_BUCK_MAX; icnt++) if (pchip->rdev[icnt] != NULL) { - regulator_lock(pchip->rdev[icnt]); regulator_notifier_call_chain(pchip->rdev[icnt], LP8755_EVENT_OCP, NULL); - regulator_unlock(pchip->rdev[icnt]); } /* send OVP event to all regulator devices */ if ((flag1 & 0x02) && (pchip->irqmask & 0x02)) for (icnt = 0; icnt < LP8755_BUCK_MAX; icnt++) if (pchip->rdev[icnt] != NULL) { - regulator_lock(pchip->rdev[icnt]); regulator_notifier_call_chain(pchip->rdev[icnt], LP8755_EVENT_OVP, NULL); - regulator_unlock(pchip->rdev[icnt]); } return IRQ_HANDLED; |