diff options
author | Arvind Yadav <arvind.yadav.cs@gmail.com> | 2017-08-20 00:37:55 +0530 |
---|---|---|
committer | Alexandre Belloni <alexandre.belloni@free-electrons.com> | 2017-09-01 01:10:11 +0200 |
commit | 45a63518493ac33506247227d5758bf2318cfbdc (patch) | |
tree | 493fd4f2109ee65b668a8ad50eedc1a5824e05bc /drivers/rtc/rtc-em3027.c | |
parent | ea369ea6d828930c0cf0cacf81f6fd9dff61992d (diff) |
rtc: 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: Alexandre Belloni <alexandre.belloni@free-electrons.com>
Diffstat (limited to 'drivers/rtc/rtc-em3027.c')
-rw-r--r-- | drivers/rtc/rtc-em3027.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/rtc/rtc-em3027.c b/drivers/rtc/rtc-em3027.c index 4f4930a2004c..b0ef8cfe742d 100644 --- a/drivers/rtc/rtc-em3027.c +++ b/drivers/rtc/rtc-em3027.c @@ -132,7 +132,7 @@ static int em3027_probe(struct i2c_client *client, return 0; } -static struct i2c_device_id em3027_id[] = { +static const struct i2c_device_id em3027_id[] = { { "em3027", 0 }, { } }; |