Commit eace45a1 authored by Trond Myklebust's avatar Trond Myklebust

NFS: Trace effects of readdirplus on the dcache

Trace the effects of readdirplus on attribute and dentry revalidation.
Signed-off-by: default avatarTrond Myklebust <trond.myklebust@hammerspace.com>
parent 310e3187
...@@ -754,8 +754,12 @@ void nfs_prime_dcache(struct dentry *parent, struct nfs_entry *entry, ...@@ -754,8 +754,12 @@ void nfs_prime_dcache(struct dentry *parent, struct nfs_entry *entry,
status = nfs_refresh_inode(d_inode(dentry), entry->fattr); status = nfs_refresh_inode(d_inode(dentry), entry->fattr);
if (!status) if (!status)
nfs_setsecurity(d_inode(dentry), entry->fattr); nfs_setsecurity(d_inode(dentry), entry->fattr);
trace_nfs_readdir_lookup_revalidate(d_inode(parent),
dentry, 0, status);
goto out; goto out;
} else { } else {
trace_nfs_readdir_lookup_revalidate_failed(
d_inode(parent), dentry, 0);
d_invalidate(dentry); d_invalidate(dentry);
dput(dentry); dput(dentry);
dentry = NULL; dentry = NULL;
...@@ -777,6 +781,7 @@ void nfs_prime_dcache(struct dentry *parent, struct nfs_entry *entry, ...@@ -777,6 +781,7 @@ void nfs_prime_dcache(struct dentry *parent, struct nfs_entry *entry,
dentry = alias; dentry = alias;
} }
nfs_set_verifier(dentry, dir_verifier); nfs_set_verifier(dentry, dir_verifier);
trace_nfs_readdir_lookup(d_inode(parent), dentry, 0);
out: out:
dput(dentry); dput(dentry);
} }
......
...@@ -432,6 +432,9 @@ DEFINE_NFS_LOOKUP_EVENT(nfs_lookup_enter); ...@@ -432,6 +432,9 @@ DEFINE_NFS_LOOKUP_EVENT(nfs_lookup_enter);
DEFINE_NFS_LOOKUP_EVENT_DONE(nfs_lookup_exit); DEFINE_NFS_LOOKUP_EVENT_DONE(nfs_lookup_exit);
DEFINE_NFS_LOOKUP_EVENT(nfs_lookup_revalidate_enter); DEFINE_NFS_LOOKUP_EVENT(nfs_lookup_revalidate_enter);
DEFINE_NFS_LOOKUP_EVENT_DONE(nfs_lookup_revalidate_exit); DEFINE_NFS_LOOKUP_EVENT_DONE(nfs_lookup_revalidate_exit);
DEFINE_NFS_LOOKUP_EVENT(nfs_readdir_lookup);
DEFINE_NFS_LOOKUP_EVENT(nfs_readdir_lookup_revalidate_failed);
DEFINE_NFS_LOOKUP_EVENT_DONE(nfs_readdir_lookup_revalidate);
TRACE_EVENT(nfs_atomic_open_enter, TRACE_EVENT(nfs_atomic_open_enter,
TP_PROTO( TP_PROTO(
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment