26 #ifndef COMMON_DPDK_UTILS_H_
27 #define COMMON_DPDK_UTILS_H_
31 #include <sys/types.h>
43 #define RX_RING_SIZE 1024
44 #define TX_RING_SIZE 1024
45 #define NUM_MBUFS (8 * 1024)
46 #define MBUF_CACHE_SIZE 250
50 struct doca_buf_inventory;
139 struct doca_buf_inventory *inventory,
141 size_t mem_range_size,
142 struct doca_buf **out_buf);
160 void print_header_info(
const struct rte_mbuf *packet,
const bool l2,
const bool l3,
const bool l4);
void dpdk_mempool_shadow_destroy(struct dpdk_mempool_shadow *mempool_shadow)
doca_error_t dpdk_init(int argc, char **argv)
struct dpdk_mempool_shadow * dpdk_mempool_shadow_create_extbuf(const struct rte_pktmbuf_extmem **ext_mem, uint32_t ext_num, struct doca_dev *device)
doca_error_t dpdk_queues_and_ports_init(struct application_dpdk_config *app_dpdk_config)
void dpdk_queues_and_ports_fini(struct application_dpdk_config *app_dpdk_config)
doca_error_t dpdk_mempool_shadow_find_buf_by_data(struct dpdk_mempool_shadow *mempool_shadow, struct doca_buf_inventory *inventory, uintptr_t mem_range_start, size_t mem_range_size, struct doca_buf **out_buf)
struct dpdk_mempool_shadow * dpdk_mempool_shadow_create(struct rte_mempool *mbuf_pool, struct doca_dev *device)
void print_header_info(const struct rte_mbuf *packet, const bool l2, const bool l3, const bool l4)
enum doca_error doca_error_t
DOCA API return codes.
__UINTPTR_TYPE__ uintptr_t
struct rte_mempool * mbuf_pool
struct application_port_config port_config
uint16_t enable_mbuf_metadata