Visible to Intel only — GUID: wqx1626225113388
Ixiasoft
Visible to Intel only — GUID: wqx1626225113388
Ixiasoft
8.2.7. API List
API | API Description | Input Parameters | Return Values |
---|---|---|---|
int rte_eth_dev_configure(uint16_t port_id, uint16_t nb_rx_q, uint16_t nb_tx_q, const struct rte_eth_conf *dev_conf) | This API configures an Ethernet device. This function must be invoked first before any other function in the Ethernet API. |
port ID: device ID nb_tx_queues : Number of TX Queues num_rx_queues: Number of Rx Queues eth_config : input configuration |
0 Success, device configured <0 Error code returned by the driver configuration function |
API | API Description | Input Parameters | Return Values |
---|---|---|---|
Int rte_eth_tx_queue_setup(uint16_t port_id, uint16_t tx_queue_id, uint16_t nb_tx_desc, unsigned int socket_id, const struct rte_eth_rxconf *tx_conf) |
This API allocates and set up a receive queue for DMA device. |
port ID: Port ID of device tx_queue_id: Queue ID nb_tx_desc: Number of Tx descriptors to allocate for the transmit ring socket_id: socket identifier tx_conf: TX configuration context |
0 on success negative otherwise |
API | API Description | Input Parameters | Return Values |
---|---|---|---|
int rte_eth_rx_queue_setup(uint16_t port_id, uint16_t rx_queue_id, uint16_t nb_rx_desc, unsigned int socket_id, const struct rte_eth_rxconf *rx_conf, struct rte_mempool *mp) |
This API allocates and set up a receive queue for DMA device. |
port ID: Port ID of device rx_queue_id: Queue ID nb_rx_desc: Number of Rx descriptors to allocate for the receive ring socket_id: socket identifier rx_conf: RX configuration context mp: Pointer to the memory pool from which is used to allocate memory buffers for each descriptor of the receive ring |
0 on success negative otherwise |
API | API Description | Input Parameters | Return Values |
---|---|---|---|
int rte_eth_dev_set_mtu(uint16_t port_id, uint16_t mtu) |
This API sets the payload value for the processing. |
port ID: Port ID of device mtu: MTU to be applied |
0 on success negative otherwise |
API | API Description | Input Parameters | Return Values |
---|---|---|---|
int rte_eth_dev_start(uint16_t port_id) |
This API starts the Ethernet device by initializing descriptors, QCSR Rx and Tx context. |
port ID: Port ID of device |
0 on success negative otherwise |
API | API Description | Input Parameters | Return Values |
---|---|---|---|
void rte_eth_dev_stop(uint16_t port_id) |
This API stops the Ethernet device. |
port ID: Port ID of device |
void |
API | API Description | Input Parameters | Return Values |
---|---|---|---|
Void rte_eth_dev_close(uint16_t port_id) |
This API closes the Ethernet device. |
port ID: Port ID of device |
void |
API | API Description | Input Parameters | Return Values |
---|---|---|---|
static inline uint16_t rte_eth_tx_burst (uint16_t port_id, uint16_t queue_id, struct rte_mbuf **tx_pkts, const uint16_t nb_pkts) |
This API is used to transmit burst of packets. |
port ID: Port ID of device queue_id: Queue ID tx_pkts: Array of pointers to *rte_mbuf* structures nb_pkts: Maximum number of packets to retrieve |
The number of output packets actually stored in transmit descriptors. |
API | API Description | Input Parameters | Return Values |
---|---|---|---|
static inline uint16_t rte_eth_rx_burst (uint16_t port_id, uint16_t queue_id, struct rte_mbuf **rx_pkts, const uint16_t nb_pkts) |
This API is used to receives burst of packets. |
port ID: Port ID of device queue_id: Queue ID rx_pkts: Array of pointers to *rte_mbuf* structures nb_pkts: Maximum number of packets to retrieve |
The number of packets actually retrieved. |
API | API Description | Input Parameters | Return Values |
---|---|---|---|
uint32_t ifc_mcdma_pio_read32(struct ifc_mcdma_device *qdev, uint64_t addr); - New |
Read 32b value from BAR2 address This API is used for PIO testing, dumping statistics, pattern generation etc. |
qdev: MCDMA device addr: address to read |
0 on success negative otherwise |
API | API Description | Input Parameters | Return Values |
---|---|---|---|
void ifc_mcdma_pio_write32( struct ifc_mcdma_device *qdev, uint64_t addr, uint32_t val) - New |
Writes 32b value to BAR2 address |
qdev: MCDMA device addr: address to write val: value to write |
0 on success and populates channel context negative otherwise |
API | API Description | Input Parameters | Return Values |
---|---|---|---|
Uint64_t ifc_mcdma_pio_read64(struct ifc_mcdma_device *qdev, uint64_t addr); - New |
Read 64b value from BAR2 address This API is used for PIO testing, dumping statistics, pattern generation etc. |
qdev: MCDMA device addr: address to read |
0 on success negative otherwise |
API | API Description | Input Parameters | Return Values |
---|---|---|---|
void ifc_mcdma_pio_write64(struct ifc_mcdma_device *qdev, uint64_t addr, uint64_t val) - New |
Writes 64 bit value to BAR2 address |
qdev: MCDMA device addr: address to write val: value to write |
0 on success and populates channel context negative otherwise |