projects
/
platform
/
kernel
/
linux-rpi.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
a9d0683
)
HID: multitouch: constify attribute_group structures.
author
Arvind Yadav
<arvind.yadav.cs@gmail.com>
Thu, 3 Aug 2017 11:26:43 +0000
(16:56 +0530)
committer
Jiri Kosina
<jkosina@suse.cz>
Thu, 3 Aug 2017 11:38:29 +0000
(13:38 +0200)
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>
drivers/hid/hid-multitouch.c
patch
|
blob
|
history
diff --git
a/drivers/hid/hid-multitouch.c
b/drivers/hid/hid-multitouch.c
index
aff20f4
..
e8acf93
100644
(file)
--- a/
drivers/hid/hid-multitouch.c
+++ b/
drivers/hid/hid-multitouch.c
@@
-341,7
+341,7
@@
static struct attribute *sysfs_attrs[] = {
NULL
};
-static struct attribute_group mt_attribute_group = {
+static
const
struct attribute_group mt_attribute_group = {
.attrs = sysfs_attrs
};