]> err.no Git - linux-2.6/commitdiff
[PATCH] Add try_to_freeze to kauditd
authorPierre Ossman <drzeus@drzeus.cx>
Mon, 12 Dec 2005 08:37:22 +0000 (00:37 -0800)
committerLinus Torvalds <torvalds@g5.osdl.org>
Mon, 12 Dec 2005 16:57:43 +0000 (08:57 -0800)
kauditd was causing suspends to fail because it refused to freeze.  Adding
a try_to_freeze() to its sleep loop solves the issue.

Signed-off-by: Pierre Ossman <drzeus@drzeus.cx>
Acked-by: Pavel Machek <pavel@suse.cz>
Cc: David Woodhouse <dwmw2@infradead.org>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
kernel/audit.c

index 0c56320d38dc38eac05fb4eb04b5d0e626352019..32fa03ad1984da1395386d99deee3b98e073648d 100644 (file)
@@ -291,8 +291,10 @@ int kauditd_thread(void *dummy)
                        set_current_state(TASK_INTERRUPTIBLE);
                        add_wait_queue(&kauditd_wait, &wait);
 
-                       if (!skb_queue_len(&audit_skb_queue))
+                       if (!skb_queue_len(&audit_skb_queue)) {
+                               try_to_freeze();
                                schedule();
+                       }
 
                        __set_current_state(TASK_RUNNING);
                        remove_wait_queue(&kauditd_wait, &wait);