---
name: "rte_flow_ops"
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_ops"
---

# rte\_flow\_ops(3)

## NAME

rte\_flow\_ops

## SYNOPSIS

`#include <rte_flow_driver.h>`

### Data Fields

int(\* **validate** )(struct rte\_eth\_dev \*, const struct **rte\_flow\_attr** \*, const struct **rte\_flow\_item**\[\], const struct **rte\_flow\_action**\[\], struct **rte\_flow\_error** \*)\
 struct rte\_flow \*(\* **create** )(struct rte\_eth\_dev \*, const struct **rte\_flow\_attr** \*, const struct **rte\_flow\_item**\[\], const struct **rte\_flow\_action**\[\], struct **rte\_flow\_error** \*)\
 int(\* **destroy** )(struct rte\_eth\_dev \*, struct rte\_flow \*, struct **rte\_flow\_error** \*)\
 int(\* **flush** )(struct rte\_eth\_dev \*, struct **rte\_flow\_error** \*)\
 int(\* **query** )(struct rte\_eth\_dev \*, struct rte\_flow \*, const struct **rte\_flow\_action** \*, void \*, struct **rte\_flow\_error** \*)\
 int(\* **isolate** )(struct rte\_eth\_dev \*, int, struct **rte\_flow\_error** \*)\
 int(\* **dev\_dump** )(struct rte\_eth\_dev \*dev, struct rte\_flow \*flow, FILE \*file, struct **rte\_flow\_error** \*error)\
 int(\* **get\_aged\_flows** )(struct rte\_eth\_dev \*dev, void \*\*context, uint32\_t nb\_contexts, struct **rte\_flow\_error** \*err)\
 int(\* **get\_q\_aged\_flows** )(struct rte\_eth\_dev \*dev, uint32\_t queue\_id, void \*\*contexts, uint32\_t nb\_contexts, struct **rte\_flow\_error** \*error)\
 struct rte\_flow\_action\_handle \*(\* **action\_handle\_create** )(struct rte\_eth\_dev \*dev, const struct **rte\_flow\_indir\_action\_conf** \*conf, const struct **rte\_flow\_action** \*action, struct **rte\_flow\_error** \*error)\
 int(\* **action\_handle\_destroy** )(struct rte\_eth\_dev \*dev, struct rte\_flow\_action\_handle \*handle, struct **rte\_flow\_error** \*error)\
 int(\* **action\_handle\_update** )(struct rte\_eth\_dev \*dev, struct rte\_flow\_action\_handle \*handle, const void \*update, struct **rte\_flow\_error** \*error)\
 int(\* **action\_handle\_query** )(struct rte\_eth\_dev \*dev, const struct rte\_flow\_action\_handle \*handle, void \*data, struct **rte\_flow\_error** \*error)\
 int(\* **action\_handle\_query\_update** )(struct rte\_eth\_dev \*dev, struct rte\_flow\_action\_handle \*handle, const void \*update, void \***query**, enum **rte\_flow\_query\_update\_mode** qu\_mode, struct **rte\_flow\_error** \*error)\
 struct rte\_flow\_action\_list\_handle \*(\* **action\_list\_handle\_create** )(struct rte\_eth\_dev \*dev, const struct **rte\_flow\_indir\_action\_conf** \*conf, const struct **rte\_flow\_action** actions\[\], struct **rte\_flow\_error** \*error)\
 int(\* **action\_list\_handle\_destroy** )(struct rte\_eth\_dev \*dev, struct rte\_flow\_action\_list\_handle \*handle, struct **rte\_flow\_error** \*error)\
 int(\* **tunnel\_decap\_set** )(struct rte\_eth\_dev \*dev, struct rte\_flow\_tunnel \*tunnel, struct **rte\_flow\_action** \*\*pmd\_actions, uint32\_t \*num\_of\_actions, struct **rte\_flow\_error** \*err)\
 int(\* **tunnel\_match** )(struct rte\_eth\_dev \*dev, struct rte\_flow\_tunnel \*tunnel, struct **rte\_flow\_item** \*\*pmd\_items, uint32\_t \*num\_of\_items, struct **rte\_flow\_error** \*err)\
 int(\* **get\_restore\_info** )(struct rte\_eth\_dev \*dev, struct **rte\_mbuf** \*m, struct **rte\_flow\_restore\_info** \*info, struct **rte\_flow\_error** \*err)\
 int(\* **tunnel\_action\_decap\_release** )(struct rte\_eth\_dev \*dev, struct **rte\_flow\_action** \*pmd\_actions, uint32\_t num\_of\_actions, struct **rte\_flow\_error** \*err)\
 int(\* **tunnel\_item\_release** )(struct rte\_eth\_dev \*dev, struct **rte\_flow\_item** \*pmd\_items, uint32\_t num\_of\_items, struct **rte\_flow\_error** \*err)\
 int(\* **pick\_transfer\_proxy** )(struct rte\_eth\_dev \*dev, uint16\_t \*proxy\_port\_id, struct **rte\_flow\_error** \*error)\
 int(\* **info\_get** )(struct rte\_eth\_dev \*dev, struct **rte\_flow\_port\_info** \*port\_info, struct **rte\_flow\_queue\_info** \*queue\_info, struct **rte\_flow\_error** \*err)\
 int(\* **configure** )(struct rte\_eth\_dev \*dev, const struct **rte\_flow\_port\_attr** \*port\_attr, uint16\_t nb\_queue, const struct **rte\_flow\_queue\_attr** \*queue\_attr\[\], struct **rte\_flow\_error** \*err)\
 struct rte\_flow\_pattern\_template \*(\* **pattern\_template\_create** )(struct rte\_eth\_dev \*dev, const struct **rte\_flow\_pattern\_template\_attr** \*template\_attr, const struct **rte\_flow\_item** pattern\[\], struct **rte\_flow\_error** \*err)\
 int(\* **pattern\_template\_destroy** )(struct rte\_eth\_dev \*dev, struct rte\_flow\_pattern\_template \*pattern\_template, struct **rte\_flow\_error** \*err)\
 struct rte\_flow\_actions\_template \*(\* **actions\_template\_create** )(struct rte\_eth\_dev \*dev, const struct **rte\_flow\_actions\_template\_attr** \*template\_attr, const struct **rte\_flow\_action** actions\[\], const struct **rte\_flow\_action** masks\[\], struct **rte\_flow\_error** \*err)\
 int(\* **actions\_template\_destroy** )(struct rte\_eth\_dev \*dev, struct rte\_flow\_actions\_template \*actions\_template, struct **rte\_flow\_error** \*err)\
 struct rte\_flow\_template\_table \*(\* **template\_table\_create** )(struct rte\_eth\_dev \*dev, const struct **rte\_flow\_template\_table\_attr** \*table\_attr, struct rte\_flow\_pattern\_template \*pattern\_templates\[\], uint8\_t nb\_pattern\_templates, struct rte\_flow\_actions\_template \*actions\_templates\[\], uint8\_t nb\_actions\_templates, struct **rte\_flow\_error** \*err)\
 int(\* **template\_table\_destroy** )(struct rte\_eth\_dev \*dev, struct rte\_flow\_template\_table \*template\_table, struct **rte\_flow\_error** \*err)\
 int(\* **group\_set\_miss\_actions** )(struct rte\_eth\_dev \*dev, uint32\_t group\_id, const struct rte\_flow\_group\_attr \*attr, const struct **rte\_flow\_action** actions\[\], struct **rte\_flow\_error** \*err)\
 int(\* **actions\_update** )(struct rte\_eth\_dev \*dev, struct rte\_flow \*flow, const struct **rte\_flow\_action** actions\[\], struct **rte\_flow\_error** \*error)\
 int(\* **action\_list\_handle\_query\_update** )(struct rte\_eth\_dev \*dev, const struct rte\_flow\_action\_list\_handle \*handle, const void \*\*update, void \*\***query**, enum **rte\_flow\_query\_update\_mode** mode, struct **rte\_flow\_error** \*error)\
 int(\* **flow\_calc\_table\_hash** )(struct rte\_eth\_dev \*dev, const struct rte\_flow\_template\_table \*table, const struct **rte\_flow\_item** pattern\[\], uint8\_t pattern\_template\_index, uint32\_t \*hash, struct **rte\_flow\_error** \*error)\
 int(\* **flow\_calc\_encap\_hash** )(struct rte\_eth\_dev \*dev, const struct **rte\_flow\_item** pattern\[\], enum **rte\_flow\_encap\_hash\_field** dest\_field, uint8\_t \*hash, struct **rte\_flow\_error** \*error)\
 int(\* **flow\_template\_table\_resize** )(struct rte\_eth\_dev \*dev, struct rte\_flow\_template\_table \*table, uint32\_t nb\_rules, struct **rte\_flow\_error** \*error)\
 int(\* **flow\_update\_resized** )(struct rte\_eth\_dev \*dev, uint32\_t queue, const struct **rte\_flow\_op\_attr** \*attr, struct rte\_flow \*rule, void \*user\_data, struct **rte\_flow\_error** \*error)\
 int(\* **flow\_template\_table\_resize\_complete** )(struct rte\_eth\_dev \*dev, struct rte\_flow\_template\_table \*table, struct **rte\_flow\_error** \*error)\

