Commit f6beb67d authored by Jean Delvare's avatar Jean Delvare Committed by Jean Delvare

i2c-algo-bit: Be verbose on bus testing failure

If bus testing fails due to the bus being seen as busy, it might be
helpful for developers to know which line is unexpectedly low.
Signed-off-by: default avatarJean Delvare <jdelvare@suse.de>
Reviewed-by: default avatarAlex Deucher <alexdeucher@gmail.com>
parent 1bddab7f
...@@ -250,7 +250,9 @@ static int test_bus(struct i2c_adapter *i2c_adap) ...@@ -250,7 +250,9 @@ static int test_bus(struct i2c_adapter *i2c_adap)
sda = getsda(adap); sda = getsda(adap);
scl = (adap->getscl == NULL) ? 1 : getscl(adap); scl = (adap->getscl == NULL) ? 1 : getscl(adap);
if (!scl || !sda) { if (!scl || !sda) {
printk(KERN_WARNING "%s: bus seems to be busy\n", name); printk(KERN_WARNING
"%s: bus seems to be busy (scl=%d, sda=%d)\n",
name, scl, sda);
goto bailout; goto bailout;
} }
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment