diff options
author | Shyam Prasad N <sprasad@microsoft.com> | 2021-07-19 14:01:32 +0000 |
---|---|---|
committer | Steve French <stfrench@microsoft.com> | 2022-01-02 20:38:46 -0600 |
commit | 66eb0c6e66617cace0d626d48819bf2b5fbf9307 (patch) | |
tree | c5670e0f181f641b1f6ef8ac7a5e0b8d76475db0 | |
parent | f486ef8e2003f6c308d0db81ea116c880a760d4f (diff) | |
download | linux-stable-66eb0c6e66617cace0d626d48819bf2b5fbf9307.tar.gz linux-stable-66eb0c6e66617cace0d626d48819bf2b5fbf9307.tar.bz2 linux-stable-66eb0c6e66617cace0d626d48819bf2b5fbf9307.zip |
cifs: adjust DebugData to use chans_need_reconnect for conn status
Use ses->chans_need_reconnect bitmask to print the connection
status of each channel under an SMB session.
Signed-off-by: Shyam Prasad N <sprasad@microsoft.com>
Signed-off-by: Steve French <stfrench@microsoft.com>
-rw-r--r-- | fs/cifs/cifs_debug.c | 8 |
1 files changed, 7 insertions, 1 deletions
diff --git a/fs/cifs/cifs_debug.c b/fs/cifs/cifs_debug.c index d282caf9f037..ea00e1a91250 100644 --- a/fs/cifs/cifs_debug.c +++ b/fs/cifs/cifs_debug.c @@ -416,11 +416,17 @@ skip_rdma: from_kuid(&init_user_ns, ses->cred_uid)); spin_lock(&ses->chan_lock); + if (CIFS_CHAN_NEEDS_RECONNECT(ses, 0)) + seq_puts(m, "\tPrimary channel: DISCONNECTED "); + if (ses->chan_count > 1) { seq_printf(m, "\n\n\tExtra Channels: %zu ", ses->chan_count-1); - for (j = 1; j < ses->chan_count; j++) + for (j = 1; j < ses->chan_count; j++) { cifs_dump_channel(m, j, &ses->chans[j]); + if (CIFS_CHAN_NEEDS_RECONNECT(ses, j)) + seq_puts(m, "\tDISCONNECTED "); + } } spin_unlock(&ses->chan_lock); |