Source-Changes-HG archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
[src/trunk]: src/sys/nfs fix nfs iod management so we don't lose i/os when io...
details: https://anonhg.NetBSD.org/src/rev/61442e3c48a7
branches: trunk
changeset: 498416:61442e3c48a7
user: chs <chs%NetBSD.org@localhost>
date: Mon Oct 23 07:18:27 2000 +0000
description:
fix nfs iod management so we don't lose i/os when iods die.
diffstat:
sys/nfs/nfs_syscalls.c | 17 +++++++++--------
1 files changed, 9 insertions(+), 8 deletions(-)
diffs (40 lines):
diff -r 2a41a1d92fc2 -r 61442e3c48a7 sys/nfs/nfs_syscalls.c
--- a/sys/nfs/nfs_syscalls.c Mon Oct 23 06:56:00 2000 +0000
+++ b/sys/nfs/nfs_syscalls.c Mon Oct 23 07:18:27 2000 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: nfs_syscalls.c,v 1.44 2000/09/19 22:14:42 fvdl Exp $ */
+/* $NetBSD: nfs_syscalls.c,v 1.45 2000/10/23 07:18:27 chs Exp $ */
/*
* Copyright (c) 1989, 1993
@@ -951,13 +951,7 @@
error = tsleep((caddr_t)&nfs_iodwant[myiod],
PWAIT | PCATCH, "nfsidl", 0);
}
- if (error) {
- if (nmp)
- nmp->nm_bufqiods--;
- nfs_iodmount[myiod] = NULL;
- break;
- }
- while ((bp = nmp->nm_bufq.tqh_first) != NULL) {
+ while (nmp != NULL && (bp = nmp->nm_bufq.tqh_first) != NULL) {
/* Take one off the front of the list */
TAILQ_REMOVE(&nmp->nm_bufq, bp, b_freelist);
nmp->nm_bufqlen--;
@@ -979,8 +973,15 @@
break;
}
}
+ if (error) {
+ break;
+ }
}
p->p_holdcnt--;
+ if (nmp)
+ nmp->nm_bufqiods--;
+ nfs_iodwant[myiod] = NULL;
+ nfs_iodmount[myiod] = NULL;
nfs_asyncdaemon[myiod] = NULL;
nfs_numasync--;
Home |
Main Index |
Thread Index |
Old Index