summaryrefslogtreecommitdiffstats
path: root/drivers/misc
diff options
context:
space:
mode:
authorArvind Yadav <arvind.yadav.cs@gmail.com>2017-08-21 22:13:26 +0530
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>2017-08-28 16:55:49 +0200
commitb8dbb5024b5e62704caac6915f0f5f33448b8b05 (patch)
tree96b41d28b2ff05e0723428f37cb1263823ae5074 /drivers/misc
parent07e4049ae0b2abc6b9c7226af5eb802380976bae (diff)
downloadlinux-stable-b8dbb5024b5e62704caac6915f0f5f33448b8b05.tar.gz
linux-stable-b8dbb5024b5e62704caac6915f0f5f33448b8b05.tar.bz2
linux-stable-b8dbb5024b5e62704caac6915f0f5f33448b8b05.zip
misc: hmc6352: constify i2c_device_id
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: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'drivers/misc')
-rw-r--r--drivers/misc/hmc6352.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/misc/hmc6352.c b/drivers/misc/hmc6352.c
index 90520d76633f..eeb7eef62174 100644
--- a/drivers/misc/hmc6352.c
+++ b/drivers/misc/hmc6352.c
@@ -132,7 +132,7 @@ static int hmc6352_remove(struct i2c_client *client)
return 0;
}
-static struct i2c_device_id hmc6352_id[] = {
+static const struct i2c_device_id hmc6352_id[] = {
{ "hmc6352", 0 },
{ }
};