## Detailed Description

Generic flow operations structure implemented and returned by PMDs.

These callback functions are not supposed to be used by applications directly, which must rely on the API defined in **rte\_flow.h**.

Public-facing wrapper functions perform a few consistency checks so that unimplemented (i.e. NULL) callbacks simply return -ENOTSUP. These callbacks otherwise only differ by their first argument (with port ID already resolved to a pointer to struct rte\_eth\_dev).

Definition at line **39** of file **rte\_flow\_driver.h**.

## Field Documentation

### int(\* validate) (struct rte\_eth\_dev \*, const struct rte\_flow\_attr \*, const struct rte\_flow\_item\[\], const struct rte\_flow\_action\[\], struct rte\_flow\_error \*)

See **rte\_flow\_validate()**.

Definition at line **41** of file **rte\_flow\_driver.h**.

### struct rte\_flow \*(\* create) (struct rte\_eth\_dev \*, const struct rte\_flow\_attr \*, const struct rte\_flow\_item\[\], const struct rte\_flow\_action\[\], struct rte\_flow\_error \*)

See **rte\_flow\_create()**.

Definition at line **41** of file **rte\_flow\_driver.h**.

### int(\* destroy) (struct rte\_eth\_dev \*, struct rte\_flow \*, struct rte\_flow\_error \*)

