diff options
-rw-r--r-- | ofproto/ofproto-dpif-upcall.c | 4 | ||||
-rw-r--r-- | ofproto/ofproto.c | 2 | ||||
-rw-r--r-- | vswitchd/vswitch.xml | 3 |
3 files changed, 7 insertions, 2 deletions
diff --git a/ofproto/ofproto-dpif-upcall.c b/ofproto/ofproto-dpif-upcall.c index ad9635496..442141ccd 100644 --- a/ofproto/ofproto-dpif-upcall.c +++ b/ofproto/ofproto-dpif-upcall.c @@ -2099,6 +2099,10 @@ should_revalidate(const struct udpif *udpif, uint64_t packets, { long long int metric, now, duration; + if (!ofproto_min_revalidate_pps) { + return true; + } + if (!used) { /* Always revalidate the first time a flow is dumped. */ return true; diff --git a/ofproto/ofproto.c b/ofproto/ofproto.c index 17f636ed9..e4a1bee76 100644 --- a/ofproto/ofproto.c +++ b/ofproto/ofproto.c @@ -724,7 +724,7 @@ ofproto_set_max_revalidator(unsigned max_revalidator) void ofproto_set_min_revalidate_pps(unsigned min_revalidate_pps) { - ofproto_min_revalidate_pps = min_revalidate_pps ? min_revalidate_pps : 1; + ofproto_min_revalidate_pps = min_revalidate_pps; } /* If forward_bpdu is true, the NORMAL action will forward frames with diff --git a/vswitchd/vswitch.xml b/vswitchd/vswitch.xml index 2b57fc0e3..64f23302d 100644 --- a/vswitchd/vswitch.xml +++ b/vswitchd/vswitch.xml @@ -205,10 +205,11 @@ </column> <column name="other_config" key="min-revalidate-pps" - type='{"type": "integer", "minInteger": 1}'> + type='{"type": "integer", "minInteger": 0}'> <p> Set minimum pps that flow must have in order to be revalidated when revalidation duration exceeds half of max-revalidator config variable. + Setting to 0 means always revalidate flows regardless of pps. </p> <p> The default is 5. |