From: Christophe JAILLET Date: Sat, 25 Oct 2025 11:27:16 +0000 (+0200) Subject: mfd: da9055: Simplify the error handling path in da9055_device_init() X-Git-Tag: v6.19-rc1~142^2~27 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=049929c5a159c8671b9b0c12a7da963fef535b00;p=thirdparty%2Flinux.git mfd: da9055: Simplify the error handling path in da9055_device_init() If mfd_add_devices() fails, there is no need to call mfd_remove_devices(). The needed clean-up is already done in the error handling path of mfd_add_devices(). So, remove the unneeded (and harmless) call. Signed-off-by: Christophe JAILLET Link: https://patch.msgid.link/871f52e7ab5d12853bc39f36ac78b5a8e484d863.1761391599.git.christophe.jaillet@wanadoo.fr Signed-off-by: Lee Jones --- diff --git a/drivers/mfd/da9055-core.c b/drivers/mfd/da9055-core.c index 8c989b74f924e..158590ad37d45 100644 --- a/drivers/mfd/da9055-core.c +++ b/drivers/mfd/da9055-core.c @@ -387,7 +387,6 @@ int da9055_device_init(struct da9055 *da9055) return 0; err: - mfd_remove_devices(da9055->dev); regmap_del_irq_chip(da9055->chip_irq, da9055->irq_data); return ret; }