Source-Changes-HG archive

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

[src/trunk]: src/sys/arch/i386/i386 bdevvp returns a locked vnode, so vput it...



details:   https://anonhg.NetBSD.org/src/rev/07926b72950f
branches:  trunk
changeset: 477253:07926b72950f
user:      fvdl <fvdl%NetBSD.org@localhost>
date:      Mon Oct 18 19:37:28 1999 +0000

description:
bdevvp returns a locked vnode, so vput it. From Bill Studenmund.

diffstat:

 sys/arch/i386/i386/autoconf.c |  11 +++++------
 1 files changed, 5 insertions(+), 6 deletions(-)

diffs (46 lines):

diff -r 0af9463ce107 -r 07926b72950f sys/arch/i386/i386/autoconf.c
--- a/sys/arch/i386/i386/autoconf.c     Mon Oct 18 17:23:00 1999 +0000
+++ b/sys/arch/i386/i386/autoconf.c     Mon Oct 18 19:37:28 1999 +0000
@@ -1,4 +1,4 @@
-/*     $NetBSD: autoconf.c,v 1.41 1999/09/17 19:59:42 thorpej Exp $    */
+/*     $NetBSD: autoconf.c,v 1.42 1999/10/18 19:37:28 fvdl Exp $       */
 
 /*-
  * Copyright (c) 1990 The Regents of the University of California.
@@ -190,7 +190,7 @@
 
                        error = VOP_OPEN(tv, FREAD, NOCRED, 0);
                        if (error) {
-                               vrele(tv);
+                               vput(tv);
                                continue;
                        }
                        error = vn_rdwr(UIO_READ, tv, mbr, DEV_BSIZE, 0,
@@ -227,7 +227,7 @@
                                }
                        }
                        i386_alldisks->dl_nativedisks[n].ni_nmatches = m;
-                       vrele(tv);
+                       vput(tv);
                }
        }
 }
@@ -287,7 +287,7 @@
 #endif
                        printf("findroot: can't open dev %s%c (%d)\n",
                               dv->dv_xname, 'a' + bid->partition, error);
-               vrele(tmpvn);
+               vput(tmpvn);
                return(0);
        }
        error = VOP_IOCTL(tmpvn, DIOCGDINFO, (caddr_t)&label, FREAD, NOCRED, 0);
@@ -309,8 +309,7 @@
 
 closeout:
        VOP_CLOSE(tmpvn, FREAD, NOCRED, 0);
-       vrele(tmpvn);
-
+       vput(tmpvn);
        return(found);
 }
 



Home | Main Index | Thread Index | Old Index