kernel: mtk_eth_soc: fix encapsulation check for GSO fraglist packets
Use skb->encapsulation flag instead of skb_tnl_header_len() to detect encapsulated packets. Prevents false positives on non-encapsulated packets. Reported-by: Mason-cw Chang (張哲維) <Mason-cw.Chang@mediatek.com> Signed-off-by: Felix Fietkau <nbd@nbd.name>
This commit is contained in:
parent
92445cc982
commit
05feabfd09
@ -427,7 +427,7 @@ Signed-off-by: Felix Fietkau <nbd@nbd.name>
|
||||
+ if (!(skb_shinfo(skb)->gso_type & SKB_GSO_FRAGLIST))
|
||||
+ return true;
|
||||
+
|
||||
+ if (skb_tnl_header_len(skb))
|
||||
+ if (skb->encapsulation)
|
||||
+ return false;
|
||||
+
|
||||
+ return skb_pagelen(skb) - header_len == skb_shinfo(skb)->gso_size &&
|
||||
|
||||
Loading…
Reference in New Issue
Block a user