summaryrefslogtreecommitdiff
path: root/security/tomoyo/gc.c
diff options
context:
space:
mode:
authorTetsuo Handa <penguin-kernel@I-love.SAKURA.ne.jp>2024-09-23 19:00:21 +0900
committerTetsuo Handa <penguin-kernel@I-love.SAKURA.ne.jp>2024-09-23 19:00:21 +0900
commit268225a1de1a021bac4884e7d61fe047345cc9be (patch)
treeacd18a3ba0b208740dfb71514db1833c9490c4bb /security/tomoyo/gc.c
parentde5cb0dcb74c294ec527eddfe5094acfdb21ff21 (diff)
tomoyo: preparation step for building as a loadable LSM module
In order to allow Makefile to generate tomoyo.ko as output, rename tomoyo.c to hooks.h and cut out LSM hook registration part that will be built into vmlinux from hooks.h to init.c . Also, update comments and relocate some variables. No behavior changes. Signed-off-by: Tetsuo Handa <penguin-kernel@I-love.SAKURA.ne.jp>
Diffstat (limited to 'security/tomoyo/gc.c')
-rw-r--r--security/tomoyo/gc.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/security/tomoyo/gc.c b/security/tomoyo/gc.c
index 026e29ea3796..6eccca150839 100644
--- a/security/tomoyo/gc.c
+++ b/security/tomoyo/gc.c
@@ -9,6 +9,9 @@
#include <linux/kthread.h>
#include <linux/slab.h>
+/* Lock for GC. */
+DEFINE_SRCU(tomoyo_ss);
+
/**
* tomoyo_memory_free - Free memory for elements.
*