[PATCH v3 09/23] mfd: Drop unused assignment of platform_device_id driver data
Uwe Kleine-König (The Capable Hub) <[email protected]> Thu, 9 Jul 2026 18:58:28 +0200
| Newsgroups | dev.linux.lists.chrome-platform,dev.linux.lists.mfd,org.infradead.lists.linux-arm-kernel,org.infradead.lists.linux-mediatek,org.kernel.vger.linux-kernel |
|---|---|
| Message-ID | <8f219a01ab8fb705f3da3b2bff4b1228d657b3c0.1783615311.git.u.kleine-koenig@baylibre.com> |
The drivers explicitly set the .driver_data member of struct platform_device_id to zero without relying on that value. Drop these unused assignments This patch doesn't modify the compiled arrays, only their representation in source form benefits. Signed-off-by: Uwe Kleine-König (The Capable Hub) <[email protected]> --- drivers/mfd/cros_ec_dev.c | 2 +- drivers/mfd/mt6397-core.c | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/drivers/mfd/cros_ec_dev.c b/drivers/mfd/cros_ec_dev.c index e253c753beb6..a933cb936da6 100644 --- a/drivers/mfd/cros_ec_dev.c +++ b/drivers/mfd/cros_ec_dev.c @@ -375,7 +375,7 @@ static void ec_device_remove(struct platform_device *pdev) } static const struct platform_device_id cros_ec_id[] = { - { DRV_NAME, 0 }, + { DRV_NAME }, { /* sentinel */ } }; MODULE_DEVICE_TABLE(platform, cros_ec_id); diff --git a/drivers/mfd/mt6397-core.c b/drivers/mfd/mt6397-core.c index ea1d039477e3..7987583afc60 100644 --- a/drivers/mfd/mt6397-core.c +++ b/drivers/mfd/mt6397-core.c @@ -429,7 +429,7 @@ static const struct of_device_id mt6397_of_match[] = { MODULE_DEVICE_TABLE(of, mt6397_of_match); static const struct platform_device_id mt6397_id[] = { - { "mt6397", 0 }, + { "mt6397" }, { }, }; MODULE_DEVICE_TABLE(platform, mt6397_id); -- 2.55.0.11.g153666a7d9bb