* [PATCH] i2c: mv64xxx: Fix transfer error code
@ 2013-06-19 21:53 Guenter Roeck
[not found] ` <1371678832-26889-1-git-send-email-linux-0h96xk9xTtrk1uMJSBkQmQ@public.gmane.org>
0 siblings, 1 reply; 5+ messages in thread
From: Guenter Roeck @ 2013-06-19 21:53 UTC (permalink / raw)
To: linux-i2c-u79uwXL29TY76Z2rM5mHXA; +Cc: Wolfram Sang, Guenter Roeck
The driver returns -ENODEV as error code if it did not get an ACK
from the device. Per Documentation/i2c/fault-codes, it should
return -ENXIO.
Signed-off-by: Guenter Roeck <linux-0h96xk9xTtrk1uMJSBkQmQ@public.gmane.org>
---
drivers/i2c/busses/i2c-mv64xxx.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/i2c/busses/i2c-mv64xxx.c b/drivers/i2c/busses/i2c-mv64xxx.c
index 1a3abd6..6972032 100644
--- a/drivers/i2c/busses/i2c-mv64xxx.c
+++ b/drivers/i2c/busses/i2c-mv64xxx.c
@@ -227,7 +227,7 @@ mv64xxx_i2c_fsm(struct mv64xxx_i2c_data *drv_data, u32 status)
/* Doesn't seem to be a device at other end */
drv_data->action = MV64XXX_I2C_ACTION_SEND_STOP;
drv_data->state = MV64XXX_I2C_STATE_IDLE;
- drv_data->rc = -ENODEV;
+ drv_data->rc = -ENXIO;
break;
default:
--
1.7.9.7
^ permalink raw reply related [flat|nested] 5+ messages in thread[parent not found: <1371678832-26889-1-git-send-email-linux-0h96xk9xTtrk1uMJSBkQmQ@public.gmane.org>]
* Re: [PATCH] i2c: mv64xxx: Fix transfer error code [not found] ` <1371678832-26889-1-git-send-email-linux-0h96xk9xTtrk1uMJSBkQmQ@public.gmane.org> @ 2013-06-20 19:23 ` Wolfram Sang 2013-06-20 21:12 ` Guenter Roeck 2013-06-21 0:16 ` Guenter Roeck 0 siblings, 2 replies; 5+ messages in thread From: Wolfram Sang @ 2013-06-20 19:23 UTC (permalink / raw) To: Guenter Roeck; +Cc: linux-i2c-u79uwXL29TY76Z2rM5mHXA [-- Attachment #1: Type: text/plain, Size: 1047 bytes --] On Wed, Jun 19, 2013 at 02:53:52PM -0700, Guenter Roeck wrote: > The driver returns -ENODEV as error code if it did not get an ACK > from the device. Per Documentation/i2c/fault-codes, it should > return -ENXIO. > > Signed-off-by: Guenter Roeck <linux-0h96xk9xTtrk1uMJSBkQmQ@public.gmane.org> Thanks, have you checked the other error codes as well while you were there? > --- > drivers/i2c/busses/i2c-mv64xxx.c | 2 +- > 1 file changed, 1 insertion(+), 1 deletion(-) > > diff --git a/drivers/i2c/busses/i2c-mv64xxx.c b/drivers/i2c/busses/i2c-mv64xxx.c > index 1a3abd6..6972032 100644 > --- a/drivers/i2c/busses/i2c-mv64xxx.c > +++ b/drivers/i2c/busses/i2c-mv64xxx.c > @@ -227,7 +227,7 @@ mv64xxx_i2c_fsm(struct mv64xxx_i2c_data *drv_data, u32 status) > /* Doesn't seem to be a device at other end */ > drv_data->action = MV64XXX_I2C_ACTION_SEND_STOP; > drv_data->state = MV64XXX_I2C_STATE_IDLE; > - drv_data->rc = -ENODEV; > + drv_data->rc = -ENXIO; > break; > > default: > -- > 1.7.9.7 > [-- Attachment #2: Digital signature --] [-- Type: application/pgp-signature, Size: 836 bytes --] ^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: [PATCH] i2c: mv64xxx: Fix transfer error code 2013-06-20 19:23 ` Wolfram Sang @ 2013-06-20 21:12 ` Guenter Roeck 2013-06-21 0:16 ` Guenter Roeck 1 sibling, 0 replies; 5+ messages in thread From: Guenter Roeck @ 2013-06-20 21:12 UTC (permalink / raw) To: Wolfram Sang; +Cc: linux-i2c-u79uwXL29TY76Z2rM5mHXA On Thu, Jun 20, 2013 at 09:23:37PM +0200, Wolfram Sang wrote: > On Wed, Jun 19, 2013 at 02:53:52PM -0700, Guenter Roeck wrote: > > The driver returns -ENODEV as error code if it did not get an ACK > > from the device. Per Documentation/i2c/fault-codes, it should > > return -ENXIO. > > > > Signed-off-by: Guenter Roeck <linux-0h96xk9xTtrk1uMJSBkQmQ@public.gmane.org> > > Thanks, have you checked the other error codes as well while you were > there? > No; this is one that was discovered while testing a driver connected to the controller. I'll check the others and let you know if I find any other problems. Thanks, Guenter > > --- > > drivers/i2c/busses/i2c-mv64xxx.c | 2 +- > > 1 file changed, 1 insertion(+), 1 deletion(-) > > > > diff --git a/drivers/i2c/busses/i2c-mv64xxx.c b/drivers/i2c/busses/i2c-mv64xxx.c > > index 1a3abd6..6972032 100644 > > --- a/drivers/i2c/busses/i2c-mv64xxx.c > > +++ b/drivers/i2c/busses/i2c-mv64xxx.c > > @@ -227,7 +227,7 @@ mv64xxx_i2c_fsm(struct mv64xxx_i2c_data *drv_data, u32 status) > > /* Doesn't seem to be a device at other end */ > > drv_data->action = MV64XXX_I2C_ACTION_SEND_STOP; > > drv_data->state = MV64XXX_I2C_STATE_IDLE; > > - drv_data->rc = -ENODEV; > > + drv_data->rc = -ENXIO; > > break; > > > > default: > > -- > > 1.7.9.7 > > ^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: [PATCH] i2c: mv64xxx: Fix transfer error code 2013-06-20 19:23 ` Wolfram Sang 2013-06-20 21:12 ` Guenter Roeck @ 2013-06-21 0:16 ` Guenter Roeck [not found] ` <20130621001627.GA25889-0h96xk9xTtrk1uMJSBkQmQ@public.gmane.org> 1 sibling, 1 reply; 5+ messages in thread From: Guenter Roeck @ 2013-06-21 0:16 UTC (permalink / raw) To: Wolfram Sang; +Cc: linux-i2c-u79uwXL29TY76Z2rM5mHXA On Thu, Jun 20, 2013 at 09:23:37PM +0200, Wolfram Sang wrote: > On Wed, Jun 19, 2013 at 02:53:52PM -0700, Guenter Roeck wrote: > > The driver returns -ENODEV as error code if it did not get an ACK > > from the device. Per Documentation/i2c/fault-codes, it should > > return -ENXIO. > > > > Signed-off-by: Guenter Roeck <linux-0h96xk9xTtrk1uMJSBkQmQ@public.gmane.org> > > Thanks, have you checked the other error codes as well while you were > there? > Other error codes are ok as far as I can see. Guenter > > --- > > drivers/i2c/busses/i2c-mv64xxx.c | 2 +- > > 1 file changed, 1 insertion(+), 1 deletion(-) > > > > diff --git a/drivers/i2c/busses/i2c-mv64xxx.c b/drivers/i2c/busses/i2c-mv64xxx.c > > index 1a3abd6..6972032 100644 > > --- a/drivers/i2c/busses/i2c-mv64xxx.c > > +++ b/drivers/i2c/busses/i2c-mv64xxx.c > > @@ -227,7 +227,7 @@ mv64xxx_i2c_fsm(struct mv64xxx_i2c_data *drv_data, u32 status) > > /* Doesn't seem to be a device at other end */ > > drv_data->action = MV64XXX_I2C_ACTION_SEND_STOP; > > drv_data->state = MV64XXX_I2C_STATE_IDLE; > > - drv_data->rc = -ENODEV; > > + drv_data->rc = -ENXIO; > > break; > > > > default: > > -- > > 1.7.9.7 > > ^ permalink raw reply [flat|nested] 5+ messages in thread
[parent not found: <20130621001627.GA25889-0h96xk9xTtrk1uMJSBkQmQ@public.gmane.org>]
* Re: [PATCH] i2c: mv64xxx: Fix transfer error code [not found] ` <20130621001627.GA25889-0h96xk9xTtrk1uMJSBkQmQ@public.gmane.org> @ 2013-06-25 16:42 ` Wolfram Sang 0 siblings, 0 replies; 5+ messages in thread From: Wolfram Sang @ 2013-06-25 16:42 UTC (permalink / raw) To: Guenter Roeck; +Cc: linux-i2c-u79uwXL29TY76Z2rM5mHXA [-- Attachment #1: Type: text/plain, Size: 653 bytes --] On Thu, Jun 20, 2013 at 05:16:27PM -0700, Guenter Roeck wrote: > On Thu, Jun 20, 2013 at 09:23:37PM +0200, Wolfram Sang wrote: > > On Wed, Jun 19, 2013 at 02:53:52PM -0700, Guenter Roeck wrote: > > > The driver returns -ENODEV as error code if it did not get an ACK > > > from the device. Per Documentation/i2c/fault-codes, it should > > > return -ENXIO. > > > > > > Signed-off-by: Guenter Roeck <linux-0h96xk9xTtrk1uMJSBkQmQ@public.gmane.org> > > > > Thanks, have you checked the other error codes as well while you were > > there? > > > Other error codes are ok as far as I can see. Applied to for-next, thanks for double checking! [-- Attachment #2: Digital signature --] [-- Type: application/pgp-signature, Size: 836 bytes --] ^ permalink raw reply [flat|nested] 5+ messages in thread
end of thread, other threads:[~2013-06-25 16:42 UTC | newest]
Thread overview: 5+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2013-06-19 21:53 [PATCH] i2c: mv64xxx: Fix transfer error code Guenter Roeck
[not found] ` <1371678832-26889-1-git-send-email-linux-0h96xk9xTtrk1uMJSBkQmQ@public.gmane.org>
2013-06-20 19:23 ` Wolfram Sang
2013-06-20 21:12 ` Guenter Roeck
2013-06-21 0:16 ` Guenter Roeck
[not found] ` <20130621001627.GA25889-0h96xk9xTtrk1uMJSBkQmQ@public.gmane.org>
2013-06-25 16:42 ` Wolfram Sang
This is a public inbox, see mirroring instructions for how to clone and mirror all data and code used for this inbox; as well as URLs for NNTP newsgroup(s).