diff --git a/usr/src/uts/common/fs/dnlc.c b/usr/src/uts/common/fs/dnlc.c index 102375dedd..c53d4f2920 100644 --- a/usr/src/uts/common/fs/dnlc.c +++ b/usr/src/uts/common/fs/dnlc.c @@ -589,6 +589,7 @@ dnlc_lookup(vnode_t *dp, const char *name) vnode_t *vp; int hash, depth; uchar_t namlen; + int moved, found; TRACE_2(TR_FAC_NFS, TR_DNLC_LOOKUP_START, "dnlc_lookup_start:dp %x name %s", dp, name); @@ -602,6 +603,8 @@ dnlc_lookup(vnode_t *dp, const char *name) DNLCHASH(name, dp, hash, namlen); depth = 1; + moved = 0; + found = 0; hp = &nc_hash[hash & nc_hashmask]; mutex_enter(&hp->hash_lock); @@ -627,6 +630,7 @@ dnlc_lookup(vnode_t *dp, const char *name) hp->hash_next = ncp; ncstats.move_to_front++; + moved = 1; } /* @@ -645,6 +649,8 @@ dnlc_lookup(vnode_t *dp, const char *name) TRACE_4(TR_FAC_NFS, TR_DNLC_LOOKUP_END, "dnlc_lookup_end:%S %d vp %x name %s", "hit", ncstats.hits, vp, name); + found = 1; + DTRACE_PROBE3(dnlc__lookup, int, depth - 1, int, moved, int, found); return (vp); } depth++; @@ -656,6 +662,7 @@ dnlc_lookup(vnode_t *dp, const char *name) TRACE_4(TR_FAC_NFS, TR_DNLC_LOOKUP_END, "dnlc_lookup_end:%S %d vp %x name %s", "miss", ncstats.misses, NULL, name); + DTRACE_PROBE3(dnlc__lookup, int, depth - 1, int, moved, int, found); return (NULL); }