nfsd: ensure we always call fh_verify_error tracepoint
Subsystems (2)
[email protected]
maintainerPATCH 1/1 nfsd: ensure we always call fh_verify_error tracepoint
From: Jeff Layton <[email protected]>
This is a conditional tracepoint. Call it every time, not just when nfs_permission fails.
Signed-off-by Jeff Layton <[email protected]>
--- fs/nfsd/nfsfh.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
fs/nfsd/nfsfh.c +1 -1
@@ -392,8 +392,8 @@ fh_verify(struct svc_rqst *rqstp, struct svc_fh *fhp, umode_t type, int access) skip_pseudoflavor_check:/* Finally, check access permissions. */ error =nfsd_permission (rqstp, exp, dentry, access); -trace_nfsd_fh_verify_err (rqstp, fhp, type, access, error); out: +trace_nfsd_fh_verify_err (rqstp, fhp, type, access, error);if (error == nfserr_stale)nfsd_stats_fh_stale_inc (exp);return error;
Signature · 1 line
2.37.3
Chuck Lever III
AppliedQuoted 10 lines · On Oct 12, 2022, at 2:42 PM, [email protected] wrote:
From: Jeff Layton <[email protected]>
This is a conditional tracepoint. Call it every time, not just when
nfs_permissionfails.Signed-off-by Jeff Layton <[email protected]>
I've applied this to nfsd's for-rc. Thanks!
Quoted 15 lines
---
fs/nfsd/nfsfh.c| 2 +-1 file changed, 1 insertion(+), 1 deletion(-)fs/nfsd/nfsfh.c +0
-0@@ -392,8 +392,8 @@ fh_verify(struct svc_rqst *rqstp, struct svc_fh *fhp, umode_t type, int access)
skip_pseudoflavor_check:/* Finally, check access permissions. */ error = nfsd_permission(rqstp, exp, dentry, access);fs/nfsd/nfsfh.c +0
-1-trace_nfsd_fh_verify_err (rqstp, fhp, type, access, error);out:
fs/nfsd/nfsfh.c +1
-0+trace_nfsd_fh_verify_err (rqstp, fhp, type, access, error);
Quoted 6 lines
if (error == nfserr_stale) nfsd_stats_fh_stale_inc(exp); return error;Signature · 1 line
2.37.3
--
Chuck Lever