All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH for-rc] RDMA/iw_cxgb4: Fix incorrect function parameters
@ 2020-05-10 18:41 Potnuri Bharat Teja
  2020-05-11 13:11 ` Jason Gunthorpe
  0 siblings, 1 reply; 3+ messages in thread
From: Potnuri Bharat Teja @ 2020-05-10 18:41 UTC (permalink / raw)
  To: jgg, dledford; +Cc: linux-rdma, bharat, nirranjan

Fixes the incorrect function parameters passed while reading TCB fields and
completing cached SRQ buffers.

Fixes: 11a27e2121a5 ("iw_cxgb4: complete the cached SRQ buffers")
Signed-off-by: Potnuri Bharat Teja <bharat@chelsio.com>
---
 drivers/infiniband/hw/cxgb4/cm.c | 7 +++----
 1 file changed, 3 insertions(+), 4 deletions(-)

diff --git a/drivers/infiniband/hw/cxgb4/cm.c b/drivers/infiniband/hw/cxgb4/cm.c
index d69dece3b1d5..30e08bcc9afb 100644
--- a/drivers/infiniband/hw/cxgb4/cm.c
+++ b/drivers/infiniband/hw/cxgb4/cm.c
@@ -2891,8 +2891,7 @@ static int peer_abort(struct c4iw_dev *dev, struct sk_buff *skb)
 			srqidx = ABORT_RSS_SRQIDX_G(
 					be32_to_cpu(req->srqidx_status));
 			if (srqidx) {
-				complete_cached_srq_buffers(ep,
-							    req->srqidx_status);
+				complete_cached_srq_buffers(ep, srqidx);
 			} else {
 				/* Hold ep ref until finish_peer_abort() */
 				c4iw_get_ep(&ep->com);
@@ -3878,8 +3877,8 @@ static int read_tcb_rpl(struct c4iw_dev *dev, struct sk_buff *skb)
 		return 0;
 	}
 
-	ep->srqe_idx = t4_tcb_get_field32(tcb, TCB_RQ_START_W, TCB_RQ_START_W,
-			TCB_RQ_START_S);
+	ep->srqe_idx = t4_tcb_get_field32(tcb, TCB_RQ_START_W, TCB_RQ_START_M,
+					  TCB_RQ_START_S);
 cleanup:
 	pr_debug("ep %p tid %u %016x\n", ep, ep->hwtid, ep->srqe_idx);
 
-- 
2.24.0


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

* Re: [PATCH for-rc] RDMA/iw_cxgb4: Fix incorrect function parameters
  2020-05-10 18:41 [PATCH for-rc] RDMA/iw_cxgb4: Fix incorrect function parameters Potnuri Bharat Teja
@ 2020-05-11 13:11 ` Jason Gunthorpe
  2020-05-11 18:54   ` Potnuri Bharat Teja
  0 siblings, 1 reply; 3+ messages in thread
From: Jason Gunthorpe @ 2020-05-11 13:11 UTC (permalink / raw)
  To: Potnuri Bharat Teja; +Cc: dledford, linux-rdma, nirranjan

On Mon, May 11, 2020 at 12:11:57AM +0530, Potnuri Bharat Teja wrote:
> Fixes the incorrect function parameters passed while reading TCB fields and
> completing cached SRQ buffers.

For a -rc fix you must explain what bad thing happens because of the
bug

Jason

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

* Re: [PATCH for-rc] RDMA/iw_cxgb4: Fix incorrect function parameters
  2020-05-11 13:11 ` Jason Gunthorpe
@ 2020-05-11 18:54   ` Potnuri Bharat Teja
  0 siblings, 0 replies; 3+ messages in thread
From: Potnuri Bharat Teja @ 2020-05-11 18:54 UTC (permalink / raw)
  To: Jason Gunthorpe; +Cc: dledford, linux-rdma, Nirranjan Kirubaharan

On Monday, May 05/11/20, 2020 at 18:41:35 +0530, Jason Gunthorpe wrote:
> On Mon, May 11, 2020 at 12:11:57AM +0530, Potnuri Bharat Teja wrote:
> > Fixes the incorrect function parameters passed while reading TCB fields and
> > completing cached SRQ buffers.
> 
> For a -rc fix you must explain what bad thing happens because of the
> bug
> 
My bad. This patch fixes app segfults during connection teardown when SRQ is 
used. Resending patch wit updated description.

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

end of thread, other threads:[~2020-05-11 18:54 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-05-10 18:41 [PATCH for-rc] RDMA/iw_cxgb4: Fix incorrect function parameters Potnuri Bharat Teja
2020-05-11 13:11 ` Jason Gunthorpe
2020-05-11 18:54   ` Potnuri Bharat Teja

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.