projects
/
GitHub
/
moto-9609
/
android_kernel_motorola_exynos9610.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
dd77f42
)
i2c: imx: Use -ENXIO as error in the NACK case
author
Fabio Estevam
<fabio.estevam@freescale.com>
Thu, 22 Oct 2015 16:41:20 +0000
(14:41 -0200)
committer
Wolfram Sang
<wsa@the-dreams.de>
Fri, 23 Oct 2015 20:25:33 +0000
(22:25 +0200)
According to Documentation/i2c/fault-codes the response to a bus NACK
should be -ENXIO, so fix the error code.
Signed-off-by: Fabio Estevam <fabio.estevam@freescale.com>
Signed-off-by: Wolfram Sang <wsa@the-dreams.de>
drivers/i2c/busses/i2c-imx.c
patch
|
blob
|
blame
|
history
diff --git
a/drivers/i2c/busses/i2c-imx.c
b/drivers/i2c/busses/i2c-imx.c
index 8d46e74c720a77ed839d3450af2d962ac5209a35..1e4d99da41646d98a85340369828bb262c77075f 100644
(file)
--- a/
drivers/i2c/busses/i2c-imx.c
+++ b/
drivers/i2c/busses/i2c-imx.c
@@
-467,7
+467,7
@@
static int i2c_imx_acked(struct imx_i2c_struct *i2c_imx)
{
if (imx_i2c_read_reg(i2c_imx, IMX_I2C_I2SR) & I2SR_RXAK) {
dev_dbg(&i2c_imx->adapter.dev, "<%s> No ACK\n", __func__);
- return -EIO; /* No ACK */
+ return -E
NX
IO; /* No ACK */
}
dev_dbg(&i2c_imx->adapter.dev, "<%s> ACK received\n", __func__);