IB/rxe: Fix missing completion for mem_reg work requests
authorVijay Immanuel <vijayi@attalasystems.com>
Wed, 13 Jun 2018 01:16:05 +0000 (18:16 -0700)
committerJason Gunthorpe <jgg@mellanox.com>
Mon, 18 Jun 2018 17:36:13 +0000 (11:36 -0600)
Run the completer task to post a work completion after processing
a memory registration or invalidate work request. This covers the
case where the memory registration or invalidate was the last work
request posted to the qp.

Signed-off-by: Vijay Immanuel <vijayi@attalasystems.com>
Reviewed-by: Yonatan Cohen <yonatanc@mellanox.com>
Signed-off-by: Jason Gunthorpe <jgg@mellanox.com>
drivers/infiniband/sw/rxe/rxe_req.c

index 829ecb93661f6e3540e20f4be5adcdb6971fb43b..8be27238a86e4ee1f160b4058e9517ef58708d26 100644 (file)
@@ -645,6 +645,9 @@ next_wqe:
                } else {
                        goto exit;
                }
+               if ((wqe->wr.send_flags & IB_SEND_SIGNALED) ||
+                   qp->sq_sig_type == IB_SIGNAL_ALL_WR)
+                       rxe_run_task(&qp->comp.task, 1);
                qp->req.wqe_index = next_index(qp->sq.queue,
                                                qp->req.wqe_index);
                goto next_wqe;