Source-Changes-HG archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

[src/trunk]: src/sys/nfs fix a deadlock due to a spl problem.



details:   https://anonhg.NetBSD.org/src/rev/fa332d89e52e
branches:  trunk
changeset: 586840:fa332d89e52e
user:      yamt <yamt%NetBSD.org@localhost>
date:      Tue Jan 03 22:25:48 2006 +0000

description:
fix a deadlock due to a spl problem.

diffstat:

 sys/nfs/nfs_syscalls.c |  7 ++++---
 1 files changed, 4 insertions(+), 3 deletions(-)

diffs (36 lines):

diff -r a7b654da7064 -r fa332d89e52e sys/nfs/nfs_syscalls.c
--- a/sys/nfs/nfs_syscalls.c    Tue Jan 03 21:34:05 2006 +0000
+++ b/sys/nfs/nfs_syscalls.c    Tue Jan 03 22:25:48 2006 +0000
@@ -1,4 +1,4 @@
-/*     $NetBSD: nfs_syscalls.c,v 1.86 2006/01/03 12:30:01 yamt Exp $   */
+/*     $NetBSD: nfs_syscalls.c,v 1.87 2006/01/03 22:25:48 yamt Exp $   */
 
 /*
  * Copyright (c) 1989, 1993
@@ -35,7 +35,7 @@
  */
 
 #include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: nfs_syscalls.c,v 1.86 2006/01/03 12:30:01 yamt Exp $");
+__KERNEL_RCSID(0, "$NetBSD: nfs_syscalls.c,v 1.87 2006/01/03 22:25:48 yamt Exp $");
 
 #include "fs_nfs.h"
 #include "opt_nfs.h"
@@ -791,15 +791,16 @@
                                        nfsd_rt(slp->ns_so->so_type, nd,
                                            cacherep);
                                }
+                               s = splsoftnet();
                                error = nfsdsock_sendreply(slp, nd);
                                nd = NULL;
                                if (error == EPIPE)
                                        nfsrv_zapsock(slp);
                                if (error == EINTR || error == ERESTART) {
                                        nfsrv_slpderef(slp);
-                                       s = splsoftnet();
                                        goto done;
                                }
+                               splx(s);
                                break;
                        case RC_DROPIT:
                                if (nfsrtton)



Home | Main Index | Thread Index | Old Index