ofproto: Don't send OpenFlow flow expirations hidden rules.
authorJesse Gross <jesse@nicira.com>
Fri, 13 Nov 2009 01:41:58 +0000 (17:41 -0800)
committerJesse Gross <jesse@nicira.com>
Fri, 13 Nov 2009 20:44:03 +0000 (12:44 -0800)
We were reporting flow expirations for the hidden exact match flows
with the stats set to zero.  These are an implementation detail and
can confuse controllers, so don't report them.

CC: David Erickson <derickso@stanford.edu>
secchan/ofproto.c

index be1f5de600d51ab833ecc2806f7955d486543c08..a34120e803d040a41fe78cbb6bcce0cba61c2234 100644 (file)
@@ -3317,9 +3317,11 @@ expire_rule(struct cls_rule *cls_rule, void *p_)
         rule_uninstall(p, rule);
     }
 
-    send_flow_exp(p, rule, now,
-                  (now >= hard_expire
-                   ? OFPER_HARD_TIMEOUT : OFPER_IDLE_TIMEOUT));
+    if (!rule_is_hidden(rule)) {
+        send_flow_exp(p, rule, now,
+                      (now >= hard_expire
+                       ? OFPER_HARD_TIMEOUT : OFPER_IDLE_TIMEOUT));
+    }
     rule_remove(p, rule);
 }