MCPcopy Create free account
hub / github.com/F-Stack/f-stack / test_get_mempool

Function test_get_mempool

dpdk/app/test/sample_packet_forward.c:86–94  ·  view source on GitHub ↗

sample test to allocate the mempool */

Source from the content-addressed store, hash-verified

84
85/* sample test to allocate the mempool */
86int
87test_get_mempool(struct rte_mempool **mp, char *poolname)
88{
89 *mp = rte_pktmbuf_pool_create(poolname, NB_MBUF, 32, 0,
90 RTE_MBUF_DEFAULT_BUF_SIZE, rte_socket_id());
91 if (*mp == NULL)
92 return -1;
93 return 0;
94}
95
96/* sample test to allocate buffer for pkts */
97int

Callers 2

run_pdump_client_testsFunction · 0.85
test_get_mbuf_from_poolFunction · 0.85

Calls 2

rte_pktmbuf_pool_createFunction · 0.85
rte_socket_idFunction · 0.85

Tested by

no test coverage detected