Module Name: src Committed By: dholland Date: Mon Apr 11 02:13:10 UTC 2011
Modified Files: src/sys/kern: vfs_lookup.c Log Message: description: namei_end() doesn't really do anything useful at this point, so get rid of it. To generate a diff of this commit: cvs rdiff -u -r1.150 -r1.151 src/sys/kern/vfs_lookup.c Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files.
Modified files: Index: src/sys/kern/vfs_lookup.c diff -u src/sys/kern/vfs_lookup.c:1.150 src/sys/kern/vfs_lookup.c:1.151 --- src/sys/kern/vfs_lookup.c:1.150 Mon Apr 11 02:12:58 2011 +++ src/sys/kern/vfs_lookup.c Mon Apr 11 02:13:10 2011 @@ -1,4 +1,4 @@ -/* $NetBSD: vfs_lookup.c,v 1.150 2011/04/11 02:12:58 dholland Exp $ */ +/* $NetBSD: vfs_lookup.c,v 1.151 2011/04/11 02:13:10 dholland Exp $ */ /* * Copyright (c) 1982, 1986, 1989, 1993 @@ -37,7 +37,7 @@ */ #include <sys/cdefs.h> -__KERNEL_RCSID(0, "$NetBSD: vfs_lookup.c,v 1.150 2011/04/11 02:12:58 dholland Exp $"); +__KERNEL_RCSID(0, "$NetBSD: vfs_lookup.c,v 1.151 2011/04/11 02:13:10 dholland Exp $"); #include "opt_magiclinks.h" @@ -626,15 +626,6 @@ } /* - * Undo namei_start: unlock and release the current lookup directory. - */ -static void -namei_end(struct namei_state *state) -{ - vput(state->namei_startdir); -} - -/* * Check for being at a symlink. */ static inline int @@ -1077,7 +1068,7 @@ * XXX: should this also check if it's unlinked? */ if (state->namei_startdir->v_mount == NULL) { - namei_end(state); + vput(state->namei_startdir); return (ENOENT); } @@ -1109,7 +1100,6 @@ if (searchdir->v_type != VDIR) { vput(searchdir); ndp->ni_vp = NULL; - /* XXX this should use namei_end() */ if (ndp->ni_dvp) { vput(ndp->ni_dvp); } @@ -1136,7 +1126,6 @@ vput(searchdir); ndp->ni_dvp = NULL; ndp->ni_vp = NULL; - /* XXX this should use namei_end() */ if (ndp->ni_dvp) { vput(ndp->ni_dvp); } @@ -1148,7 +1137,6 @@ ndp->ni_dvp = searchdir; if (error) { ndp->ni_vp = NULL; - /* XXX this should use namei_end() */ if (ndp->ni_dvp) { vput(ndp->ni_dvp); } @@ -1209,7 +1197,6 @@ KASSERT(foundobj != ndp->ni_dvp); vput(foundobj); ndp->ni_vp = NULL; - /* XXX this should use namei_end() */ if (ndp->ni_dvp) { vput(ndp->ni_dvp); } @@ -1277,7 +1264,6 @@ } vput(foundobj); foundobj = NULL; - /* XXX this should use namei_end() */ if (ndp->ni_dvp) { vput(ndp->ni_dvp); } @@ -1296,7 +1282,6 @@ vput(foundobj); } ndp->ni_vp = NULL; - /* XXX this should use namei_end() */ if (ndp->ni_dvp) { vput(ndp->ni_dvp); }