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

Commit d40496a5 authored by WANG Cong's avatar WANG Cong Committed by David S. Miller
Browse files

act_mirred: clear sender cpu before sending to tx



Similar to commit c29390c6 ("xps: must clear sender_cpu before forwarding")
the skb->sender_cpu needs to be cleared when moving from Rx
Tx, otherwise kernel could crash.

Fixes: 2bd82484 ("xps: fix xps for stacked devices")
Cc: Eric Dumazet <edumazet@google.com>
Cc: Jamal Hadi Salim <jhs@mojatatu.com>
Signed-off-by: default avatarCong Wang <cwang@twopensource.com>
Signed-off-by: default avatarCong Wang <xiyou.wangcong@gmail.com>
Acked-by: default avatarEric Dumazet <edumazet@google.com>
Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
parent c72eda06
Loading
Loading
Loading
Loading
+1 −0
Original line number Diff line number Diff line
@@ -179,6 +179,7 @@ static int tcf_mirred(struct sk_buff *skb, const struct tc_action *a,

	skb2->skb_iif = skb->dev->ifindex;
	skb2->dev = dev;
	skb_sender_cpu_clear(skb2);
	err = dev_queue_xmit(skb2);

	if (err) {