PcapPlusPlus
21.05
|
New callbacks for KNI device events. This structure MUST be used ONLY when KniDeviceList::callbackVersion returns KniDeviceList::KniCallbackVersion::CALLBACKS_NEW. Or if You are sure that DPDK version used is 17.11 or higher. If some callback is not provided (NULL) the request will always succeeds if other is not specified in callback description. More...
#include <KniDevice.h>
Public Attributes | |
int(* | change_mtu )(uint16_t port_id, unsigned int new_mtu) |
int(* | config_network_if )(uint16_t port_id, uint8_t if_up) |
int(* | config_mac_address )(uint16_t port_id, uint8_t mac_addr[]) |
int(* | config_promiscusity )(uint16_t port_id, uint8_t to_on) |
New callbacks for KNI device events. This structure MUST be used ONLY when KniDeviceList::callbackVersion returns KniDeviceList::KniCallbackVersion::CALLBACKS_NEW. Or if You are sure that DPDK version used is 17.11 or higher. If some callback is not provided (NULL) the request will always succeeds if other is not specified in callback description.
int(* pcpp::KniDevice::KniIoctlCallbacks::change_mtu) (uint16_t port_id, unsigned int new_mtu) |
Pointer to function of changing MTU. Must return 0 in case of success or negative error code
int(* pcpp::KniDevice::KniIoctlCallbacks::config_mac_address) (uint16_t port_id, uint8_t mac_addr[]) |
Pointer to function of configuring mac address. If callback is not provided and port_id of KNI device is not UINT16_MAX then DPDK will use predefined callback witch sets MAC address of DPDK port port_id via rte_eth_dev_default_mac_addr_set. Must return 0 in case of success or negative error code
int(* pcpp::KniDevice::KniIoctlCallbacks::config_network_if) (uint16_t port_id, uint8_t if_up) |
Pointer to function of configuring network interface. Must return 0 in case of success or negative error code
int(* pcpp::KniDevice::KniIoctlCallbacks::config_promiscusity) (uint16_t port_id, uint8_t to_on) |
Pointer to function of configuring promiscuous mode. If callback is not provided and port_id of KNI device is not UINT16_MAX then DPDK will use predefined callback witch sets promiscuous mode of DPDK port port_id via rte_eth_promiscuous_enable/rte_eth_promiscuous_disable. Must return 0 in case of success or negative error code