summaryrefslogtreecommitdiff
path: root/fs/gfs2/xattr.c
diff options
context:
space:
mode:
authorWedson Almeida Filho <walmeida@microsoft.com>2023-09-30 02:00:16 -0300
committerChristian Brauner <brauner@kernel.org>2023-10-09 16:24:18 +0200
commit89491fafa81c7c4e6aeb8f1a21903bc65b77515e (patch)
tree1f0b1365e7d58a2bf5cbebbfbf000d2c82f5c328 /fs/gfs2/xattr.c
parent34271edb18787d0b7d0f14c505468378de7efb4d (diff)
gfs2: move gfs2_xattr_handlers_max to .rodata
This makes it harder for accidental or malicious changes to gfs2_xattr_handlers_max at runtime. Cc: Bob Peterson <rpeterso@redhat.com> Cc: Andreas Gruenbacher <agruenba@redhat.com> Cc: cluster-devel@redhat.com Signed-off-by: Wedson Almeida Filho <walmeida@microsoft.com> Link: https://lore.kernel.org/r/20230930050033.41174-13-wedsonaf@gmail.com Signed-off-by: Christian Brauner <brauner@kernel.org>
Diffstat (limited to 'fs/gfs2/xattr.c')
-rw-r--r--fs/gfs2/xattr.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/fs/gfs2/xattr.c b/fs/gfs2/xattr.c
index 4fea70c0fe3d..79d5c5559512 100644
--- a/fs/gfs2/xattr.c
+++ b/fs/gfs2/xattr.c
@@ -1494,7 +1494,7 @@ static const struct xattr_handler gfs2_xattr_trusted_handler = {
.set = gfs2_xattr_set,
};
-const struct xattr_handler *gfs2_xattr_handlers_max[] = {
+const struct xattr_handler * const gfs2_xattr_handlers_max[] = {
/* GFS2_FS_FORMAT_MAX */
&gfs2_xattr_trusted_handler,
@@ -1504,4 +1504,4 @@ const struct xattr_handler *gfs2_xattr_handlers_max[] = {
NULL,
};
-const struct xattr_handler **gfs2_xattr_handlers_min = gfs2_xattr_handlers_max + 1;
+const struct xattr_handler * const *gfs2_xattr_handlers_min = gfs2_xattr_handlers_max + 1;