8#ifndef DPDKLIBS_INCLUDE_DPDKLIBS_EALSETUP_HPP_
9#define DPDKLIBS_INCLUDE_DPDKLIBS_EALSETUP_HPP_
13#include <boost/program_options/parsers.hpp>
16#include <rte_ethdev.h>
24#define MBUF_CACHE_SIZE 250
31void iface_conf_rss_mode(
struct rte_eth_conf& iface_conf,
bool mode =
false,
bool offload =
false);
36int iface_init(uint16_t iface, uint16_t rx_rings, uint16_t tx_rings,
37 uint16_t rx_ring_size, uint16_t tx_ring_size,
38 std::map<
int, std::unique_ptr<rte_mempool>>& mbuf_pool,
39 bool with_reset=
false,
bool with_mq_rss=
false,
bool check_link_status=
false);
41std::unique_ptr<rte_mempool>
get_mempool(
const std::string& pool_name,
43 int data_room_size=9800,
int socket_id=0);
47void init_eal(
int argc,
const char* argv[]);
49void init_eal(
const std::vector<std::string>& args );
std::unique_ptr< rte_mempool > get_mempool(const std::string &pool_name, int num_mbufs=NUM_MBUFS, int mbuf_cache_size=MBUF_CACHE_SIZE, int data_room_size=9800, int socket_id=0)
int get_available_ifaces()
std::vector< const char * > construct_eal_argv(const std::vector< std::string > &std_argv)
void init_eal(int argc, const char *argv[])
static volatile uint8_t dpdk_quit_signal
void iface_conf_rss_mode(struct rte_eth_conf &iface_conf, bool mode=false, bool offload=false)
int iface_promiscuous_mode(std::uint16_t iface, bool mode=false)
std::string get_mac_addr_str(const rte_ether_addr &addr)
int iface_init(uint16_t iface, uint16_t rx_rings, uint16_t tx_rings, uint16_t rx_ring_size, uint16_t tx_ring_size, std::map< int, std::unique_ptr< rte_mempool > > &mbuf_pool, bool with_reset=false, bool with_mq_rss=false, bool check_link_status=false)