Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > linux.kernel > #1546945 > unrolled thread
| Started by | Thomas Preisner <thomas.preisner+linux@fau.de> |
|---|---|
| First post | 2016-12-23 20:00 +0100 |
| Last post | 2016-12-30 19:40 +0100 |
| Articles | 2 — 2 participants |
Back to article view | Back to linux.kernel
[PATCH] drivers: staging: iio: cdc: fix return value Thomas Preisner <thomas.preisner+linux@fau.de> - 2016-12-23 20:00 +0100
Re: [PATCH] drivers: staging: iio: cdc: fix return value Jonathan Cameron <jic23@kernel.org> - 2016-12-30 19:40 +0100
| From | Thomas Preisner <thomas.preisner+linux@fau.de> |
|---|---|
| Date | 2016-12-23 20:00 +0100 |
| Subject | [PATCH] drivers: staging: iio: cdc: fix return value |
| Message-ID | <sRDep-2c3-3@gated-at.bofh.it> |
At the end of function ad7150_write_event_config(), "return 0" seems improper. It may be better to return the value of ret. Bugzilla: https://bugzilla.kernel.org/show_bug.cgi?id=188871 Reported-by: Pan Bian <bianpan2016@163.com> Signed-off-by: Thomas Preisner <thomas.preisner+linux@fau.de> Signed-off-by: Milan Stephan <milan.stephan+linux@fau.de> --- drivers/staging/iio/cdc/ad7150.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/staging/iio/cdc/ad7150.c b/drivers/staging/iio/cdc/ad7150.c index 6998c3d..04861eb 100644 --- a/drivers/staging/iio/cdc/ad7150.c +++ b/drivers/staging/iio/cdc/ad7150.c @@ -274,7 +274,7 @@ static int ad7150_write_event_config(struct iio_dev *indio_dev, error_ret: mutex_unlock(&chip->state_lock); - return 0; + return ret; } static int ad7150_read_event_value(struct iio_dev *indio_dev, -- 2.7.4
[toc] | [next] | [standalone]
| From | Jonathan Cameron <jic23@kernel.org> |
|---|---|
| Date | 2016-12-30 19:40 +0100 |
| Message-ID | <sUafU-7YX-49@gated-at.bofh.it> |
| In reply to | #1546945 |
On 23/12/16 18:51, Thomas Preisner wrote: > At the end of function ad7150_write_event_config(), "return 0" seems > improper. It may be better to return the value of ret. > > Bugzilla: https://bugzilla.kernel.org/show_bug.cgi?id=188871 > > Reported-by: Pan Bian <bianpan2016@163.com> > Signed-off-by: Thomas Preisner <thomas.preisner+linux@fau.de> > Signed-off-by: Milan Stephan <milan.stephan+linux@fau.de> I already see a patch for this from Pan. Jonathan > --- > drivers/staging/iio/cdc/ad7150.c | 2 +- > 1 file changed, 1 insertion(+), 1 deletion(-) > > diff --git a/drivers/staging/iio/cdc/ad7150.c b/drivers/staging/iio/cdc/ad7150.c > index 6998c3d..04861eb 100644 > --- a/drivers/staging/iio/cdc/ad7150.c > +++ b/drivers/staging/iio/cdc/ad7150.c > @@ -274,7 +274,7 @@ static int ad7150_write_event_config(struct iio_dev *indio_dev, > error_ret: > mutex_unlock(&chip->state_lock); > > - return 0; > + return ret; > } > > static int ad7150_read_event_value(struct iio_dev *indio_dev, >
[toc] | [prev] | [standalone]
Back to top | Article view | linux.kernel
csiph-web