Source-Changes-HG archive

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

[src/trunk]: src/sys/miscfs/genfs in genfs_putpages(), we must wait for any p...



details:   https://anonhg.NetBSD.org/src/rev/9359da1f1e47
branches:  trunk
changeset: 519940:9359da1f1e47
user:      chs <chs%NetBSD.org@localhost>
date:      Mon Dec 31 06:40:08 2001 +0000

description:
in genfs_putpages(), we must wait for any pending write i/os to complete
if the putpages request is synchronous.

diffstat:

 sys/miscfs/genfs/genfs_vnops.c |  8 +++++---
 1 files changed, 5 insertions(+), 3 deletions(-)

diffs (29 lines):

diff -r 32f8f4706dd9 -r 9359da1f1e47 sys/miscfs/genfs/genfs_vnops.c
--- a/sys/miscfs/genfs/genfs_vnops.c    Mon Dec 31 02:27:14 2001 +0000
+++ b/sys/miscfs/genfs/genfs_vnops.c    Mon Dec 31 06:40:08 2001 +0000
@@ -1,4 +1,4 @@
-/*     $NetBSD: genfs_vnops.c,v 1.43 2001/12/18 07:49:36 chs Exp $     */
+/*     $NetBSD: genfs_vnops.c,v 1.44 2001/12/31 06:40:08 chs Exp $     */
 
 /*
  * Copyright (c) 1982, 1986, 1989, 1993
@@ -35,7 +35,7 @@
  */
 
 #include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: genfs_vnops.c,v 1.43 2001/12/18 07:49:36 chs Exp $");
+__KERNEL_RCSID(0, "$NetBSD: genfs_vnops.c,v 1.44 2001/12/31 06:40:08 chs Exp $");
 
 #include "opt_nfsserver.h"
 
@@ -1037,7 +1037,9 @@
         */
 
        error = 0;
-       wasclean = TRUE;
+       s = splbio();
+       wasclean = (vp->v_numoutput == 0);
+       splx(s);
        off = startoff;
        if (endoff == 0 || flags & PGO_ALLPAGES) {
                endoff = trunc_page(LLONG_MAX);



Home | Main Index | Thread Index | Old Index