DPDK 24.11.0-rc2
Loading...
Searching...
No Matches
rte_swx_port.h
Go to the documentation of this file.
1/* SPDX-License-Identifier: BSD-3-Clause
2 * Copyright(c) 2020 Intel Corporation
3 */
4#ifndef __INCLUDE_RTE_SWX_PORT_H__
5#define __INCLUDE_RTE_SWX_PORT_H__
6
14#include <stdint.h>
15
19 void *handle;
20
22 uint8_t *pkt;
23
25 uint32_t offset;
26
28 uint32_t length;
29};
30
31/*
32 * Input port
33 */
34
43typedef void *
44(*rte_swx_port_in_create_t)(void *args);
45
52typedef void
53(*rte_swx_port_in_free_t)(void *port);
54
67typedef int
68(*rte_swx_port_in_pkt_rx_t)(void *port,
69 struct rte_swx_pkt *pkt);
70
74 uint64_t n_pkts;
75
77 uint64_t n_bytes;
78
80 uint64_t n_empty;
81};
82
91typedef void
93 struct rte_swx_port_in_stats *stats);
94
109
110/*
111 * Output port
112 */
113
122typedef void *
123(*rte_swx_port_out_create_t)(void *args);
124
131typedef void
132(*rte_swx_port_out_free_t)(void *port);
133
142typedef void
143(*rte_swx_port_out_pkt_tx_t)(void *port,
144 struct rte_swx_pkt *pkt);
145
154typedef void
156 struct rte_swx_pkt *pkt);
157
168typedef void
170 struct rte_swx_pkt *pkt,
171 uint32_t truncation_length);
172
179typedef void
180(*rte_swx_port_out_flush_t)(void *port);
181
185 uint64_t n_pkts;
186
188 uint64_t n_bytes;
189
191 uint64_t n_pkts_drop;
192
194 uint64_t n_bytes_drop;
195
197 uint64_t n_pkts_clone;
198
201};
202
211typedef void
213 struct rte_swx_port_out_stats *stats);
214
238
239#endif
int(* rte_swx_port_in_pkt_rx_t)(void *port, struct rte_swx_pkt *pkt)
void(* rte_swx_port_in_free_t)(void *port)
void(* rte_swx_port_out_flush_t)(void *port)
void(* rte_swx_port_out_pkt_clone_tx_t)(void *port, struct rte_swx_pkt *pkt, uint32_t truncation_length)
void(* rte_swx_port_in_stats_read_t)(void *port, struct rte_swx_port_in_stats *stats)
void(* rte_swx_port_out_pkt_tx_t)(void *port, struct rte_swx_pkt *pkt)
void(* rte_swx_port_out_free_t)(void *port)
void(* rte_swx_port_out_pkt_fast_clone_tx_t)(void *port, struct rte_swx_pkt *pkt)
void *(* rte_swx_port_in_create_t)(void *args)
void(* rte_swx_port_out_stats_read_t)(void *port, struct rte_swx_port_out_stats *stats)
void *(* rte_swx_port_out_create_t)(void *args)
uint8_t * pkt
void * handle
uint32_t offset
uint32_t length
rte_swx_port_in_free_t free
rte_swx_port_in_stats_read_t stats_read
rte_swx_port_in_pkt_rx_t pkt_rx
rte_swx_port_in_create_t create
rte_swx_port_out_create_t create
rte_swx_port_out_pkt_fast_clone_tx_t pkt_fast_clone_tx
rte_swx_port_out_stats_read_t stats_read
rte_swx_port_out_pkt_clone_tx_t pkt_clone_tx
rte_swx_port_out_pkt_tx_t pkt_tx
rte_swx_port_out_flush_t flush
rte_swx_port_out_free_t free