1 /* SPDX-License-Identifier: BSD-3-Clause
2 * Copyright(c) 2017 Intel Corporation
5 #ifndef __INCLUDE_RTE_ETH_SOFTNIC_H__
6 #define __INCLUDE_RTE_ETH_SOFTNIC_H__
15 #ifndef SOFTNIC_FIRMWARE
16 #define SOFTNIC_FIRMWARE "firmware.cli"
19 /** TCP connection port (0 = no connectivity). */
20 #ifndef SOFTNIC_CONN_PORT
21 #define SOFTNIC_CONN_PORT 0
25 #ifndef SOFTNIC_CPU_ID
26 #define SOFTNIC_CPU_ID 0
32 * 0 = The current device is run explicitly by the application. The firmware
33 * creates one or several pipelines for the current device and maps them to
34 * CPU cores that should not be service cores. The application is required
35 * to call rte_pmd_softnic_run() for the current device on each of these CPU
36 * cores in order to make the current device work.
38 * 1 = The current device is run on the service cores transparently to the
39 * application. The firmware creates one or several pipelines for the
40 * current device and maps them to CPU cores that should be service cores.
41 * Each of these service cores is calling rte_pmd_softnic_run() for the
42 * current device in order to make the current device work. The application
43 * is not allowed to call rte_pmd_softnic_run() for the current device.
49 /** Traffic Manager: Number of scheduler queues. */
50 #ifndef SOFTNIC_TM_N_QUEUES
51 #define SOFTNIC_TM_N_QUEUES (64 * 1024)
54 /** Traffic Manager: Scheduler queue size (per traffic class). */
55 #ifndef SOFTNIC_TM_QUEUE_SIZE
56 #define SOFTNIC_TM_QUEUE_SIZE 64
63 * Port ID of the Soft NIC device.
65 * Zero on success, error code otherwise.
68 rte_pmd_softnic_run(uint16_t port_id);
74 * Port ID of the Soft NIC device.
76 * Zero on success, error code otherwise.
80 rte_pmd_softnic_manage(uint16_t port_id);
86 #endif /* __INCLUDE_RTE_ETH_SOFTNIC_H__ */