diff options
author | Ben Hutchings <bhutchings@solarflare.com> | 2009-04-13 11:02:14 -0400 |
---|---|---|
committer | Jean Delvare <khali@linux-fr.org> | 2009-04-13 11:02:14 -0400 |
commit | c758e8cffe3b1bc7970d579371db01b19ff440bf (patch) | |
tree | 12ebe93ed86da0f906ed49e10198ee3db6158c8c /include/linux/i2c.h | |
parent | 3f307fb37a6dd65b7eabda9c6208a9bd161dc16e (diff) |
i2c: Fix sparse warnings for I2C_BOARD_INFO()
Since the first argument to I2C_BOARD_INFO() must be a string constant,
there is no need to parenthesise it, and adding parentheses results in
an invalid initialiser for char[]. gcc obviously accepts this syntax as
an extension, but sparse complains, e.g.:
drivers/net/sfc/boards.c:173:2: warning: array initialized from parenthesized string constant
Therefore, remove the parentheses.
Signed-off-by: Ben Hutchings <bhutchings@solarflare.com>
Signed-off-by: Jean Delvare <khali@linux-fr.org>
Diffstat (limited to 'include/linux/i2c.h')
-rw-r--r-- | include/linux/i2c.h | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/include/linux/i2c.h b/include/linux/i2c.h index 00ee11eb9092..ad2580596033 100644 --- a/include/linux/i2c.h +++ b/include/linux/i2c.h | |||
@@ -274,7 +274,7 @@ struct i2c_board_info { | |||
274 | * are provided using conventional syntax. | 274 | * are provided using conventional syntax. |
275 | */ | 275 | */ |
276 | #define I2C_BOARD_INFO(dev_type, dev_addr) \ | 276 | #define I2C_BOARD_INFO(dev_type, dev_addr) \ |
277 | .type = (dev_type), .addr = (dev_addr) | 277 | .type = dev_type, .addr = (dev_addr) |
278 | 278 | ||
279 | 279 | ||
280 | /* Add-on boards should register/unregister their devices; e.g. a board | 280 | /* Add-on boards should register/unregister their devices; e.g. a board |