rte_flow_item_eth(3)
π rte_flow_item_eth π
okay bestie, gather round, because we're about to talk about rte_flow_item_eth from the DPDK library β yes it's a manpage, yes it's about Ethernet headers, and yes it's giving main character energy. You can find this one in section 3 of the manual (library functions, iykyk).
π¦ SYNOPSIS π¦
#include <rte_flow.h>
β¨ Data Fields β¨
uint32_t has_vlan:1uint32_t reserved:31
πΈ Detailed Description πΈ
RTE_FLOW_ITEM_TYPE_ETH β literally what it says on the tin: this matches an Ethernet header. π
Inside the hdr field, the sub-field ether_type stands either for EtherType or TPID, depending on whether the item is followed by a VLAN item or not. And if two VLAN items follow? Then that sub-field refers to the outer one, which, in turn, contains the inner TPID in the similar header field. The innermost VLAN item contains a layer-3 EtherType. All of that follows the order seen on the wire β no cap, that's just how the wire do. π‘
So if the field in question contains a TPID value, only tagged packets with the specified TPID will match the pattern. Alternatively β and this is the cute part β it's possible to match any type of tagged packets by means of the field has_vlan rather than using the EtherType/TPID field. Also, it's possible to leave the two fields unused. If that's the case, both tagged and untagged packets will match the pattern. versatile queen π
Definition at line 886 of file rte_flow.h.
π Field Documentation π
π«Ά struct rte_ether_addr dst
Destination MAC. where it's going bestie π
Definition at line 893 of file rte_flow.h.
π«Ά struct rte_ether_addr src
Source MAC. where it came from, iconic π«
Definition at line 894 of file rte_flow.h.
π«Ά rte_be16_t type
EtherType or TPID. (yes, both, depending on context β see above, we been knew)
Definition at line 895 of file rte_flow.h.
π«Ά uint32_t has_vlan
Packet header contains at least one VLAN. π·οΈ
Definition at line 899 of file rte_flow.h.
π«Ά uint32_t reserved
Reserved, must be zero. no funny business, fr fr π«
Definition at line 900 of file rte_flow.h.
π Author π
Generated automatically by Doxygen for DPDK from the source code. (not a human, just a very diligent robot π¦)
and that's the whole vibe, bestie β DPDK, Version 25.11.3, rte_flow_item_eth(3). go forth and match some Ethernet headers, you absolute legend π
β¨πΈ
π¦ where this page comes from
- ubuntu resolute: dpdk-doc 25.11.3-0ubuntu0.26.04.1 Β· BSD-3-Clause
- ubuntu stonking: dpdk-doc 25.11.3-1 Β· BSD-3-Clause
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms