linux-mm.kvack.org archive mirror
 help / color / mirror / Atom feed
* [PATCH 28/29] shmem: move shmem_xattr_handlers to .rodata
       [not found] <20230930050033.41174-1-wedsonaf@gmail.com>
@ 2023-09-30  5:00 ` Wedson Almeida Filho
  0 siblings, 0 replies; only message in thread
From: Wedson Almeida Filho @ 2023-09-30  5:00 UTC (permalink / raw)
  To: Alexander Viro, Christian Brauner, linux-fsdevel
  Cc: linux-kernel, Wedson Almeida Filho, Hugh Dickins, Andrew Morton,
	linux-mm

From: Wedson Almeida Filho <walmeida@microsoft.com>

This makes it harder for accidental or malicious changes to
shmem_xattr_handlers at runtime.

Cc: Hugh Dickins <hughd@google.com>
Cc: Andrew Morton <akpm@linux-foundation.org>
Cc: linux-mm@kvack.org
Signed-off-by: Wedson Almeida Filho <walmeida@microsoft.com>
---
 mm/shmem.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/mm/shmem.c b/mm/shmem.c
index d963c747dabc..683c84d667c1 100644
--- a/mm/shmem.c
+++ b/mm/shmem.c
@@ -3487,7 +3487,7 @@ static const struct xattr_handler shmem_trusted_xattr_handler = {
 	.set = shmem_xattr_handler_set,
 };
 
-static const struct xattr_handler *shmem_xattr_handlers[] = {
+static const struct xattr_handler * const shmem_xattr_handlers[] = {
 	&shmem_security_xattr_handler,
 	&shmem_trusted_xattr_handler,
 	NULL
-- 
2.34.1



^ permalink raw reply	[flat|nested] only message in thread

only message in thread, other threads:[~2023-09-30  5:02 UTC | newest]

Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
     [not found] <20230930050033.41174-1-wedsonaf@gmail.com>
2023-09-30  5:00 ` [PATCH 28/29] shmem: move shmem_xattr_handlers to .rodata Wedson Almeida Filho

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox