Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux
1
fork

Configure Feed

Select the types of activity you want to include in your feed.

Merge tag '5.8-rc3-smb3-fixes' of git://git.samba.org/sfrench/cifs-2.6

Pull cifs fixes from Steve French:
"Eight cifs/smb3 fixes, most when specifying the multiuser mount flag.

Five of the fixes are for stable"

* tag '5.8-rc3-smb3-fixes' of git://git.samba.org/sfrench/cifs-2.6:
cifs: prevent truncation from long to int in wait_for_free_credits
cifs: Fix the target file was deleted when rename failed.
SMB3: Honor 'posix' flag for multiuser mounts
SMB3: Honor 'handletimeout' flag for multiuser mounts
SMB3: Honor lease disabling for multiuser mounts
SMB3: Honor persistent/resilient handle flags for multiuser mounts
SMB3: Honor 'seal' flag for multiuser mounts
cifs: Display local UID details for SMB sessions in DebugData

+20 -8
+5 -1
fs/cifs/cifs_debug.c
··· 399 399 if (ses->sign) 400 400 seq_puts(m, " signed"); 401 401 402 + seq_printf(m, "\n\tUser: %d Cred User: %d", 403 + from_kuid(&init_user_ns, ses->linux_uid), 404 + from_kuid(&init_user_ns, ses->cred_uid)); 405 + 402 406 if (ses->chan_count > 1) { 403 407 seq_printf(m, "\n\n\tExtra Channels: %zu\n", 404 408 ses->chan_count-1); ··· 410 406 cifs_dump_channel(m, j, &ses->chans[j]); 411 407 } 412 408 413 - seq_puts(m, "\n\tShares:"); 409 + seq_puts(m, "\n\n\tShares:"); 414 410 j = 0; 415 411 416 412 seq_printf(m, "\n\t%d) IPC: ", j);
+6 -4
fs/cifs/connect.c
··· 5306 5306 vol_info->nocase = master_tcon->nocase; 5307 5307 vol_info->nohandlecache = master_tcon->nohandlecache; 5308 5308 vol_info->local_lease = master_tcon->local_lease; 5309 + vol_info->no_lease = master_tcon->no_lease; 5310 + vol_info->resilient = master_tcon->use_resilient; 5311 + vol_info->persistent = master_tcon->use_persistent; 5312 + vol_info->handle_timeout = master_tcon->handle_timeout; 5309 5313 vol_info->no_linux_ext = !master_tcon->unix_ext; 5314 + vol_info->linux_ext = master_tcon->posix_extensions; 5310 5315 vol_info->sectype = master_tcon->ses->sectype; 5311 5316 vol_info->sign = master_tcon->ses->sign; 5317 + vol_info->seal = master_tcon->seal; 5312 5318 5313 5319 rc = cifs_set_vol_auth(vol_info, master_tcon->ses); 5314 5320 if (rc) { ··· 5339 5333 cifs_put_smb_ses(ses); 5340 5334 goto out; 5341 5335 } 5342 - 5343 - /* if new SMB3.11 POSIX extensions are supported do not remap / and \ */ 5344 - if (tcon->posix_extensions) 5345 - cifs_sb->mnt_cifs_flags |= CIFS_MOUNT_POSIX_PATHS; 5346 5336 5347 5337 if (cap_unix(ses)) 5348 5338 reset_cifs_unix_caps(0, tcon, NULL, vol_info);
+8 -2
fs/cifs/inode.c
··· 2044 2044 FILE_UNIX_BASIC_INFO *info_buf_target; 2045 2045 unsigned int xid; 2046 2046 int rc, tmprc; 2047 + bool new_target = d_really_is_negative(target_dentry); 2047 2048 2048 2049 if (flags & ~RENAME_NOREPLACE) 2049 2050 return -EINVAL; ··· 2121 2120 */ 2122 2121 2123 2122 unlink_target: 2124 - /* Try unlinking the target dentry if it's not negative */ 2125 - if (d_really_is_positive(target_dentry) && (rc == -EACCES || rc == -EEXIST)) { 2123 + /* 2124 + * If the target dentry was created during the rename, try 2125 + * unlinking it if it's not negative 2126 + */ 2127 + if (new_target && 2128 + d_really_is_positive(target_dentry) && 2129 + (rc == -EACCES || rc == -EEXIST)) { 2126 2130 if (d_is_dir(target_dentry)) 2127 2131 tmprc = cifs_rmdir(target_dir, target_dentry); 2128 2132 else
+1 -1
fs/cifs/transport.c
··· 523 523 const int timeout, const int flags, 524 524 unsigned int *instance) 525 525 { 526 - int rc; 526 + long rc; 527 527 int *credits; 528 528 int optype; 529 529 long int t;