All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH] cifs: double lock in cifs_reconnect_tcon()
@ 2023-04-06  8:55 Dan Carpenter
  2023-04-06 12:09 ` Paulo Alcantara
  0 siblings, 1 reply; 3+ messages in thread
From: Dan Carpenter @ 2023-04-06  8:55 UTC (permalink / raw)
  To: Paulo Alcantara
  Cc: Paulo Alcantara, Ronnie Sahlberg, Shyam Prasad N, Tom Talpey,
	linux-cifs, samba-technical, kernel-janitors

This lock was supposed to be an unlock.

Fixes: 6cc041e90c17 ("cifs: avoid races in parallel reconnects in smb1")
Signed-off-by: Dan Carpenter <error27@gmail.com>
---
 fs/cifs/cifssmb.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/fs/cifs/cifssmb.c b/fs/cifs/cifssmb.c
index 0d30b17494e4..9d963caec35c 100644
--- a/fs/cifs/cifssmb.c
+++ b/fs/cifs/cifssmb.c
@@ -120,7 +120,7 @@ cifs_reconnect_tcon(struct cifs_tcon *tcon, int smb_command)
 	spin_lock(&server->srv_lock);
 	if (server->tcpStatus == CifsNeedReconnect) {
 		spin_unlock(&server->srv_lock);
-		mutex_lock(&ses->session_mutex);
+		mutex_unlock(&ses->session_mutex);
 
 		if (tcon->retry)
 			goto again;
-- 
2.39.1


^ permalink raw reply related	[flat|nested] 3+ messages in thread

* Re: [PATCH] cifs: double lock in cifs_reconnect_tcon()
  2023-04-06  8:55 [PATCH] cifs: double lock in cifs_reconnect_tcon() Dan Carpenter
@ 2023-04-06 12:09 ` Paulo Alcantara
  2023-04-06 23:43   ` Steve French
  0 siblings, 1 reply; 3+ messages in thread
From: Paulo Alcantara @ 2023-04-06 12:09 UTC (permalink / raw)
  To: Dan Carpenter
  Cc: Ronnie Sahlberg, Shyam Prasad N, Tom Talpey, linux-cifs,
	samba-technical, kernel-janitors

Dan Carpenter <error27@gmail.com> writes:

> This lock was supposed to be an unlock.
>
> Fixes: 6cc041e90c17 ("cifs: avoid races in parallel reconnects in smb1")
> Signed-off-by: Dan Carpenter <error27@gmail.com>
> ---
>  fs/cifs/cifssmb.c | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)

Reviewed-by: Paulo Alcantara (SUSE) <pc@manguebit.com>

^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: [PATCH] cifs: double lock in cifs_reconnect_tcon()
  2023-04-06 12:09 ` Paulo Alcantara
@ 2023-04-06 23:43   ` Steve French
  0 siblings, 0 replies; 3+ messages in thread
From: Steve French @ 2023-04-06 23:43 UTC (permalink / raw)
  To: Paulo Alcantara
  Cc: Dan Carpenter, Ronnie Sahlberg, Shyam Prasad N, Tom Talpey,
	linux-cifs, samba-technical, kernel-janitors

Added to cifs-2.6.git for-next

On Thu, Apr 6, 2023 at 7:10 AM Paulo Alcantara <pc@manguebit.com> wrote:
>
> Dan Carpenter <error27@gmail.com> writes:
>
> > This lock was supposed to be an unlock.
> >
> > Fixes: 6cc041e90c17 ("cifs: avoid races in parallel reconnects in smb1")
> > Signed-off-by: Dan Carpenter <error27@gmail.com>
> > ---
> >  fs/cifs/cifssmb.c | 2 +-
> >  1 file changed, 1 insertion(+), 1 deletion(-)
>
> Reviewed-by: Paulo Alcantara (SUSE) <pc@manguebit.com>



-- 
Thanks,

Steve

^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2023-04-06 23:45 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2023-04-06  8:55 [PATCH] cifs: double lock in cifs_reconnect_tcon() Dan Carpenter
2023-04-06 12:09 ` Paulo Alcantara
2023-04-06 23:43   ` Steve French

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.