Skip to content

Commit 2b4ec22

Browse files
committed
Merge branch 'fixes-togreg' into togreg
2 parents 2fa03b9 + 1e96e93 commit 2b4ec22

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

drivers/iio/frequency/ad9523.c

+1-1
Original file line numberDiff line numberDiff line change
@@ -522,7 +522,7 @@ static ssize_t ad9523_store(struct device *dev,
522522
return ret;
523523

524524
if (!state)
525-
return 0;
525+
return len;
526526

527527
mutex_lock(&st->lock);
528528
switch ((u32)this_attr->address) {

drivers/iio/light/si1133.c

+1-1
Original file line numberDiff line numberDiff line change
@@ -838,7 +838,7 @@ static int si1133_write_raw(struct iio_dev *iio_dev,
838838
switch (chan->type) {
839839
case IIO_INTENSITY:
840840
case IIO_UVINDEX:
841-
if (val != 0 || val != 1)
841+
if (val != 0 && val != 1)
842842
return -EINVAL;
843843

844844
return si1133_update_adcsens(data,

0 commit comments

Comments
 (0)