diff options
author | Peter Rosin <peda@axentia.se> | 2018-05-09 22:47:48 +0300 |
---|---|---|
committer | Wolfram Sang <wsa@the-dreams.de> | 2018-05-15 10:31:26 +0300 |
commit | 35cd67a0caf767aba472452865dcb4471fcce2b1 (patch) | |
tree | 03bdc74b9fe126ac677343e37c6314c1f5f9a3da /drivers/i2c/busses/i2c-viperboard.c | |
parent | 12d9bbc5a7f347eaa65ff2a9d34995cadc05eb1b (diff) | |
download | linux-35cd67a0caf767aba472452865dcb4471fcce2b1.tar.xz |
i2c: viperboard: return message count on master_xfer success
Returning zero is wrong in this case.
Signed-off-by: Peter Rosin <peda@axentia.se>
Signed-off-by: Wolfram Sang <wsa@the-dreams.de>
Fixes: 174a13aa8669 ("i2c: Add viperboard i2c master driver")
Diffstat (limited to 'drivers/i2c/busses/i2c-viperboard.c')
-rw-r--r-- | drivers/i2c/busses/i2c-viperboard.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/i2c/busses/i2c-viperboard.c b/drivers/i2c/busses/i2c-viperboard.c index e4be86b3de9a..7235c7302bb7 100644 --- a/drivers/i2c/busses/i2c-viperboard.c +++ b/drivers/i2c/busses/i2c-viperboard.c @@ -337,7 +337,7 @@ static int vprbrd_i2c_xfer(struct i2c_adapter *i2c, struct i2c_msg *msgs, } mutex_unlock(&vb->lock); } - return 0; + return num; error: mutex_unlock(&vb->lock); return error; |