See **rte\_flow\_destroy()**.

Definition at line **55** of file **rte\_flow\_driver.h**.

### int(\* flush) (struct rte\_eth\_dev \*, struct rte\_flow\_error \*)

See **rte\_flow\_flush()**.

Definition at line **60** of file **rte\_flow\_driver.h**.

### int(\* query) (struct rte\_eth\_dev \*, struct rte\_flow \*, const struct rte\_flow\_action \*, void \*, struct rte\_flow\_error \*)

See **rte\_flow\_query()**.

Definition at line **64** of file **rte\_flow\_driver.h**.

### int(\* isolate) (struct rte\_eth\_dev \*, int, struct rte\_flow\_error \*)

See **rte\_flow\_isolate()**.

Definition at line **71** of file **rte\_flow\_driver.h**.

### int(\* dev\_dump) (struct rte\_eth\_dev \*dev, struct rte\_flow \*flow, FILE \*file, struct rte\_flow\_error \*error)

See **rte\_flow\_dev\_dump()**.

Definition at line **76** of file **rte\_flow\_driver.h**.

### int(\* get\_aged\_flows) (struct rte\_eth\_dev \*dev, void \*\*context, uint32\_t nb\_contexts, struct rte\_flow\_error \*err)

See **rte\_flow\_get\_aged\_flows()**

Definition at line **82** of file **rte\_flow\_driver.h**.

### int(\* get\_q\_aged\_flows) (struct rte\_eth\_dev \*dev, uint32\_t queue\_id, void \*\*contexts, uint32\_t nb\_contexts, struct rte\_flow\_error \*error)

See **rte\_flow\_get\_q\_aged\_flows()**

Definition at line **88** of file **rte\_flow\_driver.h**.

### struct rte\_flow\_action\_handle \*(\* action\_handle\_create) (struct rte\_eth\_dev \*dev, const struct rte\_flow\_indir\_action\_conf \*conf, const struct rte\_flow\_action \*action, struct rte\_flow\_error \*error)

See **rte\_flow\_action\_handle\_create()**

Definition at line **88** of file **rte\_flow\_driver.h**.

### int(\* action\_handle\_destroy) (struct rte\_eth\_dev \*dev, struct rte\_flow\_action\_handle \*handle, struct rte\_flow\_error \*error)

See **rte\_flow\_action\_handle\_destroy()**

Definition at line **101** of file **rte\_flow\_driver.h**.

### int(\* action\_handle\_update) (struct rte\_eth\_dev \*dev, struct rte\_flow\_action\_handle \*handle, const void \*update, struct rte\_flow\_error \*error)

See **rte\_flow\_action\_handle\_update()**

Definition at line **106** of file **rte\_flow\_driver.h**.

### int(\* action\_handle\_query) (struct rte\_eth\_dev \*dev, const struct rte\_flow\_action\_handle \*handle, void \*data, struct rte\_flow\_error \*error)

See **rte\_flow\_action\_handle\_query()**

Definition at line **112** of file **rte\_flow\_driver.h**.

