[PATCH] lockd and rpciod do not correctly drop locks

From: Robert Love (rml@tech9.net)
Date: Sat Jul 20 2002 - 15:22:05 EST


Linus,

lockd and rpciod exit without properly relinquishing the locks they
hold. This pisses off the preempt_count debugging in do_exit.

While in this case it is safe since the lock is the BKL, it is unclean
in my opinion.

I also hate seeing the debug message on unmount ;)

Patch is against 2.5.27, please apply.

        Robert Love

diff -urN linux-2.5.27/fs/lockd/svc.c linux/fs/lockd/svc.c
--- linux-2.5.27/fs/lockd/svc.c Sat Jul 20 12:11:25 2002
+++ linux/fs/lockd/svc.c Sat Jul 20 12:52:21 2002
@@ -203,6 +203,7 @@
         rpciod_down();
 
         /* Release module */
+ unlock_kernel();
         MOD_DEC_USE_COUNT;
 }
 
diff -urN linux-2.5.27/net/sunrpc/sched.c linux/net/sunrpc/sched.c
--- linux-2.5.27/net/sunrpc/sched.c Sat Jul 20 12:11:22 2002
+++ linux/net/sunrpc/sched.c Sat Jul 20 12:52:21 2002
@@ -1030,6 +1030,7 @@
         wake_up(assassin);
 
         dprintk("RPC: rpciod exiting\n");
+ unlock_kernel();
         MOD_DEC_USE_COUNT;
         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 : Tue Jul 23 2002 - 22:00:33 EST