Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit b38a0ad8 authored by Steve Wise's avatar Steve Wise Committed by Roland Dreier
Browse files

RDMA/cxgb4: Set arp error handler for PASS_ACCEPT_RPL messages



accept_cr() failed to set the arp error handler on a reused skb.  This
results in a kernel crash if the arp does indeed time out.

Signed-off-by: default avatarSteve Wise <swise@opengridcomputing.com>
Signed-off-by: default avatarVipul Pandya <vipul@chelsio.com>
Signed-off-by: default avatarRoland Dreier <roland@purestorage.com>
parent 27ca34f5
Loading
Loading
Loading
Loading
+2 −0
Original line number Original line Diff line number Diff line
@@ -332,6 +332,7 @@ static struct sk_buff *get_skb(struct sk_buff *skb, int len, gfp_t gfp)
	} else {
	} else {
		skb = alloc_skb(len, gfp);
		skb = alloc_skb(len, gfp);
	}
	}
	t4_set_arp_err_handler(skb, NULL, NULL);
	return skb;
	return skb;
}
}


@@ -2025,6 +2026,7 @@ static void accept_cr(struct c4iw_ep *ep, struct sk_buff *skb,
	rpl->opt0 = cpu_to_be64(opt0);
	rpl->opt0 = cpu_to_be64(opt0);
	rpl->opt2 = cpu_to_be32(opt2);
	rpl->opt2 = cpu_to_be32(opt2);
	set_wr_txq(skb, CPL_PRIORITY_SETUP, ep->ctrlq_idx);
	set_wr_txq(skb, CPL_PRIORITY_SETUP, ep->ctrlq_idx);
	t4_set_arp_err_handler(skb, NULL, arp_failure_discard);
	c4iw_l2t_send(&ep->com.dev->rdev, skb, ep->l2t);
	c4iw_l2t_send(&ep->com.dev->rdev, skb, ep->l2t);


	return;
	return;