]> git.dujemihanovic.xyz Git - u-boot.git/commitdiff
dm: i2c-uclass-compat: fix missed argument
authorPrzemyslaw Marczak <p.marczak@samsung.com>
Tue, 27 Jan 2015 12:36:28 +0000 (13:36 +0100)
committerSimon Glass <sjg@chromium.org>
Fri, 30 Jan 2015 00:09:59 +0000 (17:09 -0700)
This patch fixes build error for CONFIG_DM_I2C_COMPAT.
In i2c_get_chip_for_busnum() call, one of argument was missed,
which was offset_len. Now it is set to 'alen' as previous.

Signed-off-by: Przemyslaw Marczak <p.marczak@samsung.com>
Acked-by: Simon Glass <sjg@chromium.org>
drivers/i2c/i2c-uclass-compat.c

index 11239da2b997d9568fa3dac488689a5c39fd271c..841ce0510cafc16c917207cc15fba35f0e14ab53 100644 (file)
@@ -17,7 +17,7 @@ static int i2c_compat_get_device(uint chip_addr, int alen,
        struct dm_i2c_chip *chip;
        int ret;
 
-       ret = i2c_get_chip_for_busnum(cur_busnum, chip_addr, devp);
+       ret = i2c_get_chip_for_busnum(cur_busnum, chip_addr, alen, devp);
        if (ret)
                return ret;
        chip = dev_get_parent_platdata(*devp);