Browse Source

IB/rxe: Fix ref leak in duplicate_request()

A ref was added after the call to skb_clone().

Signed-off-by: Andrew Boyer <andrew.boyer@dell.com>
Signed-off-by: Doug Ledford <dledford@redhat.com>
Andrew Boyer 8 years ago
parent
commit
5407f53012
1 changed files with 1 additions and 0 deletions
  1. 1 0
      drivers/infiniband/sw/rxe/rxe_resp.c

+ 1 - 0
drivers/infiniband/sw/rxe/rxe_resp.c

@@ -1145,6 +1145,7 @@ static enum resp_states duplicate_request(struct rxe_qp *qp,
 					     pkt, skb_copy);
 					     pkt, skb_copy);
 			if (rc) {
 			if (rc) {
 				pr_err("Failed resending result. This flow is not handled - skb ignored\n");
 				pr_err("Failed resending result. This flow is not handled - skb ignored\n");
+				rxe_drop_ref(qp);
 				kfree_skb(skb_copy);
 				kfree_skb(skb_copy);
 				rc = RESPST_CLEANUP;
 				rc = RESPST_CLEANUP;
 				goto out;
 				goto out;