In fail-open mode on disconnect from controller rules are flushed. It makes
sense to flush groups and meters as well. Signed-off-by: Gur Stavi <gur.st...@gmail.com> <gst...@mrv.com> --- Original issue was discussed here: https://www.mail-archive.com/discuss@openvswitch.org/msg10930.html Resending to avoid email client auto signature. Index: ofproto/ofproto.c =================================================================== --- ofproto/ofproto.c +++ ofproto/ofproto.c @@ -1276,6 +1276,8 @@ ovs_mutex_unlock(&ofproto_mutex); } +static void delete_group(struct ofproto *ofproto, uint32_t group_id); + static void ofproto_flush__(struct ofproto *ofproto) OVS_EXCLUDED(ofproto_mutex) @@ -1305,10 +1307,18 @@ } } ovs_mutex_unlock(&ofproto_mutex); + + /* Flush groups */ + delete_group(ofproto, OFPG_ALL); + + /* Flush meters */ + ovs_mutex_lock(&ofproto_mutex); + if (ofproto->meters) { + meter_delete(ofproto, 1, ofproto->meter_features.max_meters); + } + ovs_mutex_unlock(&ofproto_mutex); } -static void delete_group(struct ofproto *ofproto, uint32_t group_id); - static void ofproto_destroy__(struct ofproto *ofproto) OVS_EXCLUDED(ofproto_mutex) _______________________________________________ dev mailing list dev@openvswitch.org http://openvswitch.org/mailman/listinfo/dev