summaryrefslogtreecommitdiff
path: root/security/tomoyo
diff options
context:
space:
mode:
authorMike Danese <mikedanese@google.com>2016-05-20 07:37:53 +0300
committerJames Morris <james.l.morris@oracle.com>2016-06-06 13:23:55 +0300
commit40d273782ff16fe1a7445cc05c66a447dfea3433 (patch)
treeb32ccd91a5cbc0b58cf2c1fcd84442c4fa17f2be /security/tomoyo
parentd6e0d306449bcb5fa3c80e7a3edf11d45abf9ae9 (diff)
downloadlinux-40d273782ff16fe1a7445cc05c66a447dfea3433.tar.xz
security: tomoyo: simplify the gc kthread creation
The code is doing the equivalent of the kthread_run macro. Signed-off-by: Mike Danese <mikedanese@google.com> Acked-by: Tetsuo Handa <penguin-kernel@I-love.SAKURA.ne.jp> Signed-off-by: James Morris <james.l.morris@oracle.com>
Diffstat (limited to 'security/tomoyo')
-rw-r--r--security/tomoyo/gc.c9
1 files changed, 2 insertions, 7 deletions
diff --git a/security/tomoyo/gc.c b/security/tomoyo/gc.c
index 986a6a756868..540bc29e1b5a 100644
--- a/security/tomoyo/gc.c
+++ b/security/tomoyo/gc.c
@@ -645,11 +645,6 @@ void tomoyo_notify_gc(struct tomoyo_io_buffer *head, const bool is_register)
}
}
spin_unlock(&tomoyo_io_buffer_list_lock);
- if (is_write) {
- struct task_struct *task = kthread_create(tomoyo_gc_thread,
- NULL,
- "GC for TOMOYO");
- if (!IS_ERR(task))
- wake_up_process(task);
- }
+ if (is_write)
+ kthread_run(tomoyo_gc_thread, NULL, "GC for TOMOYO");
}