lkml.org 
[lkml]   [2002]   [Apr]   [4]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
Patches in this message
/
Date
From
SubjectRe: [patch] kjournald locking fix
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;
}--- 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;
}
\
 
 \ /
  Last update: 2005-03-22 13:22    [W:0.041 / U:3.384 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site