X-Git-Url: https://pintos-os.org/cgi-bin/gitweb.cgi?a=blobdiff_plain;f=vswitchd%2Fbridge.c;h=96e4cf1a47db4ceabeac5bfabf100e61b8997bf2;hb=72c3b44800c5b25d5399b05e1bc6aece44414f49;hp=b57860f94485e3ebb1869da6029f41f46f2a7bfc;hpb=a58727fb4007caf91d6eb615a123f161e4f4b9af;p=openvswitch diff --git a/vswitchd/bridge.c b/vswitchd/bridge.c index b57860f9..96e4cf1a 100644 --- a/vswitchd/bridge.c +++ b/vswitchd/bridge.c @@ -1220,55 +1220,6 @@ iface_refresh_cfm_stats(struct iface *iface) ovsrec_maintenance_point_set_fault(mp, &rmp->fault, 1); } - if (hmap_is_empty(&cfm->x_remote_mps)) { - ovsrec_monitor_set_unexpected_remote_mpids(mon, NULL, 0); - } else { - size_t length; - struct remote_mp *rmp; - int64_t *x_remote_mps; - - length = hmap_count(&cfm->x_remote_mps); - x_remote_mps = xzalloc(length * sizeof *x_remote_mps); - - i = 0; - HMAP_FOR_EACH (rmp, node, &cfm->x_remote_mps) { - x_remote_mps[i++] = rmp->mpid; - } - - ovsrec_monitor_set_unexpected_remote_mpids(mon, x_remote_mps, length); - free(x_remote_mps); - } - - if (hmap_is_empty(&cfm->x_remote_maids)) { - ovsrec_monitor_set_unexpected_remote_maids(mon, NULL, 0); - } else { - size_t length; - char **x_remote_maids; - struct remote_maid *rmaid; - - length = hmap_count(&cfm->x_remote_maids); - x_remote_maids = xzalloc(length * sizeof *x_remote_maids); - - i = 0; - HMAP_FOR_EACH (rmaid, node, &cfm->x_remote_maids) { - size_t j; - - x_remote_maids[i] = xzalloc(CCM_MAID_LEN * 2 + 1); - - for (j = 0; j < CCM_MAID_LEN; j++) { - snprintf(&x_remote_maids[i][j * 2], 3, "%02hhx", - rmaid->maid[j]); - } - i++; - } - ovsrec_monitor_set_unexpected_remote_maids(mon, x_remote_maids, length); - - for (i = 0; i < length; i++) { - free(x_remote_maids[i]); - } - free(x_remote_maids); - } - ovsrec_monitor_set_fault(mon, &cfm->fault, 1); }