### int(\* action\_handle\_query\_update) (struct rte\_eth\_dev \*dev, struct rte\_flow\_action\_handle \*handle, const void \*update, void \*query, enum rte\_flow\_query\_update\_mode qu\_mode, struct rte\_flow\_error \*error)

See **rte\_flow\_action\_handle\_query\_update()**

Definition at line **118** of file **rte\_flow\_driver.h**.

### struct rte\_flow\_action\_list\_handle \*(\* action\_list\_handle\_create) (struct rte\_eth\_dev \*dev, const struct rte\_flow\_indir\_action\_conf \*conf, const struct rte\_flow\_action actions\[\], struct rte\_flow\_error \*error)

**See also**

**rte\_flow\_action\_list\_handle\_create()**

Definition at line **118** of file **rte\_flow\_driver.h**.

### int(\* action\_list\_handle\_destroy) (struct rte\_eth\_dev \*dev, struct rte\_flow\_action\_list\_handle \*handle, struct rte\_flow\_error \*error)

**See also**

**rte\_flow\_action\_list\_handle\_destroy()**

Definition at line **131** of file **rte\_flow\_driver.h**.

### int(\* tunnel\_decap\_set) (struct rte\_eth\_dev \*dev, struct rte\_flow\_tunnel \*tunnel, struct rte\_flow\_action \*\*pmd\_actions, uint32\_t \*num\_of\_actions, struct rte\_flow\_error \*err)

See **rte\_flow\_tunnel\_decap\_set()**

Definition at line **136** of file **rte\_flow\_driver.h**.

### int(\* tunnel\_match) (struct rte\_eth\_dev \*dev, struct rte\_flow\_tunnel \*tunnel, struct rte\_flow\_item \*\*pmd\_items, uint32\_t \*num\_of\_items, struct rte\_flow\_error \*err)

See **rte\_flow\_tunnel\_match()**

Definition at line **143** of file **rte\_flow\_driver.h**.

### int(\* get\_restore\_info) (struct rte\_eth\_dev \*dev, struct rte\_mbuf \*m, struct rte\_flow\_restore\_info \*info, struct rte\_flow\_error \*err)

See rte\_flow\_get\_rte\_flow\_restore\_info()

Definition at line **150** of file **rte\_flow\_driver.h**.

### int(\* tunnel\_action\_decap\_release) (struct rte\_eth\_dev \*dev, struct rte\_flow\_action \*pmd\_actions, uint32\_t num\_of\_actions, struct rte\_flow\_error \*err)

See rte\_flow\_action\_tunnel\_decap\_release()

Definition at line **156** of file **rte\_flow\_driver.h**.

### int(\* tunnel\_item\_release) (struct rte\_eth\_dev \*dev, struct rte\_flow\_item \*pmd\_items, uint32\_t num\_of\_items, struct rte\_flow\_error \*err)

See rte\_flow\_item\_release()

Definition at line **162** of file **rte\_flow\_driver.h**.

### int(\* pick\_transfer\_proxy) (struct rte\_eth\_dev \*dev, uint16\_t \*proxy\_port\_id, struct rte\_flow\_error \*error)

See **rte\_flow\_pick\_transfer\_proxy()**

Definition at line **168** of file **rte\_flow\_driver.h**.

### int(\* info\_get) (struct rte\_eth\_dev \*dev, struct rte\_flow\_port\_info \*port\_info, struct rte\_flow\_queue\_info \*queue\_info, struct rte\_flow\_error \*err)

See **rte\_flow\_info\_get()**

Definition at line **181** of file **rte\_flow\_driver.h**.

### int(\* configure) (struct rte\_eth\_dev \*dev, const struct rte\_flow\_port\_attr \*port\_attr, uint16\_t nb\_queue, const struct rte\_flow\_queue\_attr \*queue\_attr\[\], struct rte\_flow\_error \*err)

See **rte\_flow\_configure()**

Definition at line **187** of file **rte\_flow\_driver.h**.

### struct rte\_flow\_pattern\_template \*(\* pattern\_template\_create) (struct rte\_eth\_dev \*dev, const struct rte\_flow\_pattern\_template\_attr \*template\_attr, const struct rte\_flow\_item pattern\[\], struct rte\_flow\_error \*err)

See **rte\_flow\_pattern\_template\_create()**

Definition at line **187** of file **rte\_flow\_driver.h**.

### int(\* pattern\_template\_destroy) (struct rte\_eth\_dev \*dev, struct rte\_flow\_pattern\_template \*pattern\_template, struct rte\_flow\_error \*err)

See **rte\_flow\_pattern\_template\_destroy()**

Definition at line **200** of file **rte\_flow\_driver.h**.

