---
name: "rte_flow_item_eth"
section: "3"
platform: "linux"
package: "dpdk-doc"
version: "24.11.4-0+deb13u1"
release: "Debian 13 (Trixie)"
platforms: ["linux"]
url: "https://new.carta.tech/rte_flow_item_eth"
---

# rte\_flow\_item\_eth(3)

## NAME

rte\_flow\_item\_eth

## SYNOPSIS

`#include <rte_flow.h>`

### Data Fields

uint32\_t **has\_vlan**:1\
 uint32\_t **reserved**:31\

## Detailed Description

RTE\_FLOW\_ITEM\_TYPE\_ETH

Matches an Ethernet header.

Inside `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. If two VLAN items follow, the 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.

If the field in question contains a TPID value, only tagged packets with the specified TPID will match the pattern. Alternatively, it's possible to match any type of tagged packets by means of the field `has_vlan` rather than use the EtherType/TPID field. Also, it's possible to leave the two fields unused. If this is the case, both tagged and untagged packets will match the pattern.

Definition at line **886** of file **rte\_flow.h**.

## Field Documentation

### struct rte\_ether\_addr dst

Destination MAC.

Definition at line **893** of file **rte\_flow.h**.

### struct rte\_ether\_addr src

Source MAC.

Definition at line **894** of file **rte\_flow.h**.

### rte\_be16\_t type

EtherType or TPID.

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.

Definition at line **900** of file **rte\_flow.h**.

## Author

Generated automatically by Doxygen for DPDK from the source code.
