DPDK  17.11.10
Data Fields
rte_flow_attr Struct Reference

#include <rte_flow.h>

Data Fields

uint32_t group
uint32_t priority
uint32_t ingress:1
uint32_t egress:1
uint32_t reserved:30

Detailed Description

Flow rule attributes.

Priorities are set on two levels: per group and per rule within groups.

Lower values denote higher priority, the highest priority for both levels is 0, so that a rule with priority 0 in group 8 is always matched after a rule with priority 8 in group 0.

Although optional, applications are encouraged to group similar rules as much as possible to fully take advantage of hardware capabilities (e.g. optimized matching) and work around limitations (e.g. a single pattern type possibly allowed in a given group).

Group and priority levels are arbitrary and up to the application, they do not need to be contiguous nor start from 0, however the maximum number varies between devices and may be affected by existing flow rules.

If a packet is matched by several rules of a given group for a given priority level, the outcome is undefined. It can take any path, may be duplicated or even cause unrecoverable errors.

Note that support for more than a single group and priority level is not guaranteed.

Flow rules can apply to inbound and/or outbound traffic (ingress/egress).

Several pattern items and actions are valid and can be used in both directions. Those valid for only one direction are described as such.

At least one direction must be specified.

Specifying both directions at once for a given rule is not recommended but may be valid in a few cases (e.g. shared counter).

examples/flow_classify/flow_classify.c, and examples/flow_filtering/flow_blocks.c.

Definition at line 94 of file rte_flow.h.

Field Documentation

uint32_t group

Priority group.

Definition at line 95 of file rte_flow.h.

uint32_t priority

Priority level within group.

Definition at line 96 of file rte_flow.h.

uint32_t ingress

Rule applies to ingress traffic.

Definition at line 97 of file rte_flow.h.

uint32_t egress

Rule applies to egress traffic.

Definition at line 98 of file rte_flow.h.

uint32_t reserved

Reserved, must be zero.

Definition at line 99 of file rte_flow.h.

The documentation for this struct was generated from the following file: