Re: [patch] kjournald locking fix

From: Ishan O. Jayawardena (ioshadij@hotmail.com)
Date: Thu Apr 04 2002 - 17:55:35 EST


Greetings everyone,

        Here's an improved version of my previous patch. Thanks to Andrew
Morton for the advice. 2.5 needs this too I think, since preemption is
part of it now...

Ishan O. Jayawardena

----------------------------------------------------------------

--- linux-preempt/fs/jbd/journal.c.1 Wed Apr 3 08:05:08 2002
+++ linux-preempt/fs/jbd/journal.c Thu Apr 4 16:41:56 2002
@@ -204,6 +204,7 @@ int kjournald(void *arg)
 
         lock_kernel();
         daemonize();
+ reparent_to_init();
         spin_lock_irq(&current->sigmask_lock);
         sigfillset(&current->blocked);
         recalc_sigpending(current);
@@ -267,6 +268,7 @@ int kjournald(void *arg)
 
         journal->j_task = NULL;
         wake_up(&journal->j_wait_done_commit);
+ unlock_kernel();
         jbd_debug(1, "Journal thread exiting.\n");
         return 0;
 }



-
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/



This archive was generated by hypermail 2b29 : Sun Apr 07 2002 - 22:00:13 EST