]> git.ipfire.org Git - thirdparty/kernel/stable-queue.git/commitdiff
Fixes for 5.4
authorSasha Levin <sashal@kernel.org>
Thu, 9 Feb 2023 18:18:43 +0000 (13:18 -0500)
committerSasha Levin <sashal@kernel.org>
Thu, 9 Feb 2023 18:18:43 +0000 (13:18 -0500)
Signed-off-by: Sasha Levin <sashal@kernel.org>
queue-5.4/iio-adc-twl6030-enable-measurement-of-vac.patch [new file with mode: 0644]
queue-5.4/series

diff --git a/queue-5.4/iio-adc-twl6030-enable-measurement-of-vac.patch b/queue-5.4/iio-adc-twl6030-enable-measurement-of-vac.patch
new file mode 100644 (file)
index 0000000..c1e3944
--- /dev/null
@@ -0,0 +1,39 @@
+From 00b35eac5f060dfca3a1f87e3e0d58109cba0570 Mon Sep 17 00:00:00 2001
+From: Sasha Levin <sashal@kernel.org>
+Date: Sat, 17 Dec 2022 23:13:05 +0100
+Subject: iio:adc:twl6030: Enable measurement of VAC
+
+From: Andreas Kemnade <andreas@kemnade.info>
+
+[ Upstream commit bffb7d9d1a3dbd09e083b88aefd093b3b10abbfb ]
+
+VAC needs to be wired up to produce proper measurements,
+without this change only near zero values are reported.
+
+Reported-by: kernel test robot <lkp@intel.com>
+Reported-by: Julia Lawall <julia.lawall@lip6.fr>
+Fixes: 1696f36482e7 ("iio: twl6030-gpadc: TWL6030, TWL6032 GPADC driver")
+Signed-off-by: Andreas Kemnade <andreas@kemnade.info>
+Link: https://lore.kernel.org/r/20221217221305.671117-1-andreas@kemnade.info
+Signed-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>
+Signed-off-by: Sasha Levin <sashal@kernel.org>
+---
+ drivers/iio/adc/twl6030-gpadc.c | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/drivers/iio/adc/twl6030-gpadc.c b/drivers/iio/adc/twl6030-gpadc.c
+index 845e994e113ec..0a76081747580 100644
+--- a/drivers/iio/adc/twl6030-gpadc.c
++++ b/drivers/iio/adc/twl6030-gpadc.c
+@@ -952,7 +952,7 @@ static int twl6030_gpadc_probe(struct platform_device *pdev)
+       }
+       ret = twl_i2c_write_u8(TWL6030_MODULE_ID0,
+-                              VBAT_MEAS | BB_MEAS | BB_MEAS,
++                              VBAT_MEAS | BB_MEAS | VAC_MEAS,
+                               TWL6030_MISC1);
+       if (ret < 0) {
+               dev_err(dev, "failed to wire up inputs\n");
+-- 
+2.39.0
+
index 7b55fe48ac07aacf448219b5462a8afbf61466e1..92348aeb55b0f7c8490537056ed9331e15a120c1 100644 (file)
@@ -56,3 +56,4 @@ powerpc-imc-pmu-revert-nest_init_lock-to-being-a-mutex.patch
 fbdev-smscufx-fix-error-handling-code-in-ufx_usb_probe.patch
 f2fs-fix-to-do-sanity-check-on-i_extra_isize-in-is_alive.patch
 wifi-brcmfmac-check-the-count-value-of-channel-spec-to-prevent-out-of-bounds-reads.patch
+iio-adc-twl6030-enable-measurement-of-vac.patch