Commit 8bd75bd3 authored by Shouming Wang's avatar Shouming Wang Committed by Wolfram Sang

i2c: pxa: Return I2C_RETRY when timeout in pio mode

In case of timeout in pio mode of operation return I2C_RETRY.
This behavior will be same as interrupt mode of operation.
Signed-off-by: default avatarShouming Wang <wangshm@marvell.com>
[vaibhav.hiremath@linaro.org: Updated changelog]
Signed-off-by: default avatarVaibhav Hiremath <vaibhav.hiremath@linaro.org>
Acked-by: default avatarRobert Jarzmik <robert.jarzmik@free.fr>
Signed-off-by: default avatarWolfram Sang <wsa@the-dreams.de>
parent e087b427
...@@ -745,8 +745,10 @@ static int i2c_pxa_do_pio_xfer(struct pxa_i2c *i2c, ...@@ -745,8 +745,10 @@ static int i2c_pxa_do_pio_xfer(struct pxa_i2c *i2c,
ret = i2c->msg_idx; ret = i2c->msg_idx;
out: out:
if (timeout == 0) if (timeout == 0) {
i2c_pxa_scream_blue_murder(i2c, "timeout"); i2c_pxa_scream_blue_murder(i2c, "timeout");
ret = I2C_RETRY;
}
return ret; return ret;
} }
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment