octeontx2-af: fix detection of IP layer
[ Upstream commit 404dc0fd6fb0bb942b18008c6f8c0320b80aca20 ] Checksum and length checks are not enabled for IPv4 header with options and IPv6 with extension headers. To fix this a change in enum npc_kpu_lc_ltype is required which will allow adjustment of LTYPE_MASK to detect all types of IP headers. Fixes: 21e6699e5cd6 ("octeontx2-af: Add NPC KPU profile") Signed-off-by: Michal Mazur <mmazur2@marvell.com> Signed-off-by: David S. Miller <davem@davemloft.net> Signed-off-by: Sasha Levin <sashal@kernel.org>
This commit is contained in:
parent
833a64978a
commit
b7ea5bea1e
@ -38,14 +38,18 @@ enum npc_kpu_lb_ltype {
|
||||
NPC_LT_LB_ITAG,
|
||||
};
|
||||
|
||||
/* Don't modify ltypes up to IP6_EXT, otherwise length and checksum of IP
|
||||
* headers may not be checked correctly. IPv4 ltypes and IPv6 ltypes must
|
||||
* differ only at bit 0 so mask 0xE can be used to detect extended headers.
|
||||
*/
|
||||
enum npc_kpu_lc_ltype {
|
||||
NPC_LT_LC_IP = 1,
|
||||
NPC_LT_LC_PTP = 1,
|
||||
NPC_LT_LC_IP,
|
||||
NPC_LT_LC_IP6,
|
||||
NPC_LT_LC_ARP,
|
||||
NPC_LT_LC_RARP,
|
||||
NPC_LT_LC_MPLS,
|
||||
NPC_LT_LC_NSH,
|
||||
NPC_LT_LC_PTP,
|
||||
NPC_LT_LC_FCOE,
|
||||
};
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user