diff options
author | Chuck Lever <chuck.lever@oracle.com> | 2022-07-08 20:26:49 +0200 |
---|---|---|
committer | Chuck Lever <chuck.lever@oracle.com> | 2022-07-30 02:16:07 +0200 |
commit | b40a2839470cd62ed68c4a32d72a18ee8975b1ac (patch) | |
tree | 5fa4827b0bcbcebd1d278045864f78e34830cffe /fs/nfsd/filecache.c | |
parent | NFSD: Separate tracepoints for acquire and create (diff) | |
download | linux-b40a2839470cd62ed68c4a32d72a18ee8975b1ac.tar.xz linux-b40a2839470cd62ed68c4a32d72a18ee8975b1ac.zip |
NFSD: Move nfsd_file_trace_alloc() tracepoint
Avoid recording the allocation of an nfsd_file item that is
immediately released because a matching item was already
inserted in the hash.
Reviewed-by: Jeff Layton <jlayton@kernel.org>
Signed-off-by: Chuck Lever <chuck.lever@oracle.com>
Diffstat (limited to 'fs/nfsd/filecache.c')
-rw-r--r-- | fs/nfsd/filecache.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/fs/nfsd/filecache.c b/fs/nfsd/filecache.c index df54f882752c..ac38b41c89c6 100644 --- a/fs/nfsd/filecache.c +++ b/fs/nfsd/filecache.c @@ -303,7 +303,6 @@ nfsd_file_alloc(struct nfsd_file_lookup_key *key, unsigned int may) refcount_set(&nf->nf_ref, 2); nf->nf_may = key->need; nf->nf_mark = NULL; - trace_nfsd_file_alloc(nf); } return nf; } @@ -1126,6 +1125,7 @@ out_status: return status; open_file: + trace_nfsd_file_alloc(nf); nf->nf_mark = nfsd_file_mark_find_or_create(nf); if (nf->nf_mark) { if (open) { |