6#ifndef _RTE_MBUF_PTYPE_H_
7#define _RTE_MBUF_PTYPE_H_
75#define RTE_PTYPE_UNKNOWN 0x00000000
83#define RTE_PTYPE_L2_ETHER 0x00000001
90#define RTE_PTYPE_L2_ETHER_TIMESYNC 0x00000002
97#define RTE_PTYPE_L2_ETHER_ARP 0x00000003
104#define RTE_PTYPE_L2_ETHER_LLDP 0x00000004
111#define RTE_PTYPE_L2_ETHER_NSH 0x00000005
118#define RTE_PTYPE_L2_ETHER_VLAN 0x00000006
125#define RTE_PTYPE_L2_ETHER_QINQ 0x00000007
132#define RTE_PTYPE_L2_ETHER_PPPOE 0x00000008
139#define RTE_PTYPE_L2_ETHER_FCOE 0x00000009
146#define RTE_PTYPE_L2_ETHER_MPLS 0x0000000a
151#define RTE_PTYPE_L2_MASK 0x0000000f
161#define RTE_PTYPE_L3_IPV4 0x00000010
171#define RTE_PTYPE_L3_IPV4_EXT 0x00000030
181#define RTE_PTYPE_L3_IPV6 0x00000040
191#define RTE_PTYPE_L3_IPV4_EXT_UNKNOWN 0x00000090
202#define RTE_PTYPE_L3_IPV6_EXT 0x000000c0
213#define RTE_PTYPE_L3_IPV6_EXT_UNKNOWN 0x000000e0
218#define RTE_PTYPE_L3_MASK 0x000000f0
230#define RTE_PTYPE_L4_TCP 0x00000100
242#define RTE_PTYPE_L4_UDP 0x00000200
262#define RTE_PTYPE_L4_FRAG 0x00000300
274#define RTE_PTYPE_L4_SCTP 0x00000400
286#define RTE_PTYPE_L4_ICMP 0x00000500
303#define RTE_PTYPE_L4_NONFRAG 0x00000600
311#define RTE_PTYPE_L4_IGMP 0x00000700
322#define RTE_PTYPE_L4_ESP 0x00000800
327#define RTE_PTYPE_L4_MASK 0x00000f00
338#define RTE_PTYPE_TUNNEL_IP 0x00001000
349#define RTE_PTYPE_TUNNEL_GRE 0x00002000
362#define RTE_PTYPE_TUNNEL_VXLAN 0x00003000
376#define RTE_PTYPE_TUNNEL_NVGRE 0x00004000
389#define RTE_PTYPE_TUNNEL_GENEVE 0x00005000
396#define RTE_PTYPE_TUNNEL_GRENAT 0x00006000
416#define RTE_PTYPE_TUNNEL_GTPC 0x00007000
428#define RTE_PTYPE_TUNNEL_GTPU 0x00008000
439#define RTE_PTYPE_TUNNEL_ESP 0x00009000
458#define RTE_PTYPE_TUNNEL_L2TP 0x0000a000
471#define RTE_PTYPE_TUNNEL_VXLAN_GPE 0x0000b000
492#define RTE_PTYPE_TUNNEL_MPLS_IN_GRE 0x0000c000
505#define RTE_PTYPE_TUNNEL_MPLS_IN_UDP 0x0000d000
509#define RTE_PTYPE_TUNNEL_MASK 0x0000f000
517#define RTE_PTYPE_INNER_L2_ETHER 0x00010000
524#define RTE_PTYPE_INNER_L2_ETHER_VLAN 0x00020000
531#define RTE_PTYPE_INNER_L2_ETHER_QINQ 0x00030000
535#define RTE_PTYPE_INNER_L2_MASK 0x000f0000
544#define RTE_PTYPE_INNER_L3_IPV4 0x00100000
553#define RTE_PTYPE_INNER_L3_IPV4_EXT 0x00200000
562#define RTE_PTYPE_INNER_L3_IPV6 0x00300000
571#define RTE_PTYPE_INNER_L3_IPV4_EXT_UNKNOWN 0x00400000
581#define RTE_PTYPE_INNER_L3_IPV6_EXT 0x00500000
592#define RTE_PTYPE_INNER_L3_IPV6_EXT_UNKNOWN 0x00600000
596#define RTE_PTYPE_INNER_L3_MASK 0x00f00000
608#define RTE_PTYPE_INNER_L4_TCP 0x01000000
620#define RTE_PTYPE_INNER_L4_UDP 0x02000000
635#define RTE_PTYPE_INNER_L4_FRAG 0x03000000
647#define RTE_PTYPE_INNER_L4_SCTP 0x04000000
659#define RTE_PTYPE_INNER_L4_ICMP 0x05000000
672#define RTE_PTYPE_INNER_L4_NONFRAG 0x06000000
684#define RTE_PTYPE_INNER_L4_ESP 0x08000000
688#define RTE_PTYPE_INNER_L4_MASK 0x0f000000
692#define RTE_PTYPE_ALL_MASK 0x0fffffff
699#define RTE_ETH_IS_IPV4_HDR(ptype) ((ptype) & RTE_PTYPE_L3_IPV4)
706#define RTE_ETH_IS_IPV6_HDR(ptype) ((ptype) & RTE_PTYPE_L3_IPV6)
709#define RTE_ETH_IS_TUNNEL_PKT(ptype) ((ptype) & \
710 (RTE_PTYPE_TUNNEL_MASK | \
711 RTE_PTYPE_INNER_L2_MASK | \
712 RTE_PTYPE_INNER_L3_MASK | \
713 RTE_PTYPE_INNER_L4_MASK))
const char * rte_get_ptype_tunnel_name(uint32_t ptype)
const char * rte_get_ptype_inner_l3_name(uint32_t ptype)
int rte_get_ptype_name(uint32_t ptype, char *buf, size_t buflen)
const char * rte_get_ptype_l3_name(uint32_t ptype)
const char * rte_get_ptype_inner_l2_name(uint32_t ptype)
const char * rte_get_ptype_l4_name(uint32_t ptype)
const char * rte_get_ptype_inner_l4_name(uint32_t ptype)
const char * rte_get_ptype_l2_name(uint32_t ptype)