On 28/04/15 18:09, Roberta Dobrescu wrote: > This patch fixes the following warning: > > drivers/staging/iio/light/isl29018.c:386 isl29018_write_raw() warn: > inconsistent returns 'mutex:&chip->lock'. > Locked on: line 374 > Unlocked on: line 386 > > Signed-off-by: Roberta Dobrescu <roberta.dobrescu@xxxxxxxxx> > Reported-by: Dan Carpenter <dan.carpenter@xxxxxxxxxx> I applied this as a fixup rather than a separate patch. Anyhow, new testing and togreg branches should have this fixed. > --- > drivers/staging/iio/light/isl29018.c | 4 +++- > 1 file changed, 3 insertions(+), 1 deletion(-) > > diff --git a/drivers/staging/iio/light/isl29018.c b/drivers/staging/iio/light/isl29018.c > index 435d417..08ca9a4 100644 > --- a/drivers/staging/iio/light/isl29018.c > +++ b/drivers/staging/iio/light/isl29018.c > @@ -370,8 +370,10 @@ static int isl29018_write_raw(struct iio_dev *indio_dev, > break; > case IIO_CHAN_INFO_INT_TIME: > if (chan->type == IIO_LIGHT) > - if (val != 0) > + if (val != 0) { > + mutex_unlock(&chip->lock); > return -EINVAL; > + } > ret = isl29018_set_integration_time(chip, val2); > break; > case IIO_CHAN_INFO_SCALE: > -- To unsubscribe from this list: send the line "unsubscribe linux-iio" in the body of a message to majordomo@xxxxxxxxxxxxxxx More majordomo info at http://vger.kernel.org/majordomo-info.html