summaryrefslogtreecommitdiff
path: root/drivers/staging
diff options
context:
space:
mode:
authorGreg Kroah-Hartman <gregkh@linuxfoundation.org>2019-04-02 08:45:15 +0200
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>2019-04-02 08:45:15 +0200
commit360b921bdfbaf8d1c6483d77c5b7d1491be44a6d (patch)
tree76927f7b1bee79c3e3ecf970ebdce9756879e004 /drivers/staging
parent79a3aaa7b82e3106be97842dedfd8429248896e6 (diff)
parent7f75591fc5a123929a29636834d1bcb8b5c9fee3 (diff)
Merge tag 'iio-fixes-for-5.1a' of git://git.kernel.org/pub/scm/linux/kernel/git/jic23/iio into staging-linus
Jonathan writes: First set of IIO fixes for the 5.1 cycle. Mostly the usual mix, but the bme680 SPI fix is much larger than I would normally like. It never worked, but conversely we have code there that would make people expect it to do so. Chances of side effects are very low. * core - Fix an uninitialised bitaks that could potentially result in random channels being enabled on startup. * ad7192 - Fix a wrong channel address for ad7193. * ade7854 - Fix a typo that results in returning peak voltage instead of peak current. * at91 - Fix a potential hang due to a race on interrupt setting. * bmg160 - Fix scale factor of temperature * bme680 - Fix scale factor of temperature - Fix SPI read interface. This is a bit of a large patch as it seems that it never worked. It's major for this driver but is unlikely to have any negative side effects. * kxcjk1013 - restore sensor range setting after resume. * mcp4725 - make sure to store powerdown bits when storing to the eeprom. * mpu3050 - Mask the chip ID correctly as we have chips that set the bother bits of this register. * sgp30 - Fix a missing Kconfig block that means the driver doesn't actually ever get built. * tag 'iio-fixes-for-5.1a' of git://git.kernel.org/pub/scm/linux/kernel/git/jic23/iio: iio: core: fix a possible circular locking dependency iio: ad_sigma_delta: select channel when reading register iio: pms7003: select IIO_TRIGGERED_BUFFER iio: cros_ec: Fix the maths for gyro scale calculation iio: adc: xilinx: prevent touching unclocked h/w on remove iio: adc: xilinx: fix potential use-after-free on probe iio: adc: xilinx: fix potential use-after-free on remove iio: dac: mcp4725: add missing powerdown bits in store eeprom io: accel: kxcjk1013: restore the range after resume. iio:chemical:bme680: Fix SPI read interface iio:chemical:bme680: Fix, report temperature in millidegrees iio: chemical: fix missing Kconfig block for sgp30 iio: adc: at91: disable adc channel interrupt in timeout case iio: gyro: mpu3050: fix chip ID reading iio: Fix scan mask selection staging: iio: ad7192: Fix ad7193 channel address iio/gyro/bmg160: Use millidegrees for temperature scale Staging: iio: meter: fixed typo
Diffstat (limited to 'drivers/staging')
-rw-r--r--drivers/staging/iio/adc/ad7192.c8
-rw-r--r--drivers/staging/iio/meter/ade7854.c2
2 files changed, 5 insertions, 5 deletions
diff --git a/drivers/staging/iio/adc/ad7192.c b/drivers/staging/iio/adc/ad7192.c
index acdbc07fd259..2fc8bc22b57b 100644
--- a/drivers/staging/iio/adc/ad7192.c
+++ b/drivers/staging/iio/adc/ad7192.c
@@ -109,10 +109,10 @@
#define AD7192_CH_AIN3 BIT(6) /* AIN3 - AINCOM */
#define AD7192_CH_AIN4 BIT(7) /* AIN4 - AINCOM */
-#define AD7193_CH_AIN1P_AIN2M 0x000 /* AIN1(+) - AIN2(-) */
-#define AD7193_CH_AIN3P_AIN4M 0x001 /* AIN3(+) - AIN4(-) */
-#define AD7193_CH_AIN5P_AIN6M 0x002 /* AIN5(+) - AIN6(-) */
-#define AD7193_CH_AIN7P_AIN8M 0x004 /* AIN7(+) - AIN8(-) */
+#define AD7193_CH_AIN1P_AIN2M 0x001 /* AIN1(+) - AIN2(-) */
+#define AD7193_CH_AIN3P_AIN4M 0x002 /* AIN3(+) - AIN4(-) */
+#define AD7193_CH_AIN5P_AIN6M 0x004 /* AIN5(+) - AIN6(-) */
+#define AD7193_CH_AIN7P_AIN8M 0x008 /* AIN7(+) - AIN8(-) */
#define AD7193_CH_TEMP 0x100 /* Temp senseor */
#define AD7193_CH_AIN2P_AIN2M 0x200 /* AIN2(+) - AIN2(-) */
#define AD7193_CH_AIN1 0x401 /* AIN1 - AINCOM */
diff --git a/drivers/staging/iio/meter/ade7854.c b/drivers/staging/iio/meter/ade7854.c
index 029c3bf42d4d..07774c000c5a 100644
--- a/drivers/staging/iio/meter/ade7854.c
+++ b/drivers/staging/iio/meter/ade7854.c
@@ -269,7 +269,7 @@ static IIO_DEV_ATTR_VPEAK(0644,
static IIO_DEV_ATTR_IPEAK(0644,
ade7854_read_32bit,
ade7854_write_32bit,
- ADE7854_VPEAK);
+ ADE7854_IPEAK);
static IIO_DEV_ATTR_APHCAL(0644,
ade7854_read_16bit,
ade7854_write_16bit,