summaryrefslogtreecommitdiffstats
path: root/sys/kern/vfs_cache.c
diff options
context:
space:
mode:
Diffstat (limited to 'sys/kern/vfs_cache.c')
-rw-r--r--sys/kern/vfs_cache.c12
1 files changed, 3 insertions, 9 deletions
diff --git a/sys/kern/vfs_cache.c b/sys/kern/vfs_cache.c
index f00307c..a541d76 100644
--- a/sys/kern/vfs_cache.c
+++ b/sys/kern/vfs_cache.c
@@ -423,15 +423,8 @@ retry_wlocked:
*vpp = dvp->v_cache_dd->nc_dvp;
/* Return failure if negative entry was found. */
if (*vpp == NULL) {
- numneghits++;
- nchstats.ncs_neghits++;
- SDT_PROBE(vfs, namecache, lookup, hit_negative,
- dvp, "..", 0, 0, 0);
- if (wlocked)
- CACHE_WUNLOCK();
- else
- CACHE_RUNLOCK();
- return (ENOENT);
+ ncp = dvp->v_cache_dd;
+ goto negative_success;
}
CTR3(KTR_VFS, "cache_lookup(%p, %s) found %p via ..",
dvp, cnp->cn_nameptr, *vpp);
@@ -486,6 +479,7 @@ retry_wlocked:
goto success;
}
+negative_success:
/* We found a negative match, and want to create it, so purge */
if (cnp->cn_nameiop == CREATE) {
numnegzaps++;
OpenPOWER on IntegriCloud