diff options
author | Eric Paris <eparis@redhat.com> | 2013-05-07 21:24:02 -0400 |
---|---|---|
committer | Eric Paris <eparis@redhat.com> | 2013-05-07 22:27:21 -0400 |
commit | 82d8da0d46ae7d3e9089efadb5e8d9841c20a431 (patch) | |
tree | 363caec82ec31d6d8d7f4559f265d2521322fcb0 | |
parent | 33e2208acfc15ce00d3dd13e839bf6434faa2b04 (diff) |
Revert "audit: move kaudit thread start from auditd registration to kaudit init"
This reverts commit 6ff5e45985c2fcb97947818f66d1eeaf9d6600b2.
Conflicts:
kernel/audit.c
This patch was starting a kthread for all the time. Since the follow on
patches that required it didn't get finished in 3.10 time, we shouldn't
ship this change in 3.10.
Signed-off-by: Eric Paris <eparis@redhat.com>
-rw-r--r-- | kernel/audit.c | 14 |
1 files changed, 10 insertions, 4 deletions
diff --git a/kernel/audit.c b/kernel/audit.c index 8cc580316948..f9c6506536e6 100644 --- a/kernel/audit.c +++ b/kernel/audit.c | |||
@@ -644,6 +644,16 @@ static int audit_receive_msg(struct sk_buff *skb, struct nlmsghdr *nlh) | |||
644 | if (err) | 644 | if (err) |
645 | return err; | 645 | return err; |
646 | 646 | ||
647 | /* As soon as there's any sign of userspace auditd, | ||
648 | * start kauditd to talk to it */ | ||
649 | if (!kauditd_task) | ||
650 | kauditd_task = kthread_run(kauditd_thread, NULL, "kauditd"); | ||
651 | if (IS_ERR(kauditd_task)) { | ||
652 | err = PTR_ERR(kauditd_task); | ||
653 | kauditd_task = NULL; | ||
654 | return err; | ||
655 | } | ||
656 | |||
647 | seq = nlh->nlmsg_seq; | 657 | seq = nlh->nlmsg_seq; |
648 | data = nlmsg_data(nlh); | 658 | data = nlmsg_data(nlh); |
649 | 659 | ||
@@ -895,10 +905,6 @@ static int __init audit_init(void) | |||
895 | else | 905 | else |
896 | audit_sock->sk_sndtimeo = MAX_SCHEDULE_TIMEOUT; | 906 | audit_sock->sk_sndtimeo = MAX_SCHEDULE_TIMEOUT; |
897 | 907 | ||
898 | kauditd_task = kthread_run(kauditd_thread, NULL, "kauditd"); | ||
899 | if (IS_ERR(kauditd_task)) | ||
900 | return PTR_ERR(kauditd_task); | ||
901 | |||
902 | skb_queue_head_init(&audit_skb_queue); | 908 | skb_queue_head_init(&audit_skb_queue); |
903 | skb_queue_head_init(&audit_skb_hold_queue); | 909 | skb_queue_head_init(&audit_skb_hold_queue); |
904 | audit_initialized = AUDIT_INITIALIZED; | 910 | audit_initialized = AUDIT_INITIALIZED; |