Skip to content

Commit 19a0115

Browse files
ukleinekcminyard
authored andcommitted
ipmi: 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. While at it, also remove commas after the sentinel entries. Signed-off-by: Uwe Kleine-König <[email protected]> Message-Id: <[email protected]> Signed-off-by: Corey Minyard <[email protected]>
1 parent 0627cef commit 19a0115

File tree

4 files changed

+7
-7
lines changed

4 files changed

+7
-7
lines changed

drivers/char/ipmi/ipmb_dev_int.c

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -350,8 +350,8 @@ static void ipmb_remove(struct i2c_client *client)
350350
}
351351

352352
static const struct i2c_device_id ipmb_id[] = {
353-
{ "ipmb-dev", 0 },
354-
{},
353+
{ "ipmb-dev" },
354+
{}
355355
};
356356
MODULE_DEVICE_TABLE(i2c, ipmb_id);
357357

drivers/char/ipmi/ipmi_ipmb.c

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -561,8 +561,8 @@ MODULE_DEVICE_TABLE(of, of_ipmi_ipmb_match);
561561
#endif
562562

563563
static const struct i2c_device_id ipmi_ipmb_id[] = {
564-
{ DEVICE_NAME, 0 },
565-
{},
564+
{ DEVICE_NAME },
565+
{}
566566
};
567567
MODULE_DEVICE_TABLE(i2c, ipmi_ipmb_id);
568568

drivers/char/ipmi/ipmi_ssif.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2049,7 +2049,7 @@ static int dmi_ipmi_probe(struct platform_device *pdev)
20492049
#endif
20502050

20512051
static const struct i2c_device_id ssif_id[] = {
2052-
{ DEVICE_NAME, 0 },
2052+
{ DEVICE_NAME },
20532053
{ }
20542054
};
20552055
MODULE_DEVICE_TABLE(i2c, ssif_id);

drivers/char/ipmi/ssif_bmc.c

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -852,8 +852,8 @@ static const struct of_device_id ssif_bmc_match[] = {
852852
MODULE_DEVICE_TABLE(of, ssif_bmc_match);
853853

854854
static const struct i2c_device_id ssif_bmc_id[] = {
855-
{ DEVICE_NAME, 0 },
856-
{ },
855+
{ DEVICE_NAME },
856+
{ }
857857
};
858858
MODULE_DEVICE_TABLE(i2c, ssif_bmc_id);
859859

0 commit comments

Comments
 (0)