Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S932448AbVKGHNE (ORCPT ); Mon, 7 Nov 2005 02:13:04 -0500 Received: (majordomo@vger.kernel.org) by vger.kernel.org id S932449AbVKGHNE (ORCPT ); Mon, 7 Nov 2005 02:13:04 -0500 Received: from [85.8.13.51] ([85.8.13.51]:51863 "EHLO smtp.drzeus.cx") by vger.kernel.org with ESMTP id S932448AbVKGHNB (ORCPT ); Mon, 7 Nov 2005 02:13:01 -0500 From: Pierre Ossman Subject: [PATCH] [MMC] Add try_to_freeze to kauditd Date: Mon, 07 Nov 2005 08:13:00 +0100 Cc: Pierre Ossman To: akpm@osdl.org Cc: pavel@suse.cz, linux-kernel@vger.kernel.org Message-Id: <20051107071300.7073.47106.stgit@poseidon.drzeus.cx> Sender: linux-kernel-owner@vger.kernel.org X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 989 Lines: 31 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 Acked-by: Pavel Machek --- kernel/audit.c | 4 +++- 1 files changed, 3 insertions(+), 1 deletions(-) diff --git a/kernel/audit.c b/kernel/audit.c --- a/kernel/audit.c +++ b/kernel/audit.c @@ -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); - To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/