]> git.dujemihanovic.xyz Git - u-boot.git/commitdiff
i2c: kona: Resolve Kona I2C driver issue
authorSteve Rae <srae@broadcom.com>
Mon, 26 May 2014 19:33:29 +0000 (12:33 -0700)
committerHeiko Schocher <hs@denx.de>
Thu, 12 Jun 2014 09:42:50 +0000 (11:42 +0200)
- "i2c mw" command hangs (with some compilers)

Signed-off-by: Steve Rae <srae@broadcom.com>
drivers/i2c/kona_i2c.c

index 0b1715abf0dffb69cf9cc2ae18b5650aa949dc89..5eab338cfc470fbc57ae1fd4cff2166d122fa536 100644 (file)
@@ -663,7 +663,7 @@ static int kona_i2c_read(struct i2c_adapter *adap, uchar chip, uint addr,
 static int kona_i2c_write(struct i2c_adapter *adap, uchar chip, uint addr,
                          int alen, uchar *buffer, int len)
 {
-       struct i2c_msg msg[0];
+       struct i2c_msg msg[1];
        unsigned char msgbuf0[64];
        unsigned int i;
        struct bcm_kona_i2c_dev *dev = kona_get_dev(adap);