diff options
author | Peter Rosin | 2018-05-09 21:46:58 +0200 |
---|---|---|
committer | Wolfram Sang | 2018-05-24 22:13:04 +0200 |
commit | 6a0c0d0d009e6c09700cf92dec0860ade1f56f4c (patch) | |
tree | 8a34aa5324f6228a062b76c4a4f0c6fa2ae8e150 /drivers/i2c | |
parent | 7fb29b958dfff9c8eddfe4250aa0ed3614446c62 (diff) |
i2c: robotfuzz-osif: drop pointless test
In the for-loop test, ret will be either 0 or 1. So, the
comparison is pointless. Drop it, and drop the initializer
which is then also pointless.
Signed-off-by: Peter Rosin <peda@axentia.se>
Signed-off-by: Wolfram Sang <wsa@the-dreams.de>
Diffstat (limited to 'drivers/i2c')
-rw-r--r-- | drivers/i2c/busses/i2c-robotfuzz-osif.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/drivers/i2c/busses/i2c-robotfuzz-osif.c b/drivers/i2c/busses/i2c-robotfuzz-osif.c index 51d93b4b00f2..d848cf515234 100644 --- a/drivers/i2c/busses/i2c-robotfuzz-osif.c +++ b/drivers/i2c/busses/i2c-robotfuzz-osif.c @@ -62,10 +62,10 @@ static int osif_xfer(struct i2c_adapter *adapter, struct i2c_msg *msgs, { struct osif_priv *priv = adapter->algo_data; struct i2c_msg *pmsg; - int ret = 0; + int ret; int i; - for (i = 0; ret >= 0 && i < num; i++) { + for (i = 0; i < num; i++) { pmsg = &msgs[i]; if (pmsg->flags & I2C_M_RD) { |