mirror of
https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git
synced 2024-08-27 19:29:37 +00:00
staging:iio:light: Add some missing brackets to make sure code works as intended.
Note this is not a bug due to the fact the region cannot be reached without the sanity check passing. The autobuilder reported it as missaligned code which is kind of true as well. Signed-off-by: Jonathan Cameron <jic23@kernel.org> Cc: Roberta Dobrescu <roberta.dobrescu@gmail.com>
This commit is contained in:
parent
2fdaf3f4f8
commit
b91617ea62
1 changed files with 2 additions and 1 deletions
|
@ -369,12 +369,13 @@ static int isl29018_write_raw(struct iio_dev *indio_dev,
|
|||
}
|
||||
break;
|
||||
case IIO_CHAN_INFO_INT_TIME:
|
||||
if (chan->type == IIO_LIGHT)
|
||||
if (chan->type == IIO_LIGHT) {
|
||||
if (val != 0) {
|
||||
mutex_unlock(&chip->lock);
|
||||
return -EINVAL;
|
||||
}
|
||||
ret = isl29018_set_integration_time(chip, val2);
|
||||
}
|
||||
break;
|
||||
case IIO_CHAN_INFO_SCALE:
|
||||
if (chan->type == IIO_LIGHT)
|
||||
|
|
Loading…
Reference in a new issue