summaryrefslogtreecommitdiffstats
path: root/common
diff options
context:
space:
mode:
authorSimon Glass <sjg@chromium.org>2015-01-25 08:26:55 -0700
committerSimon Glass <sjg@chromium.org>2015-01-29 17:09:53 -0700
commit25ab4b0303f2df5e6b94ed92e37875a7c98f4de3 (patch)
treef8fecc4b22da4c7fe5c4e6d6a6623459e255af47 /common
parent73845350b6281a7afeeb279475e6eb613d7a89f9 (diff)
downloadtalos-obmc-uboot-25ab4b0303f2df5e6b94ed92e37875a7c98f4de3.tar.gz
talos-obmc-uboot-25ab4b0303f2df5e6b94ed92e37875a7c98f4de3.zip
dm: i2c: Provide an offset length parameter where needed
Rather than assuming that the chip offset length is 1, allow it to be provided. This allows chips that don't use the default offset length to be used (at present they are only supported by the command line 'i2c' command which sets the offset length explicitly). Signed-off-by: Simon Glass <sjg@chromium.org> Acked-by: Heiko Schocher <hs@denx.de>
Diffstat (limited to 'common')
-rw-r--r--common/cmd_i2c.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/common/cmd_i2c.c b/common/cmd_i2c.c
index 1e500fbf2c..7c3ad00fdf 100644
--- a/common/cmd_i2c.c
+++ b/common/cmd_i2c.c
@@ -168,7 +168,7 @@ static int i2c_get_cur_bus_chip(uint chip_addr, struct udevice **devp)
if (ret)
return ret;
- return i2c_get_chip(bus, chip_addr, devp);
+ return i2c_get_chip(bus, chip_addr, 1, devp);
}
#endif
OpenPOWER on IntegriCloud