Re: [PATCH] 9p: Constify static struct v9fs_attr_group

2021-01-08 Thread Dominique Martinet
Rikard Falkeborn wrote on Fri, Jan 08, 2021 at 11:46:50PM +0100: > 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

[PATCH] 9p: Constify static struct v9fs_attr_group

2021-01-08 Thread Rikard Falkeborn
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. Signed-off-by: Rikard Falkeborn --- fs/9p/v9fs.c | 2 +- 1 file