* [PATCH -next] iio: isl29018: fix to return error or 0 in isl29018_write_raw()
@ 2012-11-08 9:05 Wei Yongjun
[not found] ` <CAPgLHd873xAvToL7reBbxmS-iEoJ9OqvjEoXf8RsG2esbTyo1A-JsoAwUIsXosN+BqQ9rBEUg@public.gmane.org>
0 siblings, 1 reply; 2+ messages in thread
From: Wei Yongjun @ 2012-11-08 9:05 UTC (permalink / raw)
To: jic23-KWPb1pKIrIJaa/9Udqfwiw,
gregkh-hQyY1W1yCW8ekmWlsbkhG0B+6BGkLq7r,
grant.likely-s3s/WqlpOiPyB63q8FvJNQ,
rob.herring-bsGFqQB8/DxBDgjK7y7TUQ
Cc: yongjun_wei-zrsr2BFq86L20UzCJQGyNP8+0UxHXcjY,
linux-iio-u79uwXL29TY76Z2rM5mHXA,
devel-gWbeCf7V1WCQmaza687I9mD2FQJk+8+b,
devicetree-discuss-uLR06cmDAlY/bJ5BZ2RsiQ
From: Wei Yongjun <yongjun_wei-zrsr2BFq86L20UzCJQGyNP8+0UxHXcjY@public.gmane.org>
We had assigned the return value to 'ret' but ignored it when
return from isl29018_write_raw(), it's better to return 'ret'
instead of 0.
dpatch engine is used to auto generate this patch.
(https://github.com/weiyj/dpatch)
Signed-off-by: Wei Yongjun <yongjun_wei-zrsr2BFq86L20UzCJQGyNP8+0UxHXcjY@public.gmane.org>
---
drivers/staging/iio/light/isl29018.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/staging/iio/light/isl29018.c b/drivers/staging/iio/light/isl29018.c
index 3b03f6f..1d5b294 100644
--- a/drivers/staging/iio/light/isl29018.c
+++ b/drivers/staging/iio/light/isl29018.c
@@ -356,7 +356,7 @@ static int isl29018_write_raw(struct iio_dev *indio_dev,
}
mutex_unlock(&chip->lock);
- return 0;
+ return ret;
}
static int isl29018_read_raw(struct iio_dev *indio_dev,
^ permalink raw reply related [flat|nested] 2+ messages in thread
* Re: [PATCH -next] iio: isl29018: fix to return error or 0 in isl29018_write_raw()
[not found] ` <CAPgLHd873xAvToL7reBbxmS-iEoJ9OqvjEoXf8RsG2esbTyo1A-JsoAwUIsXosN+BqQ9rBEUg@public.gmane.org>
@ 2012-11-17 10:20 ` Jonathan Cameron
0 siblings, 0 replies; 2+ messages in thread
From: Jonathan Cameron @ 2012-11-17 10:20 UTC (permalink / raw)
To: Wei Yongjun
Cc: jic23-KWPb1pKIrIJaa/9Udqfwiw,
gregkh-hQyY1W1yCW8ekmWlsbkhG0B+6BGkLq7r,
grant.likely-s3s/WqlpOiPyB63q8FvJNQ,
rob.herring-bsGFqQB8/DxBDgjK7y7TUQ,
yongjun_wei-zrsr2BFq86L20UzCJQGyNP8+0UxHXcjY,
linux-iio-u79uwXL29TY76Z2rM5mHXA,
devel-gWbeCf7V1WCQmaza687I9mD2FQJk+8+b,
devicetree-discuss-uLR06cmDAlY/bJ5BZ2RsiQ
On 11/08/2012 09:05 AM, Wei Yongjun wrote:
> From: Wei Yongjun <yongjun_wei-zrsr2BFq86L20UzCJQGyNP8+0UxHXcjY@public.gmane.org>
>
> We had assigned the return value to 'ret' but ignored it when
> return from isl29018_write_raw(), it's better to return 'ret'
> instead of 0.
>
> dpatch engine is used to auto generate this patch.
> (https://github.com/weiyj/dpatch)
>
Thanks - merged to togreg branch of
git://git.kernel.org/pub/scm/linux/kernel/git/jic23/iio.git
> Signed-off-by: Wei Yongjun <yongjun_wei-zrsr2BFq86L20UzCJQGyNP8+0UxHXcjY@public.gmane.org>
> ---
> drivers/staging/iio/light/isl29018.c | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/drivers/staging/iio/light/isl29018.c b/drivers/staging/iio/light/isl29018.c
> index 3b03f6f..1d5b294 100644
> --- a/drivers/staging/iio/light/isl29018.c
> +++ b/drivers/staging/iio/light/isl29018.c
> @@ -356,7 +356,7 @@ static int isl29018_write_raw(struct iio_dev *indio_dev,
> }
> mutex_unlock(&chip->lock);
>
> - return 0;
> + return ret;
> }
>
> static int isl29018_read_raw(struct iio_dev *indio_dev,
>
>
> --
> To unsubscribe from this list: send the line "unsubscribe linux-iio" in
> the body of a message to majordomo-u79uwXL29TY76Z2rM5mHXA@public.gmane.org
> More majordomo info at http://vger.kernel.org/majordomo-info.html
>
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2012-11-17 10:20 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2012-11-08 9:05 [PATCH -next] iio: isl29018: fix to return error or 0 in isl29018_write_raw() Wei Yongjun
[not found] ` <CAPgLHd873xAvToL7reBbxmS-iEoJ9OqvjEoXf8RsG2esbTyo1A-JsoAwUIsXosN+BqQ9rBEUg@public.gmane.org>
2012-11-17 10:20 ` Jonathan Cameron
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).