diff options
author | Steve French <stfrench@microsoft.com> | 2018-04-04 14:08:52 -0500 |
---|---|---|
committer | Steve French <stfrench@microsoft.com> | 2018-04-11 16:44:58 -0500 |
commit | c318e6c26cbe91bfcd1e9bca8840de2fb57aef4f (patch) | |
tree | 0ca36093d0afd26613630e4897f1bccf9a1b238a /fs/cifs/smb2pdu.c | |
parent | c0953f2ed510c31a375193e9dbca9774e77fb4b7 (diff) | |
download | lwn-c318e6c26cbe91bfcd1e9bca8840de2fb57aef4f.tar.gz lwn-c318e6c26cbe91bfcd1e9bca8840de2fb57aef4f.zip |
SMB3: Log at least once if tree connect fails during reconnect
Adding an extra debug message to show if a tree connect failure during
reconnect (and made it a log once so it doesn't spam the logs).
Saw a case recently where tree connect repeatedly returned
access denied on reconnect and it wasn't as easy to spot as it
should have been.
Signed-off-by: Steve French <smfrench@gmail.com>
Reviewed-by: Aurelien Aptel <aaptel@suse.com>
Diffstat (limited to 'fs/cifs/smb2pdu.c')
-rw-r--r-- | fs/cifs/smb2pdu.c | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/fs/cifs/smb2pdu.c b/fs/cifs/smb2pdu.c index e5ac474d5d87..6c2910e6c984 100644 --- a/fs/cifs/smb2pdu.c +++ b/fs/cifs/smb2pdu.c @@ -268,8 +268,11 @@ smb2_reconnect(__le16 smb2_command, struct cifs_tcon *tcon) mutex_unlock(&tcon->ses->session_mutex); cifs_dbg(FYI, "reconnect tcon rc = %d\n", rc); - if (rc) + if (rc) { + /* If sess reconnected but tcon didn't, something strange ... */ + printk_once(KERN_WARNING "reconnect tcon failed rc = %d\n", rc); goto out; + } if (smb2_command != SMB2_INTERNAL_CMD) queue_delayed_work(cifsiod_wq, &server->reconnect, 0); |