summaryrefslogtreecommitdiffstats
path: root/src/main_dpdk.h
diff options
context:
space:
mode:
Diffstat (limited to 'src/main_dpdk.h')
-rw-r--r--src/main_dpdk.h21
1 files changed, 12 insertions, 9 deletions
diff --git a/src/main_dpdk.h b/src/main_dpdk.h
index c2169eea..91618071 100644
--- a/src/main_dpdk.h
+++ b/src/main_dpdk.h
@@ -55,13 +55,7 @@ class CPhyEthIF {
m_port_id=0;
m_rx_queue=0;
}
- bool Create(uint8_t portid){
- m_port_id = portid;
- m_last_rx_rate = 0.0;
- m_last_tx_rate = 0.0;
- m_last_tx_pps = 0.0;
- return (true);
- }
+ bool Create(uint8_t portid);
void Delete();
void set_rx_queue(uint8_t rx_queue){
@@ -125,8 +119,10 @@ class CPhyEthIF {
}
void flush_dp_rx_queue(void);
void flush_rx_queue(void);
- int add_rx_flow_stat_rule(uint8_t type, uint16_t proto, uint16_t id);
- int del_rx_flow_stat_rule(uint8_t type, uint16_t proto, uint16_t id);
+ int add_rx_flow_stat_rule(uint8_t port_id, uint16_t l3_type, uint8_t l4_proto
+ , uint8_t ipv6_next_h, uint16_t id) const;
+ int del_rx_flow_stat_rule(uint8_t port_id, uint16_t l3_type, uint8_t l4_proto
+ , uint8_t ipv6_next_h, uint16_t id) const;
inline uint16_t tx_burst(uint16_t queue_id, struct rte_mbuf **tx_pkts, uint16_t nb_pkts) {
return rte_eth_tx_burst(m_port_id, queue_id, tx_pkts, nb_pkts);
}
@@ -154,6 +150,9 @@ class CPhyEthIF {
return m_port_id;
}
int get_rx_stat_capabilities();
+
+ const std::vector<std::pair<uint8_t, uint8_t>> & get_core_list();
+
private:
uint8_t m_port_id;
uint8_t m_rx_queue;
@@ -169,6 +168,10 @@ class CPhyEthIF {
float m_last_rx_rate;
float m_last_tx_pps;
float m_last_rx_pps;
+
+ /* holds the core ID list for this port - (core, dir) list*/
+ std::vector<std::pair<uint8_t, uint8_t>> m_core_id_list;
+
public:
struct rte_eth_dev_info m_dev_info;
};