aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorArvind Yadav <arvind.yadav.cs@gmail.com>2017-08-03 07:28:35 -0400
committerJiri Kosina <jkosina@suse.cz>2017-08-03 07:38:30 -0400
commit58ee3e08aa4438467642fb280d3157c803081c0f (patch)
treed3c0c16c475bb17b1f6d70ddd0995005a0f9cccc
parent9182fb98d64baad43a5721c7617cbf91a89279dd (diff)
HID: sensor: constify attribute_group structures.
attribute_group are not supposed to change at runtime. All functions working with attribute_group provided by <linux/sysfs.h> work with const attribute_group. So mark the non-const structs as const. Signed-off-by: Arvind Yadav <arvind.yadav.cs@gmail.com> Signed-off-by: Jiri Kosina <jkosina@suse.cz>
-rw-r--r--drivers/hid/hid-sensor-custom.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/hid/hid-sensor-custom.c b/drivers/hid/hid-sensor-custom.c
index 3a84aaf1418b..fb86f86b9d92 100644
--- a/drivers/hid/hid-sensor-custom.c
+++ b/drivers/hid/hid-sensor-custom.c
@@ -276,7 +276,7 @@ static struct attribute *enable_sensor_attrs[] = {
276 NULL, 276 NULL,
277}; 277};
278 278
279static struct attribute_group enable_sensor_attr_group = { 279static const struct attribute_group enable_sensor_attr_group = {
280 .attrs = enable_sensor_attrs, 280 .attrs = enable_sensor_attrs,
281}; 281};
282 282