### struct rte\_flow\_actions\_template \*(\* actions\_template\_create) (struct rte\_eth\_dev \*dev, const struct rte\_flow\_actions\_template\_attr \*template\_attr, const struct rte\_flow\_action actions\[\], const struct rte\_flow\_action masks\[\], struct rte\_flow\_error \*err)

See **rte\_flow\_actions\_template\_create()**

Definition at line **200** of file **rte\_flow\_driver.h**.

### int(\* actions\_template\_destroy) (struct rte\_eth\_dev \*dev, struct rte\_flow\_actions\_template \*actions\_template, struct rte\_flow\_error \*err)

See **rte\_flow\_actions\_template\_destroy()**

Definition at line **212** of file **rte\_flow\_driver.h**.

### struct rte\_flow\_template\_table \*(\* template\_table\_create) (struct rte\_eth\_dev \*dev, const struct rte\_flow\_template\_table\_attr \*table\_attr, struct rte\_flow\_pattern\_template \*pattern\_templates\[\], uint8\_t nb\_pattern\_templates, struct rte\_flow\_actions\_template \*actions\_templates\[\], uint8\_t nb\_actions\_templates, struct rte\_flow\_error \*err)

See **rte\_flow\_template\_table\_create()**

Definition at line **212** of file **rte\_flow\_driver.h**.

### int(\* template\_table\_destroy) (struct rte\_eth\_dev \*dev, struct rte\_flow\_template\_table \*template\_table, struct rte\_flow\_error \*err)

See **rte\_flow\_template\_table\_destroy()**

Definition at line **226** of file **rte\_flow\_driver.h**.

### int(\* group\_set\_miss\_actions) (struct rte\_eth\_dev \*dev, uint32\_t group\_id, const struct rte\_flow\_group\_attr \*attr, const struct rte\_flow\_action actions\[\], struct rte\_flow\_error \*err)

See **rte\_flow\_group\_set\_miss\_actions()**

Definition at line **231** of file **rte\_flow\_driver.h**.

### int(\* actions\_update) (struct rte\_eth\_dev \*dev, struct rte\_flow \*flow, const struct rte\_flow\_action actions\[\], struct rte\_flow\_error \*error)

See **rte\_flow\_actions\_update()**.

Definition at line **238** of file **rte\_flow\_driver.h**.

### int(\* action\_list\_handle\_query\_update) (struct rte\_eth\_dev \*dev, const struct rte\_flow\_action\_list\_handle \*handle, const void \*\*update, void \*\*query, enum rte\_flow\_query\_update\_mode mode, struct rte\_flow\_error \*error)

**See also**

**rte\_flow\_action\_list\_handle\_query\_update()**

Definition at line **244** of file **rte\_flow\_driver.h**.

### int(\* flow\_calc\_table\_hash) (struct rte\_eth\_dev \*dev, const struct rte\_flow\_template\_table \*table, const struct rte\_flow\_item pattern\[\], uint8\_t pattern\_template\_index, uint32\_t \*hash, struct rte\_flow\_error \*error)

**See also**

**rte\_flow\_calc\_table\_hash()**

Definition at line **251** of file **rte\_flow\_driver.h**.

### int(\* flow\_calc\_encap\_hash) (struct rte\_eth\_dev \*dev, const struct rte\_flow\_item pattern\[\], enum rte\_flow\_encap\_hash\_field dest\_field, uint8\_t \*hash, struct rte\_flow\_error \*error)

**See also**

**rte\_flow\_calc\_encap\_hash()**

Definition at line **256** of file **rte\_flow\_driver.h**.

### int(\* flow\_template\_table\_resize) (struct rte\_eth\_dev \*dev, struct rte\_flow\_template\_table \*table, uint32\_t nb\_rules, struct rte\_flow\_error \*error)

**See also**

**rte\_flow\_template\_table\_resize()**

Definition at line **261** of file **rte\_flow\_driver.h**.

### int(\* flow\_update\_resized) (struct rte\_eth\_dev \*dev, uint32\_t queue, const struct rte\_flow\_op\_attr \*attr, struct rte\_flow \*rule, void \*user\_data, struct rte\_flow\_error \*error)

**See also**

**rte\_flow\_async\_update\_resized()**

Definition at line **266** of file **rte\_flow\_driver.h**.

### int(\* flow\_template\_table\_resize\_complete) (struct rte\_eth\_dev \*dev, struct rte\_flow\_template\_table \*table, struct rte\_flow\_error \*error)

**See also**

**rte\_flow\_template\_table\_resize\_complete()**

Definition at line **271** of file **rte\_flow\_driver.h**.

## Author

Generated automatically by Doxygen for DPDK from the source code.
