diff mbox series

[2/2] iio: st_magn_core.c: activate always_on attribute

Message ID 20220207090443.3710425-3-massimo.toscanelli@leica-geosystems.com (mailing list archive)
State Rejected
Headers show
Series Solve data access delay of ST sensors | expand

Commit Message

TOSCANELLI Massimo Feb. 7, 2022, 9:04 a.m. UTC
Activate always_on sysfs attribute to add the always_on feature in
st magnetometers.

Signed-off-by: Massimo Toscanelli <massimo.toscanelli@leica-geosystems.com>
---
 drivers/iio/magnetometer/st_magn_core.c | 2 ++
 1 file changed, 2 insertions(+)
diff mbox series

Patch

diff --git a/drivers/iio/magnetometer/st_magn_core.c b/drivers/iio/magnetometer/st_magn_core.c
index 0806a1e65ce4..2ab4c286d262 100644
--- a/drivers/iio/magnetometer/st_magn_core.c
+++ b/drivers/iio/magnetometer/st_magn_core.c
@@ -563,9 +563,11 @@  static int st_magn_write_raw(struct iio_dev *indio_dev,
 static ST_SENSORS_DEV_ATTR_SAMP_FREQ_AVAIL();
 static ST_SENSORS_DEV_ATTR_SCALE_AVAIL(in_magn_scale_available);
 
+static ST_SENSORS_DEV_ATTR_ALWAYS_ON();
 static struct attribute *st_magn_attributes[] = {
 	&iio_dev_attr_sampling_frequency_available.dev_attr.attr,
 	&iio_dev_attr_in_magn_scale_available.dev_attr.attr,
+	&iio_dev_attr_always_on.dev_attr.attr,
 	NULL,
 };