]> git.proxmox.com Git - ceph.git/blame - ceph/src/seastar/dpdk/lib/librte_port/rte_port_ethdev.h
import 15.2.0 Octopus source
[ceph.git] / ceph / src / seastar / dpdk / lib / librte_port / rte_port_ethdev.h
CommitLineData
9f95a23c
TL
1/* SPDX-License-Identifier: BSD-3-Clause
2 * Copyright(c) 2010-2014 Intel Corporation
7c673cae
FG
3 */
4
5#ifndef __INCLUDE_RTE_PORT_ETHDEV_H__
6#define __INCLUDE_RTE_PORT_ETHDEV_H__
7
8#ifdef __cplusplus
9extern "C" {
10#endif
11
12/**
13 * @file
14 * RTE Port Ethernet Device
15 *
16 * ethdev_reader: input port built on top of pre-initialized NIC RX queue
17 * ethdev_writer: output port built on top of pre-initialized NIC TX queue
18 *
19 ***/
20
21#include <stdint.h>
22
23#include "rte_port.h"
24
25/** ethdev_reader port parameters */
26struct rte_port_ethdev_reader_params {
27 /** NIC RX port ID */
9f95a23c 28 uint16_t port_id;
7c673cae
FG
29
30 /** NIC RX queue ID */
31 uint16_t queue_id;
32};
33
34/** ethdev_reader port operations */
35extern struct rte_port_in_ops rte_port_ethdev_reader_ops;
36
37/** ethdev_writer port parameters */
38struct rte_port_ethdev_writer_params {
39 /** NIC RX port ID */
9f95a23c 40 uint16_t port_id;
7c673cae
FG
41
42 /** NIC RX queue ID */
43 uint16_t queue_id;
44
45 /** Recommended burst size to NIC TX queue. The actual burst size can be
46 bigger or smaller than this value. */
47 uint32_t tx_burst_sz;
48};
49
50/** ethdev_writer port operations */
51extern struct rte_port_out_ops rte_port_ethdev_writer_ops;
52
53/** ethdev_writer_nodrop port parameters */
54struct rte_port_ethdev_writer_nodrop_params {
55 /** NIC RX port ID */
9f95a23c 56 uint16_t port_id;
7c673cae
FG
57
58 /** NIC RX queue ID */
59 uint16_t queue_id;
60
61 /** Recommended burst size to NIC TX queue. The actual burst size can be
62 bigger or smaller than this value. */
63 uint32_t tx_burst_sz;
64
65 /** Maximum number of retries, 0 for no limit */
66 uint32_t n_retries;
67};
68
69/** ethdev_writer_nodrop port operations */
70extern struct rte_port_out_ops rte_port_ethdev_writer_nodrop_ops;
71
72#ifdef __cplusplus
73}
74#endif
75
76#endif