summaryrefslogtreecommitdiff
path: root/security/tomoyo
diff options
context:
space:
mode:
authorJames Morris <jmorris@namei.org>2017-02-14 16:18:51 +0300
committerJames Morris <james.l.morris@oracle.com>2017-03-06 03:00:15 +0300
commitca97d939db114c8d1619e10a3b82af8615372dae (patch)
treecb16c707c4015b2dcbfc1f783071b5980ddd9145 /security/tomoyo
parentdd0859dccbe291cf8179a96390f5c0e45cb9af1d (diff)
downloadlinux-ca97d939db114c8d1619e10a3b82af8615372dae.tar.xz
security: mark LSM hooks as __ro_after_init
Mark all of the registration hooks as __ro_after_init (via the __lsm_ro_after_init macro). Signed-off-by: James Morris <james.l.morris@oracle.com> Acked-by: Stephen Smalley <sds@tycho.nsa.gov> Acked-by: Kees Cook <keescook@chromium.org>
Diffstat (limited to 'security/tomoyo')
-rw-r--r--security/tomoyo/tomoyo.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/security/tomoyo/tomoyo.c b/security/tomoyo/tomoyo.c
index edc52d620f29..b5fb930349a9 100644
--- a/security/tomoyo/tomoyo.c
+++ b/security/tomoyo/tomoyo.c
@@ -496,7 +496,7 @@ static int tomoyo_socket_sendmsg(struct socket *sock, struct msghdr *msg,
* tomoyo_security_ops is a "struct security_operations" which is used for
* registering TOMOYO.
*/
-static struct security_hook_list tomoyo_hooks[] = {
+static struct security_hook_list tomoyo_hooks[] __lsm_ro_after_init = {
LSM_HOOK_INIT(cred_alloc_blank, tomoyo_cred_alloc_blank),
LSM_HOOK_INIT(cred_prepare, tomoyo_cred_prepare),
LSM_HOOK_INIT(cred_transfer, tomoyo_cred_transfer),