On 29 September 2017 at 06:18, Beilei Xing <beilei.x...@intel.com> wrote: > Add support of GTP-C and GTP-U tunnels in rte_net_get_ptype(). > > Signed-off-by: Beilei Xing <beilei.x...@intel.com> > Acked-by: Olivier Matz <olivier.m...@6wind.com> > --- > lib/librte_mbuf/rte_mbuf_ptype.c | 2 ++ > lib/librte_mbuf/rte_mbuf_ptype.h | 24 ++++++++++++++++++++++++ > 2 files changed, 26 insertions(+)
<snip> > /** > + * GTP-C (GPRS Tunnelling Protocol) control tunneling packet type. > + * Packet format: > + * <'ether type'=0x0800 > + * | 'version'=4, 'protocol'=17 > + * | 'destination port'=2123> > + * or, > + * <'ether type'=0x86DD > + * | 'version'=6, 'next header'=17 > + * | 'destination port'=2123> > + */ > +#define RTE_PTYPE_TUNNEL_GTPC 0x00007000 This isn't a good description of GTP-C. GTP-C messages have a source port of 2123, or a destination port of 2123. > +/** > + * GTP-U (GPRS Tunnelling Protocol) user data tunneling packet type. > + * Packet format: > + * <'ether type'=0x0800 > + * | 'version'=4, 'protocol'=17 > + * | 'destination port'=2152> > + * or, > + * <'ether type'=0x86DD > + * | 'version'=6, 'next header'=17 > + * | 'destination port'=2152> > + */ > +#define RTE_PTYPE_TUNNEL_GTPU 0x00008000 > +/** > * Mask of tunneling packet types. > */ > #define RTE_PTYPE_TUNNEL_MASK 0x0000f000 > -- > 2.5.5 >