From: Uwe Kleine-König (The Capable Hub) Date: Wed, 13 May 2026 17:23:03 +0000 (+0200) Subject: ASoC: Drop empty i2c remove callbacks X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=2e0389f3689c42091ec153beadc4056ede448a34;p=thirdparty%2Fkernel%2Flinux.git ASoC: Drop empty i2c remove callbacks A remove callback that does nothing has the same semantic (apart from a debug output) as no such callback at all as i2c_device_remove() just does: if (driver->remove) { dev_dbg(dev, "remove\n"); driver->remove(client); } Remove these useless callbacks. While touching the driver structs, unify indention. Signed-off-by: Uwe Kleine-König (The Capable Hub) Link: https://patch.msgid.link/3afd8230634dd68ac7c1885ee2b01da377349f89.1778692164.git.u.kleine-koenig@baylibre.com Signed-off-by: Mark Brown --- diff --git a/sound/soc/codecs/nau8825.c b/sound/soc/codecs/nau8825.c index dd3528537ae42..c6df21b91e369 100644 --- a/sound/soc/codecs/nau8825.c +++ b/sound/soc/codecs/nau8825.c @@ -2930,9 +2930,6 @@ static int nau8825_i2c_probe(struct i2c_client *i2c) &nau8825_dai, 1); } -static void nau8825_i2c_remove(struct i2c_client *client) -{} - static const struct i2c_device_id nau8825_i2c_ids[] = { { "nau8825" }, { } @@ -2962,7 +2959,6 @@ static struct i2c_driver nau8825_driver = { .acpi_match_table = ACPI_PTR(nau8825_acpi_match), }, .probe = nau8825_i2c_probe, - .remove = nau8825_i2c_remove, .id_table = nau8825_i2c_ids, }; module_i2c_driver(nau8825_driver); diff --git a/sound/soc/codecs/rt5616.c b/sound/soc/codecs/rt5616.c index fb9cf127e3ff2..005a2ffe90aec 100644 --- a/sound/soc/codecs/rt5616.c +++ b/sound/soc/codecs/rt5616.c @@ -1386,9 +1386,6 @@ static int rt5616_i2c_probe(struct i2c_client *i2c) rt5616_dai, ARRAY_SIZE(rt5616_dai)); } -static void rt5616_i2c_remove(struct i2c_client *i2c) -{} - static void rt5616_i2c_shutdown(struct i2c_client *client) { struct rt5616_priv *rt5616 = i2c_get_clientdata(client); @@ -1403,7 +1400,6 @@ static struct i2c_driver rt5616_i2c_driver = { .of_match_table = of_match_ptr(rt5616_of_match), }, .probe = rt5616_i2c_probe, - .remove = rt5616_i2c_remove, .shutdown = rt5616_i2c_shutdown, .id_table = rt5616_i2c_id, }; diff --git a/sound/soc/codecs/rt5631.c b/sound/soc/codecs/rt5631.c index 19c6d8f760d9e..2c404a50b120a 100644 --- a/sound/soc/codecs/rt5631.c +++ b/sound/soc/codecs/rt5631.c @@ -1722,16 +1722,12 @@ static int rt5631_i2c_probe(struct i2c_client *i2c) return ret; } -static void rt5631_i2c_remove(struct i2c_client *client) -{} - static struct i2c_driver rt5631_i2c_driver = { .driver = { .name = "rt5631", .of_match_table = of_match_ptr(rt5631_i2c_dt_ids), }, - .probe = rt5631_i2c_probe, - .remove = rt5631_i2c_remove, + .probe = rt5631_i2c_probe, .id_table = rt5631_i2c_id, }; diff --git a/sound/soc/codecs/sta350.c b/sound/soc/codecs/sta350.c index 71af82b099c01..0d36cb06dcede 100644 --- a/sound/soc/codecs/sta350.c +++ b/sound/soc/codecs/sta350.c @@ -1236,9 +1236,6 @@ static int sta350_i2c_probe(struct i2c_client *i2c) return ret; } -static void sta350_i2c_remove(struct i2c_client *client) -{} - static const struct i2c_device_id sta350_i2c_id[] = { { "sta350" }, { } @@ -1250,8 +1247,7 @@ static struct i2c_driver sta350_i2c_driver = { .name = "sta350", .of_match_table = of_match_ptr(st350_dt_ids), }, - .probe = sta350_i2c_probe, - .remove = sta350_i2c_remove, + .probe = sta350_i2c_probe, .id_table = sta350_i2c_id, }; diff --git a/sound/soc/codecs/tas5086.c b/sound/soc/codecs/tas5086.c index 12bf6a89dbd86..36596b00ca693 100644 --- a/sound/soc/codecs/tas5086.c +++ b/sound/soc/codecs/tas5086.c @@ -975,17 +975,13 @@ static int tas5086_i2c_probe(struct i2c_client *i2c) return ret; } -static void tas5086_i2c_remove(struct i2c_client *i2c) -{} - static struct i2c_driver tas5086_i2c_driver = { .driver = { - .name = "tas5086", + .name = "tas5086", .of_match_table = of_match_ptr(tas5086_dt_ids), }, - .id_table = tas5086_i2c_id, - .probe = tas5086_i2c_probe, - .remove = tas5086_i2c_remove, + .id_table = tas5086_i2c_id, + .probe = tas5086_i2c_probe, }; module_i2c_driver(tas5086_i2c_driver); diff --git a/sound/soc/codecs/wm8900.c b/sound/soc/codecs/wm8900.c index fea629541acda..5312eb70dd29b 100644 --- a/sound/soc/codecs/wm8900.c +++ b/sound/soc/codecs/wm8900.c @@ -1286,9 +1286,6 @@ static int wm8900_i2c_probe(struct i2c_client *i2c) return ret; } -static void wm8900_i2c_remove(struct i2c_client *client) -{} - static const struct i2c_device_id wm8900_i2c_id[] = { { "wm8900" }, { } @@ -1299,8 +1296,7 @@ static struct i2c_driver wm8900_i2c_driver = { .driver = { .name = "wm8900", }, - .probe = wm8900_i2c_probe, - .remove = wm8900_i2c_remove, + .probe = wm8900_i2c_probe, .id_table = wm8900_i2c_id, }; #endif diff --git a/sound/soc/codecs/wm9081.c b/sound/soc/codecs/wm9081.c index 5bfe43c6c1f40..521c55280f078 100644 --- a/sound/soc/codecs/wm9081.c +++ b/sound/soc/codecs/wm9081.c @@ -1357,9 +1357,6 @@ static int wm9081_i2c_probe(struct i2c_client *i2c) return 0; } -static void wm9081_i2c_remove(struct i2c_client *client) -{} - static const struct i2c_device_id wm9081_i2c_id[] = { { "wm9081" }, { } @@ -1370,8 +1367,7 @@ static struct i2c_driver wm9081_i2c_driver = { .driver = { .name = "wm9081", }, - .probe = wm9081_i2c_probe, - .remove = wm9081_i2c_remove, + .probe = wm9081_i2c_probe, .id_table = wm9081_i2c_id, };