aboutsummaryrefslogtreecommitdiff
path: root/drivers/iio/proximity
diff options
context:
space:
mode:
authorUwe Kleine-König <u.kleine-koenig@pengutronix.de>2024-05-08 09:29:27 +0200
committerJonathan Cameron <Jonathan.Cameron@huawei.com>2024-05-27 09:48:57 +0100
commit4391affa107d68b6c3e5222264e91bbc21793cf0 (patch)
treee363852fcd7ba512469b2fb889c536c06297c53d /drivers/iio/proximity
parent1b5a2466b72e1afe550c8568e072f6b2af1698d5 (diff)
iio: 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 add it, also remove commas after the sentinel entries. Signed-off-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de> Link: https://lore.kernel.org/r/20240508072928.2135858-2-u.kleine-koenig@pengutronix.de Signed-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>
Diffstat (limited to 'drivers/iio/proximity')
-rw-r--r--drivers/iio/proximity/isl29501.c2
-rw-r--r--drivers/iio/proximity/pulsedlight-lidar-lite-v2.c6
-rw-r--r--drivers/iio/proximity/rfd77402.c2
-rw-r--r--drivers/iio/proximity/sx9500.c4
-rw-r--r--drivers/iio/proximity/vl53l0x-i2c.c2
5 files changed, 8 insertions, 8 deletions
diff --git a/drivers/iio/proximity/isl29501.c b/drivers/iio/proximity/isl29501.c
index 4982686fb4c3..dc66ca9bba6b 100644
--- a/drivers/iio/proximity/isl29501.c
+++ b/drivers/iio/proximity/isl29501.c
@@ -989,7 +989,7 @@ static int isl29501_probe(struct i2c_client *client)
}
static const struct i2c_device_id isl29501_id[] = {
- {"isl29501", 0},
+ { "isl29501" },
{}
};
diff --git a/drivers/iio/proximity/pulsedlight-lidar-lite-v2.c b/drivers/iio/proximity/pulsedlight-lidar-lite-v2.c
index 2913d5e0fe4f..5c959730aecd 100644
--- a/drivers/iio/proximity/pulsedlight-lidar-lite-v2.c
+++ b/drivers/iio/proximity/pulsedlight-lidar-lite-v2.c
@@ -322,9 +322,9 @@ static void lidar_remove(struct i2c_client *client)
}
static const struct i2c_device_id lidar_id[] = {
- {"lidar-lite-v2", 0},
- {"lidar-lite-v3", 0},
- { },
+ { "lidar-lite-v2" },
+ { "lidar-lite-v3" },
+ { }
};
MODULE_DEVICE_TABLE(i2c, lidar_id);
diff --git a/drivers/iio/proximity/rfd77402.c b/drivers/iio/proximity/rfd77402.c
index f02e83e3f15f..aff60a3c1a6f 100644
--- a/drivers/iio/proximity/rfd77402.c
+++ b/drivers/iio/proximity/rfd77402.c
@@ -308,7 +308,7 @@ static DEFINE_SIMPLE_DEV_PM_OPS(rfd77402_pm_ops, rfd77402_suspend,
rfd77402_resume);
static const struct i2c_device_id rfd77402_id[] = {
- { "rfd77402", 0 },
+ { "rfd77402" },
{ }
};
MODULE_DEVICE_TABLE(i2c, rfd77402_id);
diff --git a/drivers/iio/proximity/sx9500.c b/drivers/iio/proximity/sx9500.c
index 550e7d3cd5ee..b89d49defd7a 100644
--- a/drivers/iio/proximity/sx9500.c
+++ b/drivers/iio/proximity/sx9500.c
@@ -1043,8 +1043,8 @@ static const struct of_device_id sx9500_of_match[] = {
MODULE_DEVICE_TABLE(of, sx9500_of_match);
static const struct i2c_device_id sx9500_id[] = {
- {"sx9500", 0},
- { },
+ { "sx9500" },
+ { }
};
MODULE_DEVICE_TABLE(i2c, sx9500_id);
diff --git a/drivers/iio/proximity/vl53l0x-i2c.c b/drivers/iio/proximity/vl53l0x-i2c.c
index 2cea64bea909..8d4f3f849fe2 100644
--- a/drivers/iio/proximity/vl53l0x-i2c.c
+++ b/drivers/iio/proximity/vl53l0x-i2c.c
@@ -278,7 +278,7 @@ static int vl53l0x_probe(struct i2c_client *client)
}
static const struct i2c_device_id vl53l0x_id[] = {
- { "vl53l0x", 0 },
+ { "vl53l0x" },
{ }
};
MODULE_DEVICE_TABLE(i2c, vl53l0x_id);