summaryrefslogtreecommitdiffstats
path: root/src/bp_sim.h
diff options
context:
space:
mode:
authorYaroslav Brustinov <ybrustin@cisco.com>2017-03-13 11:01:55 +0200
committerYaroslav Brustinov <ybrustin@cisco.com>2017-03-13 11:01:55 +0200
commitdbff547f4d9360d3c48c7b269255234cd31271df (patch)
tree1bbee86b5a4d9d54fa20140f96ea62b7474f8db2 /src/bp_sim.h
parentc8d1f318e2d322626e401c9599ba75006d2e8e6c (diff)
i40e fix of workaround of stuck counters + regression test
Change-Id: I251cb8d346461ccfa4eee8abfda113410160a602 Signed-off-by: Yaroslav Brustinov <ybrustin@cisco.com>
Diffstat (limited to 'src/bp_sim.h')
-rwxr-xr-xsrc/bp_sim.h10
1 files changed, 10 insertions, 0 deletions
diff --git a/src/bp_sim.h b/src/bp_sim.h
index 7346615a..24681d4b 100755
--- a/src/bp_sim.h
+++ b/src/bp_sim.h
@@ -775,6 +775,9 @@ public:
out_file = "";
prefix = "";
set_tw_bucket_time_in_usec(20.0);
+ // we read every 0.5 second. We want to catch the counter when it approach the maximum (where it will stuck,
+ // and we will start losing packets).
+ x710_fdir_reset_threshold = 0xffffffff - 1000000000/8/64*40;
}
CParserOption(){
@@ -819,6 +822,7 @@ public:
CMacAddrCfg m_mac_addr[TREX_MAX_PORTS];
double m_tw_bucket_time_sec;
double m_tw_bucket_time_sec_level1;
+ uint32_t x710_fdir_reset_threshold;
public:
uint8_t * get_src_mac_addr(int if_index){
@@ -857,6 +861,12 @@ public:
void set_rx_enabled() {
m_rx_thread_enabled = true;
}
+ uint32_t get_x710_fdir_reset_threshold() {
+ return (x710_fdir_reset_threshold);
+ }
+ void set_x710_fdir_reset_threshold(uint32_t val) {
+ x710_fdir_reset_threshold = val;
+ }
inline double get_tw_bucket_time_in_sec(void){
return (m_tw_bucket_time_sec);