android_kernel_xiaomi_sm7250/drivers/iio
Colin Ian King 2870da9189 iio: adc: Fix incorrect exit of for-loop
commit 5afc1540f13804a31bb704b763308e17688369c5 upstream.

Currently the for-loop that scans for the optimial adc_period iterates
through all the possible adc_period levels because the exit logic in
the loop is inverted. I believe the comparison should be swapped and
the continue replaced with a break to exit the loop at the correct
point.

Addresses-Coverity: ("Continue has no effect")
Fixes: e08e19c331 ("iio:adc: add iio driver for Palmas (twl6035/7) gpadc")
Signed-off-by: Colin Ian King <colin.king@canonical.com>
Link: https://lore.kernel.org/r/20210730071651.17394-1-colin.king@canonical.com
Cc: <stable@vger.kernel.org>
Signed-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2021-08-26 08:36:35 -04:00
..
accel iio: accel: bma180: Fix BMA25x bandwidth register values 2021-07-28 11:13:51 +02:00
adc iio: adc: Fix incorrect exit of for-loop 2021-08-26 08:36:35 -04:00
afe
amplifiers
buffer
chemical
common
counter
dac iio: dac: ds4422/ds4424 drop of_node check 2021-07-31 08:22:37 +02:00
dummy
frequency
gyro iio: gyro: bmg160: Fix buffer alignment in iio_push_to_buffers_with_timestamp() 2021-07-20 16:15:54 +02:00
health
humidity iio: humidity: hdc100x: Add margin to the conversion time 2021-08-26 08:36:35 -04:00
imu iio: adis_buffer: do not return ints in irq handlers 2021-07-20 16:15:53 +02:00
light iio: light: tcs3472: Fix buffer alignment in iio_push_to_buffers_with_timestamp() 2021-07-20 16:15:54 +02:00
magnetometer iio:magnetometer:mag3110: Fix alignment and data leak issues. 2021-01-09 13:43:48 +01:00
multiplexer
orientation
potentiometer
potentiostat iio: potentiostat: lmp91000: Fix alignment of buffer in iio_push_to_buffers_with_timestamp() 2021-07-20 16:15:54 +02:00
pressure iio:pressure:mpl3115: Force alignment of buffer 2020-12-30 11:26:16 +01:00
proximity iio: prox: isl29501: Fix buffer alignment in iio_push_to_buffers_with_timestamp() 2021-07-20 16:15:56 +02:00
resolver
temperature iio: hid-sensor-temperature: Fix issues of timestamp channel 2021-03-24 11:07:36 +01:00
trigger
iio_core_trigger.h
iio_core.h
industrialio-buffer.c iio: buffer: Fix demux update 2020-12-30 11:26:15 +01:00
industrialio-configfs.c
industrialio-core.c
industrialio-event.c
industrialio-sw-device.c
industrialio-sw-trigger.c
industrialio-trigger.c
industrialio-triggered-event.c
inkern.c
Kconfig
Makefile