Browse Source

IB/rxe: Another fix for broken receive queue draining

This fixes another path in rxe_requester() that might overlook stale SKBs,
preventing cleanup.

Fixes: 1217197142d1 ("rxe: fix broken receive queue draining")
Signed-off-by: Andrew Boyer <andrew.boyer@dell.com>
Signed-off-by: Doug Ledford <dledford@redhat.com>
Andrew Boyer 8 years ago
parent
commit
1223a1af75
1 changed files with 3 additions and 1 deletions
  1. 3 1
      drivers/infiniband/sw/rxe/rxe_req.c

+ 3 - 1
drivers/infiniband/sw/rxe/rxe_req.c

@@ -594,8 +594,10 @@ int rxe_requester(void *arg)
 	rxe_add_ref(qp);
 	rxe_add_ref(qp);
 
 
 next_wqe:
 next_wqe:
-	if (unlikely(!qp->valid))
+	if (unlikely(!qp->valid)) {
+		rxe_drain_req_pkts(qp, true);
 		goto exit;
 		goto exit;
+	}
 
 
 	if (unlikely(qp->req.state == QP_STATE_ERROR)) {
 	if (unlikely(qp->req.state == QP_STATE_ERROR)) {
 		rxe_drain_req_pkts(qp, true);
 		rxe_drain_req_pkts(qp, true);