]> git.ipfire.org Git - thirdparty/linux.git/commit
irqchip/ts4800: Convert to platform_driver::remove_new() callback
authorUwe Kleine-König <u.kleine-koenig@pengutronix.de>
Fri, 22 Dec 2023 22:50:44 +0000 (23:50 +0100)
committerThomas Gleixner <tglx@linutronix.de>
Tue, 27 Feb 2024 17:12:11 +0000 (18:12 +0100)
commitf7f56d59a3923e95bad2c49615a4d7313ed78314
tree657eccd726458652ab4481632a90e90eed0e538a
parent935603e8199991ac1f72c47a41a558f43f1a6004
irqchip/ts4800: Convert to platform_driver::remove_new() callback

The .remove() callback for a platform driver returns an int which makes
many driver authors wrongly assume it's possible to do error handling by
returning an error code. However the value returned is ignored (apart
from emitting a warning) and this typically results in resource leaks.

To improve here there is a quest to make the remove callback return
void. In the first step of this quest all drivers are converted to
.remove_new(), which already returns void. Eventually after all drivers
are converted, .remove_new() will be renamed to .remove().

Trivially convert this driver from always returning zero in the remove
callback to the void returning variant.

Signed-off-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de>
Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
Link: https://lore.kernel.org/r/0bdce86b50e5aa50cffbc4add332cbfbad87521e.1703284359.git.u.kleine-koenig@pengutronix.de
drivers/irqchip/irq-ts4800.c