Patch "RDMA/rtrs-srv: Release lock before call into close_sess" has been added to the 5.11-stable tree

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



This is a note to let you know that I've just added the patch titled

    RDMA/rtrs-srv: Release lock before call into close_sess

to the 5.11-stable tree which can be found at:
    http://www.kernel.org/git/?p=linux/kernel/git/stable/stable-queue.git;a=summary

The filename of the patch is:
     rdma-rtrs-srv-release-lock-before-call-into-close_se.patch
and it can be found in the queue-5.11 subdirectory.

If you, or anyone else, feels it should not be added to the stable tree,
please let <stable@xxxxxxxxxxxxxxx> know about it.



commit 0136112582b485b997aa1a90f9cef28a4c7e2c43
Author: Jack Wang <jinpu.wang@xxxxxxxxxxxxxxx>
Date:   Thu Dec 17 15:18:59 2020 +0100

    RDMA/rtrs-srv: Release lock before call into close_sess
    
    [ Upstream commit 99f0c3807973359bba8f37d9198eea59fe38c32a ]
    
    In this error case, we don't need hold mutex to call close_sess.
    
    Fixes: 9cb837480424 ("RDMA/rtrs: server: main functionality")
    Link: https://lore.kernel.org/r/20201217141915.56989-4-jinpu.wang@xxxxxxxxxxxxxxx
    Signed-off-by: Jack Wang <jinpu.wang@xxxxxxxxxxxxxxx>
    Tested-by: Lutz Pogrell <lutz.pogrell@xxxxxxxxxxxxxxx>
    Signed-off-by: Jason Gunthorpe <jgg@xxxxxxxxxx>
    Signed-off-by: Sasha Levin <sashal@xxxxxxxxxx>

diff --git a/drivers/infiniband/ulp/rtrs/rtrs-srv.c b/drivers/infiniband/ulp/rtrs/rtrs-srv.c
index ed4628f032bb6..341661f42add0 100644
--- a/drivers/infiniband/ulp/rtrs/rtrs-srv.c
+++ b/drivers/infiniband/ulp/rtrs/rtrs-srv.c
@@ -1863,8 +1863,8 @@ static int rtrs_rdma_connect(struct rdma_cm_id *cm_id,
 	return rtrs_rdma_do_reject(cm_id, -ECONNRESET);
 
 close_and_return_err:
-	close_sess(sess);
 	mutex_unlock(&srv->paths_mutex);
+	close_sess(sess);
 
 	return err;
 }



[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Index of Archives]     [Linux USB Devel]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]

  Powered by Linux