mbuf: extend meaning of QinQ stripped bit
authorSomnath Kotur <somnath.kotur@broadcom.com>
Mon, 6 Jan 2020 08:34:23 +0000 (14:04 +0530)
committerOlivier Matz <olivier.matz@6wind.com>
Mon, 3 Aug 2020 11:18:10 +0000 (13:18 +0200)
commit7194e9ee66d6f229862e9293fed358061fb93daf
tree1c1c6d5a05b617efa9e542052aea11e7f10e4e69
parentd659460a17afa28d4c7a37d492df47ab3ac542c7
mbuf: extend meaning of QinQ stripped bit

Certain hardware may be able to strip and/or save only the outermost
VLAN instead of both the VLANs in the mbuf in a QinQ scenario.
To handle such cases, we could re-interpret setting of just
PKT_RX_QINQ_STRIPPED to indicate that only the outermost VLAN has
been stripped and saved in mbuf->vlan_tci_outer.
Only When both PKT_RX_QINQ_STRIPPED and PKT_RX_VLAN_STRIPPED are set, the 2
VLANs have been stripped by the hardware and their TCI are saved in
mbuf->vlan_tci (inner) and mbuf->vlan_tci_outer (outer).

Signed-off-by: Somnath Kotur <somnath.kotur@broadcom.com>
lib/librte_mbuf/rte_mbuf_core.h