Skip to content

Commit b825b44

Browse files
Jay Freyenseesagigrimberg
authored andcommitted
nvmet-rdma: +1 to *queue_size from hsqsize/hrqsize
The host will be sending sqsize 0-based hsqsize value, the target need to be adjusted as well. Signed-off-by: Jay Freyensee <[email protected]> Reviewed-by: Sagi Grimberg <[email protected]> Signed-off-by: Sagi Grimberg <[email protected]>
1 parent 3256aae commit b825b44

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

drivers/nvme/target/rdma.c

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1004,10 +1004,10 @@ nvmet_rdma_parse_cm_connect_req(struct rdma_conn_param *conn,
10041004
queue->host_qid = le16_to_cpu(req->qid);
10051005

10061006
/*
1007-
* req->hsqsize corresponds to our recv queue size
1007+
* req->hsqsize corresponds to our recv queue size plus 1
10081008
* req->hrqsize corresponds to our send queue size
10091009
*/
1010-
queue->recv_queue_size = le16_to_cpu(req->hsqsize);
1010+
queue->recv_queue_size = le16_to_cpu(req->hsqsize) + 1;
10111011
queue->send_queue_size = le16_to_cpu(req->hrqsize);
10121012

10131013
if (!queue->host_qid && queue->recv_queue_size > NVMF_AQ_DEPTH)

0 commit comments

Comments
 (0)