| NVIDIA DOCA SDK | Data Center on a Chip Framework Documentation |

Modules | |
| DOCA ETH TXQ CPU Data Path | |
| DOCA ETH TXQ GPU Data Path | |
Enumerations | |
| enum | doca_eth_txq_type { DOCA_ETH_TXQ_TYPE_REGULAR = 0 } |
| enum | doca_eth_txq_data_path_type { DOCA_ETH_TXQ_DATA_PATH_TYPE_CPU = 0 , DOCA_ETH_TXQ_DATA_PATH_TYPE_GPU } |
Functions | |
| DOCA_EXPERIMENTAL doca_error_t | doca_eth_txq_create (struct doca_dev *dev, uint32_t max_burst_size, struct doca_eth_txq **eth_txq) |
| Create a DOCA ETH TXQ instance. More... | |
| DOCA_EXPERIMENTAL doca_error_t | doca_eth_txq_destroy (struct doca_eth_txq *eth_txq) |
| Destroy a DOCA ETH TXQ instance. More... | |
| DOCA_EXPERIMENTAL struct doca_ctx * | doca_eth_txq_as_doca_ctx (struct doca_eth_txq *eth_txq) |
| Convert doca_eth_txq instance into a generalized context for use with doca core objects. More... | |
| DOCA_EXPERIMENTAL doca_error_t | doca_eth_txq_set_max_burst_size (struct doca_eth_txq *eth_txq, uint32_t max_burst_size) |
| Set max burst size property for doca_eth_txq. This value dictates the maximal number of packets the HW can handle at the same time. can only be called before calling doca_ctx_start(). More... | |
| DOCA_EXPERIMENTAL doca_error_t | doca_eth_txq_set_max_send_buf_list_len (struct doca_eth_txq *eth_txq, uint32_t max_send_buf_list_len) |
| Set the maximal send buffer list length for doca_eth_txq. This value indicated what the maximal number of elements in a doca_buf list is. can only be called before calling doca_ctx_start(). More... | |
| DOCA_EXPERIMENTAL doca_error_t | doca_eth_txq_set_metadata_num (struct doca_eth_txq *eth_txq, uint8_t metadata_num) |
| Set metadata number for doca_eth_txq. This value is the number of metadata per packet. can only be called before calling doca_ctx_start(). More... | |
| DOCA_EXPERIMENTAL doca_error_t | doca_eth_txq_set_mss (struct doca_eth_txq *eth_txq, uint16_t mss) |
| Set the Maximum Segment Size for doca_eth_txq. This value will be used per LSO send task / task_batch unless user overrides it (by setting MSS on the specific task / task_batch). This value is the maximum data size that can be sent in each segment of the LSO packet. can only be called before calling doca_ctx_start(). More... | |
| DOCA_EXPERIMENTAL doca_error_t | doca_eth_txq_set_max_lso_header_size (struct doca_eth_txq *eth_txq, uint16_t max_lso_header_size) |
| Set the maximum LSO header size for doca_eth_txq. This value is the maximum header size of the LSO packet can only be called before calling doca_ctx_start(). More... | |
| DOCA_EXPERIMENTAL doca_error_t | doca_eth_txq_set_type (struct doca_eth_txq *eth_txq, enum doca_eth_txq_type type) |
| Set TX queue type property for doca_eth_txq. can only be called before calling doca_ctx_start(). More... | |
| DOCA_EXPERIMENTAL doca_error_t | doca_eth_txq_set_l3_chksum_offload (struct doca_eth_txq *eth_txq, uint8_t enable_l3_chksum) |
| Set offload for the calculation of IPv4 checksum (L3) on transmitted packets. If the users enables L3 checksum offloading, then the HW will calculate the checksum value and write it into the specific field in the packet. This offload is enabled/disabled to every task / task_batch by default. User can change this by modifying the ol_flag value (See "enum doca_eth_txq_ol_flags"). can only be called before calling doca_ctx_start(). More... | |
| DOCA_EXPERIMENTAL doca_error_t | doca_eth_txq_set_l4_chksum_offload (struct doca_eth_txq *eth_txq, uint8_t enable_l4_chksum) |
| Set offload for the calculation of TCP/UDP checksum (L4) on transmitted packets. If the users enables L4 checksum offloading, then the HW will calculate the checksum value and write it into the specific field in the packet. This offload is enabled/disabled to every task / task_batch by default. User can change this by modifying the ol_flag value (See "enum doca_eth_txq_ol_flags"). can only be called before calling doca_ctx_start(). More... | |
| DOCA_EXPERIMENTAL doca_error_t | doca_eth_txq_set_wait_on_time_offload (struct doca_eth_txq *eth_txq) |
| Set offload to enable wait on time feature on the queue. can only be called before calling doca_ctx_start(). More... | |
| DOCA_EXPERIMENTAL doca_error_t | doca_eth_txq_get_gpu_handle (const struct doca_eth_txq *eth_txq, struct doca_gpu_eth_txq **eth_txq_ext) |
| Get a gpu handle of a doca_eth_txq. More... | |
| DOCA_EXPERIMENTAL doca_error_t | doca_eth_txq_cap_get_max_burst_size (const struct doca_devinfo *devinfo, uint32_t max_send_buf_list_len, uint16_t max_lso_header_size, uint32_t *max_burst_size) |
| Get the maximum burst size supported by the device. More... | |
| DOCA_EXPERIMENTAL doca_error_t | doca_eth_txq_cap_get_max_send_buf_list_len (const struct doca_devinfo *devinfo, uint32_t *max_send_buf_list_len) |
| Get the maximum send buffer list length supported by the device. More... | |
| DOCA_EXPERIMENTAL doca_error_t | doca_eth_txq_cap_get_max_metadata_num (const struct doca_devinfo *devinfo, uint8_t *max_metadata_num) |
| Get the maximum metadata number supported by the device. More... | |
| DOCA_EXPERIMENTAL doca_error_t | doca_eth_txq_cap_get_max_lso_header_size (const struct doca_devinfo *devinfo, uint16_t *max_lso_header_size) |
| Get the maximum header size of an LSO packet supported by the device. More... | |
| DOCA_EXPERIMENTAL doca_error_t | doca_eth_txq_cap_is_type_supported (const struct doca_devinfo *devinfo, enum doca_eth_txq_type type, enum doca_eth_txq_data_path_type data_path_type) |
| Check if TX queue type is supported. More... | |
| DOCA_EXPERIMENTAL doca_error_t | doca_eth_txq_cap_is_l3_chksum_offload_supported (const struct doca_devinfo *devinfo) |
| Check if L3 checksum offload is supported by the device. More... | |
| DOCA_EXPERIMENTAL doca_error_t | doca_eth_txq_cap_is_l4_chksum_offload_supported (const struct doca_devinfo *devinfo) |
| Check if L4 checksum offload is supported by the device. More... | |
| DOCA_EXPERIMENTAL doca_error_t | doca_eth_txq_cap_get_max_lso_msg_size (const struct doca_devinfo *devinfo, uint32_t *max_lso_msg_size) |
| Get the max LSO message size by the network device. More... | |
| DOCA_EXPERIMENTAL doca_error_t | doca_eth_txq_cap_get_wait_on_time_offload_supported (const struct doca_devinfo *devinfo, enum doca_eth_wait_on_time_type *wait_on_time_mode) |
| Check if wait on time offload is supported by the network device. More... | |
| DOCA_EXPERIMENTAL doca_error_t | doca_eth_txq_calculate_timestamp (struct doca_eth_txq *eth_txq, uint64_t timestamp_ns, uint64_t *wait_on_time_value) |
| Calculate timestamp to use when setting the wait on time on the Tx queue. More... | |
| DOCA_EXPERIMENTAL doca_error_t | doca_eth_txq_get_flow_queue_id (struct doca_eth_txq *eth_txq, uint16_t *flow_queue_id) |
| Get the DPDK queue ID of the doca_eth send queue. can only be called after calling doca_ctx_start(). More... | |
DOCA ETH TXQ library.
TX data-path type.
| Enumerator | |
|---|---|
| DOCA_ETH_TXQ_DATA_PATH_TYPE_CPU | Enable data path management on the CPU |
| DOCA_ETH_TXQ_DATA_PATH_TYPE_GPU | Enable data path management on the GPU |
Definition at line 71 of file doca_eth_txq.h.
| enum doca_eth_txq_type |
| DOCA_EXPERIMENTAL struct doca_ctx* doca_eth_txq_as_doca_ctx | ( | struct doca_eth_txq * | eth_txq | ) |
Convert doca_eth_txq instance into a generalized context for use with doca core objects.
| [in] | eth_txq | Pointer to doca_eth_txq instance. |
| DOCA_EXPERIMENTAL doca_error_t doca_eth_txq_calculate_timestamp | ( | struct doca_eth_txq * | eth_txq, |
| uint64_t | timestamp_ns, | ||
| uint64_t * | wait_on_time_value | ||
| ) |
Calculate timestamp to use when setting the wait on time on the Tx queue.
| [in] | eth_txq | Pointer to doca_eth_txq instance. |
| [in] | timestamp_ns | Timestamp to indicate when send packets. |
| [out] | wait_on_time_value | Value to use to enqueue wait on time in send queue. |
| DOCA_EXPERIMENTAL doca_error_t doca_eth_txq_cap_get_max_burst_size | ( | const struct doca_devinfo * | devinfo, |
| uint32_t | max_send_buf_list_len, | ||
| uint16_t | max_lso_header_size, | ||
| uint32_t * | max_burst_size | ||
| ) |
Get the maximum burst size supported by the device.
| [in] | devinfo | Pointer to doca_devinfo instance. |
| [in] | max_send_buf_list_len | Maximal send buffer list length to use in context. (check doca_eth_txq_set_max_send_buf_list_len) |
| [in] | max_lso_header_size | Maximum header size of an LSO packet to use in context. Can be 0 in case user isn't planning to use LSO tasks. |
| [out] | max_burst_size | The max burst size supported by the device. |
| DOCA_EXPERIMENTAL doca_error_t doca_eth_txq_cap_get_max_lso_header_size | ( | const struct doca_devinfo * | devinfo, |
| uint16_t * | max_lso_header_size | ||
| ) |
Get the maximum header size of an LSO packet supported by the device.
| [in] | devinfo | Pointer to doca_devinfo instance. |
| [out] | max_lso_header_size | Maximum header size of an LSO packet |
| DOCA_EXPERIMENTAL doca_error_t doca_eth_txq_cap_get_max_lso_msg_size | ( | const struct doca_devinfo * | devinfo, |
| uint32_t * | max_lso_msg_size | ||
| ) |
Get the max LSO message size by the network device.
| [in] | devinfo | Pointer to doca_devinfo instance. |
| [out] | max_lso_msg_size | Maximum LSO message supported. |
| DOCA_EXPERIMENTAL doca_error_t doca_eth_txq_cap_get_max_metadata_num | ( | const struct doca_devinfo * | devinfo, |
| uint8_t * | max_metadata_num | ||
| ) |
Get the maximum metadata number supported by the device.
| [in] | devinfo | Pointer to doca_devinfo instance. |
| [out] | max_metadata_num | Maximal metadata number to get. (check doca_eth_txq_set_metadata_num) |
| DOCA_EXPERIMENTAL doca_error_t doca_eth_txq_cap_get_max_send_buf_list_len | ( | const struct doca_devinfo * | devinfo, |
| uint32_t * | max_send_buf_list_len | ||
| ) |
Get the maximum send buffer list length supported by the device.
| [in] | devinfo | Pointer to doca_devinfo instance. |
| [out] | max_send_buf_list_len | Maximal send buffer list length to get. (check doca_eth_txq_set_max_send_buf_list_len) |
| DOCA_EXPERIMENTAL doca_error_t doca_eth_txq_cap_get_wait_on_time_offload_supported | ( | const struct doca_devinfo * | devinfo, |
| enum doca_eth_wait_on_time_type * | wait_on_time_mode | ||
| ) |
Check if wait on time offload is supported by the network device.
| [in] | devinfo | Pointer to doca_devinfo instance. |
| [out] | wait_on_time_mode | Offload wait on time mode (native or DPDK). |
| DOCA_EXPERIMENTAL doca_error_t doca_eth_txq_cap_is_l3_chksum_offload_supported | ( | const struct doca_devinfo * | devinfo | ) |
Check if L3 checksum offload is supported by the device.
| [in] | devinfo | Pointer to doca_devinfo instance. |
| DOCA_EXPERIMENTAL doca_error_t doca_eth_txq_cap_is_l4_chksum_offload_supported | ( | const struct doca_devinfo * | devinfo | ) |
Check if L4 checksum offload is supported by the device.
| [in] | devinfo | Pointer to doca_devinfo instance. |
| DOCA_EXPERIMENTAL doca_error_t doca_eth_txq_cap_is_type_supported | ( | const struct doca_devinfo * | devinfo, |
| enum doca_eth_txq_type | type, | ||
| enum doca_eth_txq_data_path_type | data_path_type | ||
| ) |
Check if TX queue type is supported.
| [in] | devinfo | Pointer to doca_devinfo instance. |
| [in] | type | TX queue type - see enum doca_eth_txq_type. |
| [in] | data_path_type | TX data-path type - see enum doca_eth_txq_data_path_type. |
| DOCA_EXPERIMENTAL doca_error_t doca_eth_txq_create | ( | struct doca_dev * | dev, |
| uint32_t | max_burst_size, | ||
| struct doca_eth_txq ** | eth_txq | ||
| ) |
Create a DOCA ETH TXQ instance.
| [in] | dev | Device to bind the context. |
| [in] | max_burst_size | Max burst size to use in context. |
| [out] | eth_txq | Pointer to pointer to be set to point to the created doca_eth_txq instance. |
| DOCA_EXPERIMENTAL doca_error_t doca_eth_txq_destroy | ( | struct doca_eth_txq * | eth_txq | ) |
Destroy a DOCA ETH TXQ instance.
| [in] | eth_txq | Pointer to instance to be destroyed. |
| DOCA_EXPERIMENTAL doca_error_t doca_eth_txq_get_flow_queue_id | ( | struct doca_eth_txq * | eth_txq, |
| uint16_t * | flow_queue_id | ||
| ) |
Get the DPDK queue ID of the doca_eth send queue. can only be called after calling doca_ctx_start().
| [in] | eth_txq | Pointer to doca_eth_txq instance. |
| [out] | flow_queue_id | The queue ID to be used in rte_flow or doca_flow. |
| DOCA_EXPERIMENTAL doca_error_t doca_eth_txq_get_gpu_handle | ( | const struct doca_eth_txq * | eth_txq, |
| struct doca_gpu_eth_txq ** | eth_txq_ext | ||
| ) |
Get a gpu handle of a doca_eth_txq.
This method should be used after ctx is started. The expected flow is as follows:
| [in] | eth_txq | Pointer to doca_eth_txq instance. |
| [out] | eth_txq_ext | A doca gpu eth_txq handle. |
| DOCA_EXPERIMENTAL doca_error_t doca_eth_txq_set_l3_chksum_offload | ( | struct doca_eth_txq * | eth_txq, |
| uint8_t | enable_l3_chksum | ||
| ) |
Set offload for the calculation of IPv4 checksum (L3) on transmitted packets. If the users enables L3 checksum offloading, then the HW will calculate the checksum value and write it into the specific field in the packet. This offload is enabled/disabled to every task / task_batch by default. User can change this by modifying the ol_flag value (See "enum doca_eth_txq_ol_flags"). can only be called before calling doca_ctx_start().
| [in] | eth_txq | Pointer to doca_eth_txq instance. |
| [in] | enable_l3_chksum | An indicator to enable/disable L3 checksum. |
| DOCA_EXPERIMENTAL doca_error_t doca_eth_txq_set_l4_chksum_offload | ( | struct doca_eth_txq * | eth_txq, |
| uint8_t | enable_l4_chksum | ||
| ) |
Set offload for the calculation of TCP/UDP checksum (L4) on transmitted packets. If the users enables L4 checksum offloading, then the HW will calculate the checksum value and write it into the specific field in the packet. This offload is enabled/disabled to every task / task_batch by default. User can change this by modifying the ol_flag value (See "enum doca_eth_txq_ol_flags"). can only be called before calling doca_ctx_start().
| [in] | eth_txq | Pointer to doca_eth_txq instance. |
| [in] | enable_l4_chksum | An indicator to enable/disable L4 checksum. |
| DOCA_EXPERIMENTAL doca_error_t doca_eth_txq_set_max_burst_size | ( | struct doca_eth_txq * | eth_txq, |
| uint32_t | max_burst_size | ||
| ) |
Set max burst size property for doca_eth_txq. This value dictates the maximal number of packets the HW can handle at the same time. can only be called before calling doca_ctx_start().
| [in] | eth_txq | Pointer to doca_eth_txq instance. |
| [in] | max_burst_size | Max burst size to use in context. |
| DOCA_EXPERIMENTAL doca_error_t doca_eth_txq_set_max_lso_header_size | ( | struct doca_eth_txq * | eth_txq, |
| uint16_t | max_lso_header_size | ||
| ) |
Set the maximum LSO header size for doca_eth_txq. This value is the maximum header size of the LSO packet can only be called before calling doca_ctx_start().
| [in] | eth_txq | Pointer to doca_eth_txq instance. |
| [in] | max_lso_header_size | Maximum LSO header size to use in context. |
| DOCA_EXPERIMENTAL doca_error_t doca_eth_txq_set_max_send_buf_list_len | ( | struct doca_eth_txq * | eth_txq, |
| uint32_t | max_send_buf_list_len | ||
| ) |
Set the maximal send buffer list length for doca_eth_txq. This value indicated what the maximal number of elements in a doca_buf list is. can only be called before calling doca_ctx_start().
| [in] | eth_txq | Pointer to doca_eth_txq instance. |
| [in] | max_send_buf_list_len | Maximal send buffer list length to use in context. |
| DOCA_EXPERIMENTAL doca_error_t doca_eth_txq_set_metadata_num | ( | struct doca_eth_txq * | eth_txq, |
| uint8_t | metadata_num | ||
| ) |
Set metadata number for doca_eth_txq. This value is the number of metadata per packet. can only be called before calling doca_ctx_start().
| [in] | eth_txq | Pointer to doca_eth_txq instance. |
| [in] | metadata_num | metadata number to use in context. |
| DOCA_EXPERIMENTAL doca_error_t doca_eth_txq_set_mss | ( | struct doca_eth_txq * | eth_txq, |
| uint16_t | mss | ||
| ) |
Set the Maximum Segment Size for doca_eth_txq. This value will be used per LSO send task / task_batch unless user overrides it (by setting MSS on the specific task / task_batch). This value is the maximum data size that can be sent in each segment of the LSO packet. can only be called before calling doca_ctx_start().
| [in] | eth_txq | Pointer to doca_eth_txq instance. |
| [in] | mss | Maximum Segment Size to use in context. |
| DOCA_EXPERIMENTAL doca_error_t doca_eth_txq_set_type | ( | struct doca_eth_txq * | eth_txq, |
| enum doca_eth_txq_type | type | ||
| ) |
Set TX queue type property for doca_eth_txq. can only be called before calling doca_ctx_start().
| [in] | eth_txq | Pointer to doca_eth_txq instance. |
| [in] | type | TX queue type - see enum doca_eth_txq_type. |
| DOCA_EXPERIMENTAL doca_error_t doca_eth_txq_set_wait_on_time_offload | ( | struct doca_eth_txq * | eth_txq | ) |
Set offload to enable wait on time feature on the queue. can only be called before calling doca_ctx_start().
| [in] | eth_txq | Pointer to doca_eth_txq instance. |