summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMatti Vaittinen <mazziesaccount@gmail.com>2026-08-10 10:49:56 +0300
committerJonathan Cameron <jonathan.cameron@oss.qualcomm.com>2026-08-28 23:35:04 +0100
commite6b60f957fa3c23f6f8b3561ba494271d69543c0 (patch)
tree32601ea9bdfea35b4e464e6cb0f68aca54120408
parent05405a0b037e624dbb112d178910eed3e265da41 (diff)
downloadlinux-next-e6b60f957fa3c23f6f8b3561ba494271d69543c0.tar.gz
linux-next-e6b60f957fa3c23f6f8b3561ba494271d69543c0.zip
iio: adc: rohm-bd79124: Fix rising alarm
The rising alarm is using the cached falling alarm value causing wrong value to be used. Fix this by using the correct cached value for rising alarm. Fixes: 3f57a3b9ab74 ("iio: adc: Support ROHM BD79124 ADC") Signed-off-by: Matti Vaittinen <mazziesaccount@gmail.com> Cc: <Stable@vger.kernel.org> Signed-off-by: Jonathan Cameron <jonathan.cameron@oss.qualcomm.com>
-rw-r--r--drivers/iio/adc/rohm-bd79124.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/iio/adc/rohm-bd79124.c b/drivers/iio/adc/rohm-bd79124.c
index ed5427288961..eab5286763a7 100644
--- a/drivers/iio/adc/rohm-bd79124.c
+++ b/drivers/iio/adc/rohm-bd79124.c
@@ -524,7 +524,7 @@ static int bd79124_enable_event(struct bd79124_data *data,
return ret;
if (dir == IIO_EV_DIR_RISING) {
- limit = &data->alarm_f_limit[channel];
+ limit = &data->alarm_r_limit[channel];
reg = BD79124_GET_HIGH_LIMIT_REG(channel);
} else {
limit = &data->alarm_f_limit[channel];