hwmon: (ftsteutates) constify i2c_device_id
authorArvind Yadav <arvind.yadav.cs@gmail.com>
Sat, 19 Aug 2017 19:26:34 +0000 (00:56 +0530)
committerGuenter Roeck <linux@roeck-us.net>
Wed, 30 Aug 2017 00:44:23 +0000 (17:44 -0700)
i2c_device_id are not supposed to change at runtime. All functions
working with i2c_device_id provided by <linux/i2c.h> work with
const i2c_device_id. So mark the non-const structs as const.

Signed-off-by: Arvind Yadav <arvind.yadav.cs@gmail.com>
Signed-off-by: Guenter Roeck <linux@roeck-us.net>
drivers/hwmon/ftsteutates.c

index a0fb9e9291f023bb6a7c9471566a9bc35527a62b..0801f48a41f7e6845703f1859a0a3358316811ef 100644 (file)
@@ -60,7 +60,7 @@
 
 static const unsigned short normal_i2c[] = { 0x73, I2C_CLIENT_END };
 
-static struct i2c_device_id fts_id[] = {
+static const struct i2c_device_id fts_id[] = {
        { "ftsteutates", 0 },
        { }
 };