提交 7a36ceb2 编写于 作者: L Lee Jones

mfd: 88pm860x-i2c: Fix variable length array Sparse warning

drivers/mfd/88pm860x-i2c.c:125:33:
  warning: Variable length array is used.
Signed-off-by: NLee Jones <lee.jones@linaro.org>
上级 260a127b
...@@ -122,7 +122,7 @@ static int read_device(struct i2c_client *i2c, int reg, ...@@ -122,7 +122,7 @@ static int read_device(struct i2c_client *i2c, int reg,
static int write_device(struct i2c_client *i2c, int reg, static int write_device(struct i2c_client *i2c, int reg,
int bytes, void *src) int bytes, void *src)
{ {
unsigned char buf[bytes + 1]; unsigned char buf[2];
struct i2c_adapter *adap = i2c->adapter; struct i2c_adapter *adap = i2c->adapter;
struct i2c_msg msg; struct i2c_msg msg;
int ret; int ret;
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册