diff options
author | Ye Li <ye.li@nxp.com> | 2017-03-24 16:52:26 +0800 |
---|---|---|
committer | Ye Li <ye.li@nxp.com> | 2017-04-05 19:48:58 +0800 |
commit | ce4339b757d66230adb345e07c08ac0a134d13cc (patch) | |
tree | 994d4844b06d5558b48b76d7c7e5dbdf3c4c160b /drivers | |
parent | e0a78c87a10e46cc651167135d970a27d2ea2273 (diff) | |
download | u-boot-imx-ce4339b757d66230adb345e07c08ac0a134d13cc.zip u-boot-imx-ce4339b757d66230adb345e07c08ac0a134d13cc.tar.gz u-boot-imx-ce4339b757d66230adb345e07c08ac0a134d13cc.tar.bz2 |
MLK-14605 mx7ulp: Modify the lpi2c seq number
Change the i2c alias seq number to align with device index. So in lpi2c
driver we don't need to add 4 to get the device index. This codes may not
valid on other platforms.
Signed-off-by: Ye Li <ye.li@nxp.com>
Diffstat (limited to 'drivers')
-rw-r--r-- | drivers/i2c/imx_lpi2c.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/drivers/i2c/imx_lpi2c.c b/drivers/i2c/imx_lpi2c.c index f792d44..a434ecf 100644 --- a/drivers/i2c/imx_lpi2c.c +++ b/drivers/i2c/imx_lpi2c.c @@ -262,7 +262,7 @@ static int bus_i2c_set_bus_speed(struct udevice *bus, int speed) bool mode; int i; - clock_rate = imx_get_i2cclk(bus->seq + 4); + clock_rate = imx_get_i2cclk(bus->seq); if (!clock_rate) return -EPERM; @@ -419,14 +419,14 @@ static int imx_lpi2c_probe(struct udevice *bus) i2c_bus->bus = bus; /* power up i2c resource */ - ret = init_i2c_power(bus->seq + 4); + ret = init_i2c_power(bus->seq); if (ret) { debug("init_i2c_power err = %d\n", ret); return ret; } /* Enable clk, only i2c4-7 can be handled by A7 core */ - ret = enable_i2c_clk(1, bus->seq + 4); + ret = enable_i2c_clk(1, bus->seq); if (ret < 0) return ret; |