summaryrefslogtreecommitdiff
path: root/drivers/iio/light
diff options
context:
space:
mode:
authorSubhajit Ghosh <subhajit.ghosh@vixtechnology.com>2022-11-10 13:12:41 +0300
committerJonathan Cameron <Jonathan.Cameron@huawei.com>2022-11-23 22:58:45 +0300
commit5ae34494cf37ae6383f4bd674f343ef20833024d (patch)
treedd04d2ada32792be414064cc0f78b9cecc5701cc /drivers/iio/light
parent7b4452381a966de33707718aa8d79672cc8caa2f (diff)
downloadlinux-5ae34494cf37ae6383f4bd674f343ef20833024d.tar.xz
iio: light: apds9960: Fix iio_event_spec structures
There is only one interrupt enable option for both ALS low and high thresholds, and one for both Proximity low and high thresholds. Signed-off-by: Subhajit Ghosh <subhajit.ghosh@vixtechnology.com> Reviewed-by: Matt Ranostay <matt.ranostay@konsulko.com> Link: https://lore.kernel.org/r/20221110101241.10576-1-subhajit.ghosh@vixtechnology.com Signed-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>
Diffstat (limited to 'drivers/iio/light')
-rw-r--r--drivers/iio/light/apds9960.c20
1 files changed, 12 insertions, 8 deletions
diff --git a/drivers/iio/light/apds9960.c b/drivers/iio/light/apds9960.c
index b62c139baf41..997aa01ecc11 100644
--- a/drivers/iio/light/apds9960.c
+++ b/drivers/iio/light/apds9960.c
@@ -223,14 +223,16 @@ static const struct iio_event_spec apds9960_pxs_event_spec[] = {
{
.type = IIO_EV_TYPE_THRESH,
.dir = IIO_EV_DIR_RISING,
- .mask_separate = BIT(IIO_EV_INFO_VALUE) |
- BIT(IIO_EV_INFO_ENABLE),
+ .mask_separate = BIT(IIO_EV_INFO_VALUE),
},
{
.type = IIO_EV_TYPE_THRESH,
.dir = IIO_EV_DIR_FALLING,
- .mask_separate = BIT(IIO_EV_INFO_VALUE) |
- BIT(IIO_EV_INFO_ENABLE),
+ .mask_separate = BIT(IIO_EV_INFO_VALUE),
+ },
+ {
+ .type = IIO_EV_TYPE_THRESH,
+ .mask_separate = BIT(IIO_EV_INFO_ENABLE),
},
};
@@ -238,14 +240,16 @@ static const struct iio_event_spec apds9960_als_event_spec[] = {
{
.type = IIO_EV_TYPE_THRESH,
.dir = IIO_EV_DIR_RISING,
- .mask_separate = BIT(IIO_EV_INFO_VALUE) |
- BIT(IIO_EV_INFO_ENABLE),
+ .mask_separate = BIT(IIO_EV_INFO_VALUE),
},
{
.type = IIO_EV_TYPE_THRESH,
.dir = IIO_EV_DIR_FALLING,
- .mask_separate = BIT(IIO_EV_INFO_VALUE) |
- BIT(IIO_EV_INFO_ENABLE),
+ .mask_separate = BIT(IIO_EV_INFO_VALUE),
+ },
+ {
+ .type = IIO_EV_TYPE_THRESH,
+ .mask_separate = BIT(IIO_EV_INFO_ENABLE),
},
};