Patch "RDMA/rtrs-srv: Init wr_cnt as 1" 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: Init wr_cnt as 1

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-init-wr_cnt-as-1.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 48c205d360e444c1348c5424a73d3bd1322b6a09
Author: Jack Wang <jinpu.wang@xxxxxxxxxxxxxxx>
Date:   Thu Dec 17 15:19:14 2020 +0100

    RDMA/rtrs-srv: Init wr_cnt as 1
    
    [ Upstream commit 6f5d1b3016d650f351e65c645a5eee5394547dd0 ]
    
    Fix up wr_avail accounting. if wr_cnt is 0, then we do SIGNAL for first
    wr, in completion we add queue_depth back, which is not right in the
    sense of tracking for available wr.
    
    So fix it by init wr_cnt to 1.
    
    Fixes: 9cb837480424 ("RDMA/rtrs: server: main functionality")
    Link: https://lore.kernel.org/r/20201217141915.56989-19-jinpu.wang@xxxxxxxxxxxxxxx
    Signed-off-by: Jack Wang <jinpu.wang@xxxxxxxxxxxxxxx>
    Signed-off-by: Gioh Kim <gi-oh.kim@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 f59731c5a96a3..d017ede304b76 100644
--- a/drivers/infiniband/ulp/rtrs/rtrs-srv.c
+++ b/drivers/infiniband/ulp/rtrs/rtrs-srv.c
@@ -1604,7 +1604,7 @@ static int create_con(struct rtrs_srv_sess *sess,
 	con->c.cm_id = cm_id;
 	con->c.sess = &sess->s;
 	con->c.cid = cid;
-	atomic_set(&con->wr_cnt, 0);
+	atomic_set(&con->wr_cnt, 1);
 
 	if (con->c.cid == 0) {
 		/*



[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