Skip to content

Commit a446e96

Browse files
committed
Merge tag '6.13-rc2-smb3-client-fixes' of git://git.samba.org/sfrench/cifs-2.6
Pull smb client fixes from Steve French: - fix rmmod leak - two minor cleanups - fix for unlink/rename with pending i/o * tag '6.13-rc2-smb3-client-fixes' of git://git.samba.org/sfrench/cifs-2.6: smb: client: destroy cfid_put_wq on module exit cifs: Use str_yes_no() helper in cifs_ses_add_channel() cifs: Fix rmdir failure due to ongoing I/O on deleted file smb3: fix compiler warning in reparse code
2 parents f861356 + 633609c commit a446e96

File tree

4 files changed

+8
-4
lines changed

4 files changed

+8
-4
lines changed

fs/smb/client/cifsfs.c

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2043,6 +2043,7 @@ exit_cifs(void)
20432043
destroy_workqueue(decrypt_wq);
20442044
destroy_workqueue(fileinfo_put_wq);
20452045
destroy_workqueue(serverclose_wq);
2046+
destroy_workqueue(cfid_put_wq);
20462047
destroy_workqueue(cifsiod_wq);
20472048
cifs_proc_clean();
20482049
}

fs/smb/client/inode.c

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1947,6 +1947,7 @@ int cifs_unlink(struct inode *dir, struct dentry *dentry)
19471947
goto unlink_out;
19481948
}
19491949

1950+
netfs_wait_for_outstanding_io(inode);
19501951
cifs_close_deferred_file_under_dentry(tcon, full_path);
19511952
#ifdef CONFIG_CIFS_ALLOW_INSECURE_LEGACY
19521953
if (cap_unix(tcon->ses) && (CIFS_UNIX_POSIX_PATH_OPS_CAP &
@@ -2464,8 +2465,10 @@ cifs_rename2(struct mnt_idmap *idmap, struct inode *source_dir,
24642465
}
24652466

24662467
cifs_close_deferred_file_under_dentry(tcon, from_name);
2467-
if (d_inode(target_dentry) != NULL)
2468+
if (d_inode(target_dentry) != NULL) {
2469+
netfs_wait_for_outstanding_io(d_inode(target_dentry));
24682470
cifs_close_deferred_file_under_dentry(tcon, to_name);
2471+
}
24692472

24702473
rc = cifs_do_rename(xid, source_dentry, from_name, target_dentry,
24712474
to_name);

fs/smb/client/reparse.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -676,7 +676,7 @@ static int parse_reparse_wsl_symlink(struct reparse_wsl_symlink_data_buffer *buf
676676
return -ENOMEM;
677677
symname_utf16_len = utf8s_to_utf16s(buf->PathBuffer, symname_utf8_len,
678678
UTF16_LITTLE_ENDIAN,
679-
symname_utf16, symname_utf8_len * 2);
679+
(wchar_t *) symname_utf16, symname_utf8_len * 2);
680680
if (symname_utf16_len < 0) {
681681
kfree(symname_utf16);
682682
return symname_utf16_len;

fs/smb/client/sess.c

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -488,11 +488,11 @@ cifs_ses_add_channel(struct cifs_ses *ses,
488488

489489
if (iface->sockaddr.ss_family == AF_INET)
490490
cifs_dbg(FYI, "adding channel to ses %p (speed:%zu bps rdma:%s ip:%pI4)\n",
491-
ses, iface->speed, iface->rdma_capable ? "yes" : "no",
491+
ses, iface->speed, str_yes_no(iface->rdma_capable),
492492
&ipv4->sin_addr);
493493
else
494494
cifs_dbg(FYI, "adding channel to ses %p (speed:%zu bps rdma:%s ip:%pI6)\n",
495-
ses, iface->speed, iface->rdma_capable ? "yes" : "no",
495+
ses, iface->speed, str_yes_no(iface->rdma_capable),
496496
&ipv6->sin6_addr);
497497

498498
/*

0 commit comments

Comments
 (0)