1

eeprom: Drop explicit initialization of struct i2c_device_id::driver_data to 0

These drivers don't use the driver_data member of struct i2c_device_id,
so don't explicitly initialize this member.

This prepares putting driver_data in an anonymous union which requires
either no initialization or named designators. But it's also a nice
cleanup on its own.

Signed-off-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de>
Link: https://lore.kernel.org/r/20240510211454.2274614-2-u.kleine-koenig@pengutronix.de
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
This commit is contained in:
Uwe Kleine-König 2024-05-10 23:14:54 +02:00 committed by Greg Kroah-Hartman
parent 83f939f4d4
commit 10724d5d47
3 changed files with 50 additions and 50 deletions

View File

@ -52,7 +52,7 @@ static struct ee1004_bus_data {
} ee1004_bus_data[EE1004_MAX_BUSSES];
static const struct i2c_device_id ee1004_ids[] = {
{ "ee1004", 0 },
{ "ee1004" },
{ }
};
MODULE_DEVICE_TABLE(i2c, ee1004_ids);

View File

@ -1426,58 +1426,58 @@ MODULE_DEVICE_TABLE(i2c, ee_ids);
* idt_ids - supported IDT 89HPESx devices
*/
static const struct i2c_device_id idt_ids[] = {
{ "89hpes8nt2", 0 },
{ "89hpes12nt3", 0 },
{ "89hpes8nt2" },
{ "89hpes12nt3" },
{ "89hpes24nt6ag2", 0 },
{ "89hpes32nt8ag2", 0 },
{ "89hpes32nt8bg2", 0 },
{ "89hpes12nt12g2", 0 },
{ "89hpes16nt16g2", 0 },
{ "89hpes24nt24g2", 0 },
{ "89hpes32nt24ag2", 0 },
{ "89hpes32nt24bg2", 0 },
{ "89hpes24nt6ag2" },
{ "89hpes32nt8ag2" },
{ "89hpes32nt8bg2" },
{ "89hpes12nt12g2" },
{ "89hpes16nt16g2" },
{ "89hpes24nt24g2" },
{ "89hpes32nt24ag2" },
{ "89hpes32nt24bg2" },
{ "89hpes12n3", 0 },
{ "89hpes12n3a", 0 },
{ "89hpes24n3", 0 },
{ "89hpes24n3a", 0 },
{ "89hpes12n3" },
{ "89hpes12n3a" },
{ "89hpes24n3" },
{ "89hpes24n3a" },
{ "89hpes32h8", 0 },
{ "89hpes32h8g2", 0 },
{ "89hpes48h12", 0 },
{ "89hpes48h12g2", 0 },
{ "89hpes48h12ag2", 0 },
{ "89hpes16h16", 0 },
{ "89hpes22h16", 0 },
{ "89hpes22h16g2", 0 },
{ "89hpes34h16", 0 },
{ "89hpes34h16g2", 0 },
{ "89hpes64h16", 0 },
{ "89hpes64h16g2", 0 },
{ "89hpes64h16ag2", 0 },
{ "89hpes32h8" },
{ "89hpes32h8g2" },
{ "89hpes48h12" },
{ "89hpes48h12g2" },
{ "89hpes48h12ag2" },
{ "89hpes16h16" },
{ "89hpes22h16" },
{ "89hpes22h16g2" },
{ "89hpes34h16" },
{ "89hpes34h16g2" },
{ "89hpes64h16" },
{ "89hpes64h16g2" },
{ "89hpes64h16ag2" },
/* { "89hpes3t3", 0 }, // No SMBus-slave iface */
{ "89hpes12t3g2", 0 },
{ "89hpes24t3g2", 0 },
/* { "89hpes4t4", 0 }, // No SMBus-slave iface */
{ "89hpes16t4", 0 },
{ "89hpes4t4g2", 0 },
{ "89hpes10t4g2", 0 },
{ "89hpes16t4g2", 0 },
{ "89hpes16t4ag2", 0 },
{ "89hpes5t5", 0 },
{ "89hpes6t5", 0 },
{ "89hpes8t5", 0 },
{ "89hpes8t5a", 0 },
{ "89hpes24t6", 0 },
{ "89hpes6t6g2", 0 },
{ "89hpes24t6g2", 0 },
{ "89hpes16t7", 0 },
{ "89hpes32t8", 0 },
{ "89hpes32t8g2", 0 },
{ "89hpes48t12", 0 },
{ "89hpes48t12g2", 0 },
/* { "89hpes3t3" }, // No SMBus-slave iface */
{ "89hpes12t3g2" },
{ "89hpes24t3g2" },
/* { "89hpes4t4" }, // No SMBus-slave iface */
{ "89hpes16t4" },
{ "89hpes4t4g2" },
{ "89hpes10t4g2" },
{ "89hpes16t4g2" },
{ "89hpes16t4ag2" },
{ "89hpes5t5" },
{ "89hpes6t5" },
{ "89hpes8t5" },
{ "89hpes8t5a" },
{ "89hpes24t6" },
{ "89hpes6t6g2" },
{ "89hpes24t6g2" },
{ "89hpes16t7" },
{ "89hpes32t8" },
{ "89hpes32t8g2" },
{ "89hpes48t12" },
{ "89hpes48t12g2" },
{ /* END OF LIST */ }
};
MODULE_DEVICE_TABLE(i2c, idt_ids);

View File

@ -183,7 +183,7 @@ static void max6875_remove(struct i2c_client *client)
}
static const struct i2c_device_id max6875_id[] = {
{ "max6875", 0 },
{ "max6875" },
{ }
};
MODULE_DEVICE_TABLE(i2c, max6875_id);