linux/drivers/iio
Fabrice Gasnier 06e3fe8998 iio: trigger: stm32-timer: fix get/set down count direction
Fixes: 4adec7da05 ("iio: stm32 trigger: Add quadrature encoder device")

This fixes two issues:
- stm32_set_count_direction: to set down direction
- stm32_get_count_direction: to get down direction

IIO core provides/expects value to be an index of iio_enum items array.
This needs to be turned by these routines into TIM_CR1_DIR (e.g. BIT(4))
value.
Also, report error when attempting to write direction, when in encoder
mode: in this case, direction is read only (given by encoder inputs).

Signed-off-by: Fabrice Gasnier <fabrice.gasnier@st.com>
Acked-by: Benjamin Gaignard <benjamin.gaignard@linaro.org>
Signed-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>
2017-07-30 14:46:02 +01:00
..
accel First set of IIO fixes for the 4.13 cycle. 2017-07-23 20:54:31 -07:00
adc First set of IIO fixes for the 4.13 cycle. 2017-07-23 20:54:31 -07:00
amplifiers
buffer iio: buffer-dmaengine: Add missing header buffer_impl.h 2017-06-13 20:56:05 +01:00
chemical drivers: iio: chemical: replace comma with a semicolon 2017-03-30 19:13:23 +01:00
common First set of IIO fixes for the 4.13 cycle. 2017-07-23 20:54:31 -07:00
counter iio: pc104: Mask PC/104 drivers via the PC104 Kconfig option 2017-03-15 21:59:08 +00:00
dac First set of new device support, features and cleanups for IIO in the 4.13 cycle 2017-05-29 15:53:42 +02:00
dummy iio:dummy: Stop enabling timestamp by default. 2017-01-10 19:54:55 +00:00
frequency iio: frequency: ad9523: use unsigned int rather then bare unsigned 2016-04-17 10:31:03 +01:00
gyro Fourth set of IIO new device support, features and cleanups for the 4.12 cycle 2017-04-18 17:13:31 +02:00
health First set of IIO new device support, features and cleanup for the 4.12 cycle. 2017-03-06 13:17:21 +01:00
humidity iio: humidity: hts221: add power management support 2017-05-14 16:52:33 +01:00
imu Second set of IIO new device support, features and cleanups for the 4.13 cycle. 2017-06-26 07:09:23 +02:00
light First set of IIO fixes for the 4.13 cycle. 2017-07-23 20:54:31 -07:00
magnetometer iio: magnetometer: st_magn_spi: fix spi_device_id table 2017-06-11 15:07:40 +01:00
multiplexer iio: multiplexer: new iio category and iio-mux driver 2017-06-03 19:29:26 +09:00
orientation iio: hid-sensor-rotation: Add "scale" and "offset" properties parse support 2017-05-07 12:22:36 +01:00
potentiometer iio: max5481: Add support for Maxim digital potentiometers 2017-01-28 12:13:31 +00:00
potentiostat iio: lmp91000: Set parent device 2017-02-19 12:01:52 +00:00
pressure iio: bmp280: properly initialize device for humidity reading 2017-07-30 14:41:12 +01:00
proximity Second set of IIO new device support, features and cleanups for the 4.13 cycle. 2017-06-26 07:09:23 +02:00
temperature iio: temperature: maxim_thermocouple: add MAX31856 part 2017-05-07 12:36:41 +01:00
trigger iio: trigger: stm32-timer: fix get/set down count direction 2017-07-30 14:46:02 +01:00
iio_core.h iio:core: timestamping clock selection support 2016-06-30 19:41:38 +01:00
iio_core_trigger.h
industrialio-buffer.c sched/headers: Prepare to move signal wakeup & sigpending methods from <linux/sched.h> into <linux/sched/signal.h> 2017-03-02 08:42:32 +01:00
industrialio-configfs.c
industrialio-core.c iio: add hardware triggered operating mode 2017-06-11 15:58:41 +01:00
industrialio-event.c iio: iio_push_event(): Don't crash if the event interface is not registered 2016-09-10 16:40:44 +01:00
industrialio-sw-device.c iio: Add support for creating IIO devices via configfs 2016-05-04 11:43:54 +01:00
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 Char/Misc patches for 4.13-rc1 2017-07-03 20:55:59 -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