summaryrefslogtreecommitdiff
path: root/fs/locks.c
diff options
context:
space:
mode:
authorAlexey Dobriyan <adobriyan@gmail.com>2023-10-11 19:55:00 +0300
committerAndrew Morton <akpm@linux-foundation.org>2023-10-18 14:43:23 -0700
commit68279f9c9f592e75d30a9ba5154a15e0a0b42ae8 (patch)
treeacbebe6f512f63e0bdcf876a4fb4991520a5499f /fs/locks.c
parent1b13a7030504da9d379270675166342e7039817c (diff)
treewide: mark stuff as __ro_after_init
__read_mostly predates __ro_after_init. Many variables which are marked __read_mostly should have been __ro_after_init from day 1. Also, mark some stuff as "const" and "__init" while I'm at it. [akpm@linux-foundation.org: revert sysctl_nr_open_min, sysctl_nr_open_max changes due to arm warning] [akpm@linux-foundation.org: coding-style cleanups] Link: https://lkml.kernel.org/r/4f6bb9c0-abba-4ee4-a7aa-89265e886817@p183 Signed-off-by: Alexey Dobriyan <adobriyan@gmail.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Diffstat (limited to 'fs/locks.c')
-rw-r--r--fs/locks.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/fs/locks.c b/fs/locks.c
index 76ad05f8070a..dbd2fb1f7494 100644
--- a/fs/locks.c
+++ b/fs/locks.c
@@ -167,8 +167,8 @@ static DEFINE_HASHTABLE(blocked_hash, BLOCKED_HASH_BITS);
*/
static DEFINE_SPINLOCK(blocked_lock_lock);
-static struct kmem_cache *flctx_cache __read_mostly;
-static struct kmem_cache *filelock_cache __read_mostly;
+static struct kmem_cache *flctx_cache __ro_after_init;
+static struct kmem_cache *filelock_cache __ro_after_init;
static struct file_lock_context *
locks_get_lock_context(struct inode *inode, int type)