diff options
author | Sascha Hauer <s.hauer@pengutronix.de> | 2022-09-08 11:30:04 +0200 |
---|---|---|
committer | Sascha Hauer <s.hauer@pengutronix.de> | 2022-09-12 09:20:25 +0200 |
commit | 113fb8ea0af080c4e39af30b02a1c217a90e9608 (patch) | |
tree | 51e4909b187e5b3f34fcbe67df8ca6358bbafa75 /common/ratp | |
parent | 032362ebcc9ddbd5585de621165fe7988a8b30e1 (diff) | |
download | barebox-113fb8ea0af080c4e39af30b02a1c217a90e9608.tar.gz barebox-113fb8ea0af080c4e39af30b02a1c217a90e9608.tar.xz |
ratp: i2c: Do not return error
The RATP command implementations should only return an error on internal
failures. When an i2c command failed we should return 0 though to
actually send the error message. Without it the remote would just wait
for a response until it times out.
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
Link: https://lore.barebox.org/20220908093005.3035259-5-s.hauer@pengutronix.de
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
Diffstat (limited to 'common/ratp')
-rw-r--r-- | common/ratp/i2c.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/common/ratp/i2c.c b/common/ratp/i2c.c index c14bbbf9b9..404ddd2ece 100644 --- a/common/ratp/i2c.c +++ b/common/ratp/i2c.c @@ -162,7 +162,7 @@ out: *rsp = (struct ratp_bb *)i2c_read_rsp; *rsp_len = i2c_read_rsp_len; - return ret; + return 0; } BAREBOX_RATP_CMD_START(I2C_READ) @@ -271,7 +271,7 @@ out: *rsp = (struct ratp_bb *)i2c_write_rsp; *rsp_len = sizeof(*i2c_write_rsp); - return ret; + return 0; } BAREBOX_RATP_CMD_START(I2C_WRITE) |