]> git.baikalelectronics.ru Git - kernel.git/commit
mfd: lp8788: Fix an error handling path in lp8788_probe()
authorChristophe JAILLET <christophe.jaillet@wanadoo.fr>
Sun, 31 Jul 2022 09:55:27 +0000 (11:55 +0200)
committerLee Jones <lee@kernel.org>
Wed, 28 Sep 2022 15:09:50 +0000 (16:09 +0100)
commitc4c79cd79826445a5a39a011c23b4bb8fe611f47
treedcdeb8b6bb2649ea6a2cb0cf6daf094e0618b113
parent9c91ee9a5117299793805e3e602c47c8dfad679a
mfd: lp8788: Fix an error handling path in lp8788_probe()

Should an error occurs in mfd_add_devices(), some resources need to be
released, as already done in the .remove() function.

Add an error handling path and a lp8788_irq_exit() call to undo a previous
lp8788_irq_init().

Fixes: 0ea14a49e360 ("mfd: Add lp8788 mfd driver")
Signed-off-by: Christophe JAILLET <christophe.jaillet@wanadoo.fr>
Signed-off-by: Lee Jones <lee@kernel.org>
Link: https://lore.kernel.org/r/18398722da9df9490722d853e4797350189ae79b.1659261275.git.christophe.jaillet@wanadoo.fr
drivers/mfd/lp8788.c