linux/drivers/iio
Geert Uytterhoeven f61dfff2f5 iio: pressure: zpa2326: Remove always-true check which confuses gcc
With gcc 4.1.2:

    drivers/iio/pressure/zpa2326.c: In function ‘zpa2326_wait_oneshot_completion’:
    drivers/iio/pressure/zpa2326.c:868: warning: ‘ret’ may be used uninitialized in this function

When testing for "timeout < 0", timeout is already guaranteed to be
strict negative, so the branch is always taken, and ret is thus always
initialized.  But (some version of) gcc is not smart enough to notice.

Remove the check to fix this.
As there is no other code in between assigning the error codes and
returning them, the error codes can be returned immediately, and the
intermediate variable can be dropped.
Drop the "else" to please checkpatch.

Fixes: e7215fe4d5 ("iio: pressure: zpa2326: report interrupted case as failure")
Signed-off-by: Geert Uytterhoeven <geert@linux-m68k.org>
Signed-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>
2017-09-25 21:39:00 +01:00
..
accel Second set of IIO new device support, features and cleanup for the 4.14 cycle. 2017-08-20 10:42:42 -07:00
adc First round of IIO fixes for the 4.14 cycle 2017-09-25 10:58:22 +02:00
amplifiers
buffer iio: buffer-dmaengine: Add missing header buffer_impl.h 2017-06-13 20:56:05 +01:00
chemical iio: chemical: ccs811: Add triggered buffer support 2017-08-18 08:08:02 +01:00
common First round of IIO fixes for the 4.14 cycle 2017-09-25 10:58:22 +02:00
counter iio: counter: Add support for STM32 LPTimer 2017-09-04 14:49:30 +01:00
dac iio: dac: stm32-dac-core: explicitly request exclusive reset control 2017-08-20 15:41:18 +01:00
dummy
frequency
gyro iio: gyro: st_gyro_spi: add OF capability to st_gyro_spi 2017-07-02 10:24:56 +01:00
health
humidity iio: humidity: hts221: move drdy enable logic in hts221_trig_set_state() 2017-07-25 20:03:04 +01:00
imu Merge 4.13-rc7 into staging-next 2017-08-28 15:26:48 +02:00
light Second set of IIO new device support, features and cleanup for the 4.14 cycle. 2017-08-20 10:42:42 -07:00
magnetometer First round of IIO fixes for the 4.14 cycle 2017-09-25 10:58:22 +02:00
multiplexer iio: multiplexer: new iio category and iio-mux driver 2017-06-03 19:29:26 +09:00
orientation iio: orientation: hid-sensor-rotation: Drop unnecessary static 2017-07-17 21:45:01 +01:00
potentiometer
potentiostat
pressure iio: pressure: zpa2326: Remove always-true check which confuses gcc 2017-09-25 21:39:00 +01:00
proximity iio: proximity: as3935: noise detection + threshold changes 2017-09-25 19:49:21 +01:00
temperature iio: temperature: tsys01: Add OF match table 2017-07-01 10:16:42 +01:00
trigger First round of IIO fixes for the 4.14 cycle 2017-09-25 10:58:22 +02:00
iio_core.h
iio_core_trigger.h
industrialio-buffer.c
industrialio-configfs.c
industrialio-core.c iio: core: Return error for failed read_reg 2017-09-24 16:58:32 +01:00
industrialio-event.c
industrialio-sw-device.c
industrialio-sw-trigger.c
industrialio-trigger.c iio: trigger: fix NULL pointer dereference in iio_trigger_write_current() 2017-05-21 12:36:59 +01:00
industrialio-triggered-event.c
inkern.c First round of IIO new device support, features and cleanups for the 4.14 cycle. 2017-07-27 21:29:49 -07:00
Kconfig iio: multiplexer: new iio category and iio-mux driver 2017-06-03 19:29:26 +09:00
Makefile iio: multiplexer: new iio category and iio-mux driver 2017-06-03 19:29:26 +09:00