diff options
author | Ismael Luceno Cortes <ismael.luceno@silicon-gears.com> | 2019-03-07 18:00:53 +0000 |
---|---|---|
committer | Heiko Schocher <hs@denx.de> | 2019-03-08 05:53:23 +0100 |
commit | ff4035be9bd1ef60f5cf772539304ac1ee728fbb (patch) | |
tree | 66dcd0259519df2f0c2964ccf9a479bdda06645a /drivers | |
parent | 3ad31eb1cc6ed4b9a54529df5a30c8321a0ec0de (diff) |
i2c: rcar_i2c: Don't mask errors with EREMOTEIO at rcar_i2c_xfer
Fix rcar_i2c_xfer return value, previously it was always returning
-EREMOTEIO when dealing with errors from calls to the read/write
functions.
Signed-off-by: Ismael Luceno <ismael.luceno@silicon-gears.com>
Reviewed-by: Marek Vasut <marek.vasut+renesas@gmail.com>
Reviewed-by: Heiko Schocher <hs@denx.de>
Diffstat (limited to 'drivers')
-rw-r--r-- | drivers/i2c/rcar_i2c.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/i2c/rcar_i2c.c b/drivers/i2c/rcar_i2c.c index a88fbcf34f..9223eaecbf 100644 --- a/drivers/i2c/rcar_i2c.c +++ b/drivers/i2c/rcar_i2c.c @@ -221,7 +221,7 @@ static int rcar_i2c_xfer(struct udevice *dev, struct i2c_msg *msg, int nmsgs) ret = rcar_i2c_write_common(dev, msg); if (ret) - return -EREMOTEIO; + return ret; } return ret; |