mirror of
https://github.com/BobTheBlinker/android_kernel_motorola_sm6375.git
synced 2026-10-29 11:11:45 -04:00
i2c: taos-evm: Make structure tsl2550_info constant
Static structure tsl2550_info, of type i2c_board_info, is referenced only twice: the first time in arguments to dev_info() (which does not modify it) and the second time as the last argument to function i2c_new_device() (where the corresponding parameter is declared as const). As tsl2550_info is therefore never modified, make it const to protect it from unintended modifications. Issue found with Coccinelle. Signed-off-by: Nishka Dasgupta <[email protected]> Reviewed-by: Jean Delvare <[email protected]> Signed-off-by: Wolfram Sang <[email protected]>
This commit is contained in:
parent
70fb95e213
commit
f9bf7a8994
1 changed files with 1 additions and 1 deletions
|
|
@ -39,7 +39,7 @@ struct taos_data {
|
|||
};
|
||||
|
||||
/* TAOS TSL2550 EVM */
|
||||
static struct i2c_board_info tsl2550_info = {
|
||||
static const struct i2c_board_info tsl2550_info = {
|
||||
I2C_BOARD_INFO("tsl2550", 0x39),
|
||||
};
|
||||
|
||||
|
|
|
|||
Loading…
Reference in a new issue