Skip to content

Commit 0dae522

Browse files
rikardfalkebornmartinetd
authored andcommitted
9p: Constify static struct v9fs_attr_group
The only usage of v9fs_attr_group is to pass its address to sysfs_create_group() and sysfs_create_group(), both which takes pointers to const struct attribute_group. Make it const to allow the compiler to put it in read-only memory. Link: http://lkml.kernel.org/r/[email protected] Signed-off-by: Rikard Falkeborn <[email protected]> Signed-off-by: Dominique Martinet <[email protected]>
1 parent a5e13c6 commit 0dae522

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

fs/9p/v9fs.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -583,7 +583,7 @@ static struct attribute *v9fs_attrs[] = {
583583
NULL,
584584
};
585585

586-
static struct attribute_group v9fs_attr_group = {
586+
static const struct attribute_group v9fs_attr_group = {
587587
.attrs = v9fs_attrs,
588588
};
589589

0 commit comments

Comments
 (0)