diff mbox series

drm/i2c/sil164: Drop no-op remove function

Message ID 20220526202538.1723142-1-u.kleine-koenig@pengutronix.de (mailing list archive)
State Handled Elsewhere, archived
Commit eb09882d64807c24228ed1d005dbbae70860ca3f
Headers show
Series drm/i2c/sil164: Drop no-op remove function | expand

Commit Message

Uwe Kleine-König May 26, 2022, 8:25 p.m. UTC
A remove callback that just returns 0 is equivalent to no callback at all
as can be seen in i2c_device_remove(). So simplify accordingly.

Signed-off-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de>
---
 drivers/gpu/drm/i2c/sil164_drv.c | 7 -------
 1 file changed, 7 deletions(-)


base-commit: 4b0986a3613c92f4ec1bdc7f60ec66fea135991f

Comments

Uwe Kleine-König June 9, 2022, 9:18 a.m. UTC | #1
Hello,

On Thu, May 26, 2022 at 10:25:38PM +0200, Uwe Kleine-König wrote:
> A remove callback that just returns 0 is equivalent to no callback at all
> as can be seen in i2c_device_remove(). So simplify accordingly.

I intend to change the prototype of i2c remove callbacks to return void
after the next merge window. This patch is a preparation for that quest.

So I ask you to either take this patch to sil164_drv.c before (my
preferred option), or accept that I send it as part of a bigger series
that will probably be merged via the i2c tree.

See
https://lore.kernel.org/linux-i2c/20220609091018.q52fhowlsdbdkct5@pengutronix.de
for some more details.

Best regards
Uwe
diff mbox series

Patch

diff --git a/drivers/gpu/drm/i2c/sil164_drv.c b/drivers/gpu/drm/i2c/sil164_drv.c
index 741886b54419..1bc0b5de4499 100644
--- a/drivers/gpu/drm/i2c/sil164_drv.c
+++ b/drivers/gpu/drm/i2c/sil164_drv.c
@@ -370,12 +370,6 @@  sil164_probe(struct i2c_client *client, const struct i2c_device_id *id)
 	return 0;
 }
 
-static int
-sil164_remove(struct i2c_client *client)
-{
-	return 0;
-}
-
 static struct i2c_client *
 sil164_detect_slave(struct i2c_client *client)
 {
@@ -427,7 +421,6 @@  MODULE_DEVICE_TABLE(i2c, sil164_ids);
 static struct drm_i2c_encoder_driver sil164_driver = {
 	.i2c_driver = {
 		.probe = sil164_probe,
-		.remove = sil164_remove,
 		.driver = {
 			.name = "sil164",
 		},