i2c: mxc_i2c: Remove i2c_idle_bus from probe
Subsystems (2)
PATCH 2/2 i2c: mxc_i2c: Remove i2c_idle_bus from probe
i2c_idle_bus is already used in i2c_init_transfer. So before each tranfer if the bus is not ready, the i2c_idle_bus will be used to force idle. It is unnecessary to call it again in probe.
We found a issue when enabling i2c mux with the mxc_i2c. The mxc_i2c is probed after mux probing. However, at this moment the mux is still in idle state not select any port. So if we call i2c_idle_bus in probe, it will fail and cause mxc_i2c probe failed.
--- drivers/i2c/mxc_i2c.c | 7 ------- 1 file changed, 7 deletions(-)
drivers/i2c/mxc_i2c.c +0 -7
@@ -916,13 +916,6 @@ static int mxc_i2c_probe(struct udevice *bus) } } - ret =i2c_idle_bus (i2c_bus); -if (ret <0 ) { -/* Disable clk */ -enable_i2c_clk (0 , bus->seq); -return ret; - } -/* * Pinmux settings are in board file now, until pinmux is supported, * we can set pinmux here in probe function.
Signature · 1 line
2.7.4
PATCH 2/2 i2c: mxc_i2c: Remove i2c_idle_bus from probe
Hello Ye Li,
Am 10.07.2019 um 12:24 schrieb Ye Li:
Quoted 9 lines
i2c_idle_busis already used ini2c_init_transfer. So before each tranfer if the bus is not ready, thei2c_idle_buswill be used to force idle. It is unnecessary to call it again in probe.We found a issue when enabling i2c mux with the
mxc_i2c. Themxc_i2cis probed after mux probing. However, at this moment the mux is still in idle state not select any port. So if we calli2c_idle_busin probe, it will fail and causemxc_i2cprobe failed.
Quoted 4 lines
Signed-off-by Ye Li <[email protected]>--- drivers/i2c/mxc_i2c.c | 7 ------- 1 file changed, 7 deletions(-)
Applied to u-boot-i2c master
Thanks!
bye,
Heiko
Signature · 3 lines
DENX Software Engineering GmbH, Managing Director: Wolfgang Denk HRB 165235 Munich, Office: Kirchenstr.5, D-82194 Groebenzell, Germany Phone: +49-8142-66989-52 Fax: +49-8142-66989-80 Email: hs at denx.de