linux-rdma.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH for-next] RDMA/cxgb4: Set queue pair state when being queried
@ 2021-12-20 15:25 Kamal Heib
  2022-01-03  8:58 ` Leon Romanovsky
  2022-01-05 20:00 ` Jason Gunthorpe
  0 siblings, 2 replies; 3+ messages in thread
From: Kamal Heib @ 2021-12-20 15:25 UTC (permalink / raw)
  To: linux-rdma; +Cc: Potnuri Bharat Teja, Jason Gunthorpe, Kamal Heib

The API for ib_query_qp requires the driver to set
cur_qp_state on return, add the missing set.

Fixes: 67bbc05512d8 ("RDMA/cxgb4: Add query_qp support")
Signed-off-by: Kamal Heib <kamalheib1@gmail.com>
---
 drivers/infiniband/hw/cxgb4/qp.c | 1 +
 1 file changed, 1 insertion(+)

diff --git a/drivers/infiniband/hw/cxgb4/qp.c b/drivers/infiniband/hw/cxgb4/qp.c
index d20b4ef2c853..ffbd9a89981e 100644
--- a/drivers/infiniband/hw/cxgb4/qp.c
+++ b/drivers/infiniband/hw/cxgb4/qp.c
@@ -2460,6 +2460,7 @@ int c4iw_ib_query_qp(struct ib_qp *ibqp, struct ib_qp_attr *attr,
 	memset(attr, 0, sizeof(*attr));
 	memset(init_attr, 0, sizeof(*init_attr));
 	attr->qp_state = to_ib_qp_state(qhp->attr.state);
+	attr->cur_qp_state = to_ib_qp_state(qhp->attr.state);
 	init_attr->cap.max_send_wr = qhp->attr.sq_num_entries;
 	init_attr->cap.max_recv_wr = qhp->attr.rq_num_entries;
 	init_attr->cap.max_send_sge = qhp->attr.sq_max_sges;
-- 
2.31.1


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

* Re: [PATCH for-next] RDMA/cxgb4: Set queue pair state when being queried
  2021-12-20 15:25 [PATCH for-next] RDMA/cxgb4: Set queue pair state when being queried Kamal Heib
@ 2022-01-03  8:58 ` Leon Romanovsky
  2022-01-05 20:00 ` Jason Gunthorpe
  1 sibling, 0 replies; 3+ messages in thread
From: Leon Romanovsky @ 2022-01-03  8:58 UTC (permalink / raw)
  To: Kamal Heib; +Cc: linux-rdma, Potnuri Bharat Teja, Jason Gunthorpe

On Mon, Dec 20, 2021 at 05:25:30PM +0200, Kamal Heib wrote:
> The API for ib_query_qp requires the driver to set
> cur_qp_state on return, add the missing set.
> 
> Fixes: 67bbc05512d8 ("RDMA/cxgb4: Add query_qp support")
> Signed-off-by: Kamal Heib <kamalheib1@gmail.com>
> ---
>  drivers/infiniband/hw/cxgb4/qp.c | 1 +
>  1 file changed, 1 insertion(+)

I wonder if this is last error of such type.
The bnxt_re had same error 53839b51a767 ("RDMA/bnxt_re: Set queue pair state when being queried")

Thanks,
Reviewed-by: Leon Romanovsky <leonro@nvidia.com>

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

* Re: [PATCH for-next] RDMA/cxgb4: Set queue pair state when being queried
  2021-12-20 15:25 [PATCH for-next] RDMA/cxgb4: Set queue pair state when being queried Kamal Heib
  2022-01-03  8:58 ` Leon Romanovsky
@ 2022-01-05 20:00 ` Jason Gunthorpe
  1 sibling, 0 replies; 3+ messages in thread
From: Jason Gunthorpe @ 2022-01-05 20:00 UTC (permalink / raw)
  To: Kamal Heib; +Cc: linux-rdma, Potnuri Bharat Teja

On Mon, Dec 20, 2021 at 05:25:30PM +0200, Kamal Heib wrote:
> The API for ib_query_qp requires the driver to set
> cur_qp_state on return, add the missing set.
> 
> Fixes: 67bbc05512d8 ("RDMA/cxgb4: Add query_qp support")
> Signed-off-by: Kamal Heib <kamalheib1@gmail.com>
> Reviewed-by: Leon Romanovsky <leonro@nvidia.com>
> ---
>  drivers/infiniband/hw/cxgb4/qp.c | 1 +
>  1 file changed, 1 insertion(+)

Applied to for-next, thanks

Jason

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

end of thread, other threads:[~2022-01-05 20:00 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-12-20 15:25 [PATCH for-next] RDMA/cxgb4: Set queue pair state when being queried Kamal Heib
2022-01-03  8:58 ` Leon Romanovsky
2022-01-05 20:00 ` Jason Gunthorpe

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).