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.19-rc1-smb3-client-fixes' of git://git.samba.org/sfrench/cifs-2.6

Pull cifs client fixes from Steve French:
"Three reconnect fixes, all for stable as well.

One of these three reconnect fixes does address a problem with
multichannel reconnect, but this does not include the additional
fix (still being tested) for dynamically detecting multichannel
adapter changes which will improve those reconnect scenarios even
more"

* tag '5.19-rc1-smb3-client-fixes' of git://git.samba.org/sfrench/cifs-2.6:
cifs: populate empty hostnames for extra channels
cifs: return errors during session setup during reconnects
cifs: fix reconnect on smb3 mount types

+29 -14
+1 -1
fs/cifs/cifsfs.c
··· 1086 1086 }; 1087 1087 MODULE_ALIAS_FS("cifs"); 1088 1088 1089 - static struct file_system_type smb3_fs_type = { 1089 + struct file_system_type smb3_fs_type = { 1090 1090 .owner = THIS_MODULE, 1091 1091 .name = "smb3", 1092 1092 .init_fs_context = smb3_init_fs_context,
+1 -1
fs/cifs/cifsfs.h
··· 38 38 return (unsigned long) dentry->d_fsdata; 39 39 } 40 40 41 - extern struct file_system_type cifs_fs_type; 41 + extern struct file_system_type cifs_fs_type, smb3_fs_type; 42 42 extern const struct address_space_operations cifs_addr_ops; 43 43 extern const struct address_space_operations cifs_addr_ops_smallbuf; 44 44
+4
fs/cifs/connect.c
··· 97 97 if (!server->hostname) 98 98 return -EINVAL; 99 99 100 + /* if server hostname isn't populated, there's nothing to do here */ 101 + if (server->hostname[0] == '\0') 102 + return 0; 103 + 100 104 len = strlen(server->hostname) + 3; 101 105 102 106 unc = kmalloc(len, GFP_KERNEL);
+16 -11
fs/cifs/misc.c
··· 1211 1211 .data = data, 1212 1212 .sb = NULL, 1213 1213 }; 1214 + struct file_system_type **fs_type = (struct file_system_type *[]) { 1215 + &cifs_fs_type, &smb3_fs_type, NULL, 1216 + }; 1214 1217 1215 - iterate_supers_type(&cifs_fs_type, f, &sd); 1216 - 1217 - if (!sd.sb) 1218 - return ERR_PTR(-EINVAL); 1219 - /* 1220 - * Grab an active reference in order to prevent automounts (DFS links) 1221 - * of expiring and then freeing up our cifs superblock pointer while 1222 - * we're doing failover. 1223 - */ 1224 - cifs_sb_active(sd.sb); 1225 - return sd.sb; 1218 + for (; *fs_type; fs_type++) { 1219 + iterate_supers_type(*fs_type, f, &sd); 1220 + if (sd.sb) { 1221 + /* 1222 + * Grab an active reference in order to prevent automounts (DFS links) 1223 + * of expiring and then freeing up our cifs superblock pointer while 1224 + * we're doing failover. 1225 + */ 1226 + cifs_sb_active(sd.sb); 1227 + return sd.sb; 1228 + } 1229 + } 1230 + return ERR_PTR(-EINVAL); 1226 1231 } 1227 1232 1228 1233 static void __cifs_put_super(struct super_block *sb)
+4 -1
fs/cifs/sess.c
··· 301 301 /* Auth */ 302 302 ctx.domainauto = ses->domainAuto; 303 303 ctx.domainname = ses->domainName; 304 - ctx.server_hostname = ses->server->hostname; 304 + 305 + /* no hostname for extra channels */ 306 + ctx.server_hostname = ""; 307 + 305 308 ctx.username = ses->user_name; 306 309 ctx.password = ses->password; 307 310 ctx.sectype = ses->sectype;
+3
fs/cifs/smb2pdu.c
··· 288 288 mutex_unlock(&ses->session_mutex); 289 289 rc = -EHOSTDOWN; 290 290 goto failed; 291 + } else if (rc) { 292 + mutex_unlock(&ses->session_mutex); 293 + goto out; 291 294 } 292 295 } else { 293 296 mutex_unlock(&ses->session_mutex);