Skip to content

Commit ab5625c

Browse files
groeckWolfram Sang
authored andcommitted
i2c: diolan-u2c: Fix master_xfer return code
The master_xfer function returns 0 on success. It should return the number of successful transactions. Signed-off-by: Guenter Roeck <[email protected]> Signed-off-by: Wolfram Sang <[email protected]>
1 parent 33ec5e8 commit ab5625c

File tree

1 file changed

+1
-0
lines changed

1 file changed

+1
-0
lines changed

drivers/i2c/busses/i2c-diolan-u2c.c

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -405,6 +405,7 @@ static int diolan_usb_xfer(struct i2c_adapter *adapter, struct i2c_msg *msgs,
405405
}
406406
}
407407
}
408+
ret = num;
408409
abort:
409410
sret = diolan_i2c_stop(dev);
410411
if (sret < 0 && ret >= 0)

0 commit comments

Comments
 (0)