linux-brain/drivers/staging/iio
Lucas Stankus 657f6a33f8 staging: iio: cdc: ad7746: avoid overwrite of num_channels
commit 04f5b9f539ce314f758d919a14dc7a669f3b7838 upstream.

AD7745 devices don't have the CIN2 pins and therefore can't handle related
channels. Forcing the number of AD7746 channels may lead to enabling more
channels than what the hardware actually supports.
Avoid num_channels being overwritten after first assignment.

Signed-off-by: Lucas Stankus <lucas.p.stankus@gmail.com>
Fixes: 83e416f458 ("staging: iio: adc: Replace, rewrite ad7745 from scratch.")
Signed-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>
Cc: <Stable@vger.kernel.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2021-06-03 08:59:04 +02:00
..
Documentation staging: iio: ad5933: add ABI documentation 2019-04-04 20:20:13 +01:00
accel staging: iio: accel: adis16240: Improve readability on write_raw function 2019-08-18 20:12:52 +01:00
adc staging: iio: adc: ad7192: Add low_pass_3db_filter_frequency 2019-08-18 19:33:51 +01:00
addac Second set of IIO device support, features, cleanups and minor fixes for 5.3. 2019-07-01 10:58:13 +02:00
cdc staging: iio: cdc: ad7746: avoid overwrite of num_channels 2021-06-03 08:59:04 +02:00
frequency staging: iio: ad9834: add a check for devm_clk_get 2019-12-31 16:44:11 +01:00
impedance-analyzer First set of new device support, features and fixes for IIO in the 5.2 cycle 2019-04-04 22:25:29 +02:00
meter Merge 5.1-rc6 into staging-next 2019-04-21 23:18:44 +02:00
resolver staging: iio: ad2s1210: Fix SPI reading 2020-05-27 17:46:45 +02:00
Kconfig staging: add missing SPDX lines to Kconfig files 2019-04-03 11:10:15 +02:00
Makefile staging: iio: Drop ADIS16060 driver from staging 2018-06-10 11:52:31 +01:00
TODO staging: iio: Augment TODO file with GPIO work item 2018-04-23 14:36:10 +02:00