diff mbox series

cifs: fix stray unlock in cifs_chan_skip_or_disable

Message ID 20240123050757.5373-1-sprasad@microsoft.com (mailing list archive)
State New, archived
Headers show
Series cifs: fix stray unlock in cifs_chan_skip_or_disable | expand

Commit Message

Shyam Prasad N Jan. 23, 2024, 5:07 a.m. UTC
From: Shyam Prasad N <sprasad@microsoft.com>

A recent change moved the code that decides to skip
a channel or disable multichannel entirely, into a
helper function.

During this, a mutex_unlock of the session_mutex
should have been removed. Doing that here.

Fixes: f591062bdbf4 ("cifs: handle servers that still advertise multichannel after disabling")
Signed-off-by: Shyam Prasad N <sprasad@microsoft.com>
---
 fs/smb/client/smb2pdu.c | 1 -
 1 file changed, 1 deletion(-)

Comments

Steve French Jan. 23, 2024, 5:46 a.m. UTC | #1
tentatively merged into cifs-2.6.git for-next pending more review and
testing (and temporarily backed out the larger cifs netfs integration
patches series)

On Mon, Jan 22, 2024 at 11:08 PM <nspmangalore@gmail.com> wrote:
>
> From: Shyam Prasad N <sprasad@microsoft.com>
>
> A recent change moved the code that decides to skip
> a channel or disable multichannel entirely, into a
> helper function.
>
> During this, a mutex_unlock of the session_mutex
> should have been removed. Doing that here.
>
> Fixes: f591062bdbf4 ("cifs: handle servers that still advertise multichannel after disabling")
> Signed-off-by: Shyam Prasad N <sprasad@microsoft.com>
> ---
>  fs/smb/client/smb2pdu.c | 1 -
>  1 file changed, 1 deletion(-)
>
> diff --git a/fs/smb/client/smb2pdu.c b/fs/smb/client/smb2pdu.c
> index 4f2cc8373b67..86f6f35b7f32 100644
> --- a/fs/smb/client/smb2pdu.c
> +++ b/fs/smb/client/smb2pdu.c
> @@ -195,7 +195,6 @@ cifs_chan_skip_or_disable(struct cifs_ses *ses,
>                 pserver = server->primary_server;
>                 cifs_signal_cifsd_for_reconnect(pserver, false);
>  skip_terminate:
> -               mutex_unlock(&ses->session_mutex);
>                 return -EHOSTDOWN;
>         }
>
> --
> 2.34.1
>
diff mbox series

Patch

diff --git a/fs/smb/client/smb2pdu.c b/fs/smb/client/smb2pdu.c
index 4f2cc8373b67..86f6f35b7f32 100644
--- a/fs/smb/client/smb2pdu.c
+++ b/fs/smb/client/smb2pdu.c
@@ -195,7 +195,6 @@  cifs_chan_skip_or_disable(struct cifs_ses *ses,
 		pserver = server->primary_server;
 		cifs_signal_cifsd_for_reconnect(pserver, false);
 skip_terminate:
-		mutex_unlock(&ses->session_mutex);
 		return -EHOSTDOWN;
 	}