mediatek: correctly log i2c response
The read response is in the i2c_response variable. Also use %hhx format, because we're dealing with a single char. Signed-off-by: Sven Wegener <sven.wegener@stealer.net>
This commit is contained in:
parent
a188356484
commit
c4f9f9b44c
@ -74,14 +74,14 @@ static int ubnt_ledbar_apply_state(struct ubnt_ledbar *ledbar)
|
|||||||
|
|
||||||
i2c_response = ubnt_ledbar_perform_transaction(ledbar, setup_msg);
|
i2c_response = ubnt_ledbar_perform_transaction(ledbar, setup_msg);
|
||||||
if (i2c_response != UBNT_LEDBAR_TRANSACTION_SUCCESS) {
|
if (i2c_response != UBNT_LEDBAR_TRANSACTION_SUCCESS) {
|
||||||
dev_err(&ledbar->client->dev, "Error initializing LED transaction: %02x\n", ret);
|
dev_err(&ledbar->client->dev, "Error initializing LED transaction: %02hhx\n", i2c_response);
|
||||||
ret = -EINVAL;
|
ret = -EINVAL;
|
||||||
goto out_gpio;
|
goto out_gpio;
|
||||||
}
|
}
|
||||||
|
|
||||||
i2c_response = ubnt_ledbar_perform_transaction(ledbar, led_msg);
|
i2c_response = ubnt_ledbar_perform_transaction(ledbar, led_msg);
|
||||||
if (i2c_response != UBNT_LEDBAR_TRANSACTION_SUCCESS) {
|
if (i2c_response != UBNT_LEDBAR_TRANSACTION_SUCCESS) {
|
||||||
dev_err(&ledbar->client->dev, "Failed LED transaction: %02x\n", ret);
|
dev_err(&ledbar->client->dev, "Failed LED transaction: %02hhx\n", i2c_response);
|
||||||
ret = -EINVAL;
|
ret = -EINVAL;
|
||||||
goto out_gpio;
|
goto out_gpio;
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user