aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/fs/smb/client/smb2ops.c
diff options
context:
space:
mode:
authorSteve French <stfrench@microsoft.com>2024-07-23 18:12:40 -0500
committerSteve French <stfrench@microsoft.com>2024-07-26 12:34:19 -0500
commit5779d398dbcd74c30a641c209946b8498e668a53 (patch)
tree137867fce1d72f21011016b3b05f3a2de3a3e7a1 /fs/smb/client/smb2ops.c
parentcifs: mount with "unix" mount option for SMB1 incorrectly handled (diff)
downloadwireguard-linux-5779d398dbcd74c30a641c209946b8498e668a53.tar.xz
wireguard-linux-5779d398dbcd74c30a641c209946b8498e668a53.zip
smb3: add dynamic tracepoint for reflink errors
There are cases where debugging clone_range ("smb2_duplicate_extents" function) and in the future copy_range ("smb2_copychunk_range") can be helpful. Add dynamic trace points for any errors in clone, and a followon patch will add them for copychunk. "trace-cmd record -e smb3_clone_err" Reviewed-by: Shyam Prasad N <sprasad@microsoft.com> Signed-off-by: Steve French <stfrench@microsoft.com>
Diffstat (limited to 'fs/smb/client/smb2ops.c')
-rw-r--r--fs/smb/client/smb2ops.c5
1 files changed, 5 insertions, 0 deletions
diff --git a/fs/smb/client/smb2ops.c b/fs/smb/client/smb2ops.c
index 7fe59235f090..1539463285ee 100644
--- a/fs/smb/client/smb2ops.c
+++ b/fs/smb/client/smb2ops.c
@@ -2075,6 +2075,11 @@ smb2_duplicate_extents(const unsigned int xid,
cifs_dbg(FYI, "Non-zero response length in duplicate extents\n");
duplicate_extents_out:
+ if (rc)
+ trace_smb3_clone_err(xid, srcfile->fid.volatile_fid,
+ trgtfile->fid.volatile_fid,
+ tcon->tid, tcon->ses->Suid, src_off,
+ dest_off, len, rc);
return rc;
}