]> Git Repo - linux.git/commitdiff
evm: mark evm_fixmode as __ro_after_init
authorAustin Kim <[email protected]>
Thu, 28 Oct 2021 11:26:42 +0000 (12:26 +0100)
committerMimi Zohar <[email protected]>
Thu, 28 Oct 2021 22:52:49 +0000 (18:52 -0400)
The evm_fixmode is only configurable by command-line option and it is never
modified outside initcalls, so declaring it with __ro_after_init is better.

Signed-off-by: Austin Kim <[email protected]>
Cc: [email protected]
Signed-off-by: Mimi Zohar <[email protected]>
security/integrity/evm/evm_main.c

index 1c8435dfabeeaf240d6dc819bcba11cd2cd0497b..08f907382c6187b6616b5211aa6fbb360aff24b0 100644 (file)
@@ -78,7 +78,7 @@ static struct xattr_list evm_config_default_xattrnames[] = {
 
 LIST_HEAD(evm_config_xattrnames);
 
-static int evm_fixmode;
+static int evm_fixmode __ro_after_init;
 static int __init evm_set_fixmode(char *str)
 {
        if (strncmp(str, "fix", 3) == 0)
This page took 0.057782 seconds and 4 git commands to generate.