Lines Matching refs:bridge

122 	struct list uplink_port_list;	/* List of all uplinks to the bridge */
136 struct dpif_solaris_bridge *bridge;
408 struct dpif_solaris_bridge *bridge;
438 HMAP_FOR_EACH(bridge, node, &dpif->bridges) {
440 LIST_FOR_EACH(port, uplink_node, &bridge->uplink_port_list) {
645 struct dpif_solaris_bridge *bridge;
647 HMAP_FOR_EACH(bridge, node, &dpif->bridges) {
648 if (strcmp(bridge->name, brname) == 0) {
649 return (bridge);
661 struct dpif_solaris_bridge *bridge;
680 bridge = dpif_solaris_lookup_bridge(dpif, brname);
681 if (bridge == NULL) {
682 VLOG_DBG("dpif_solaris_bridge_add_port creating bridge %s",
684 bridge = xzalloc(sizeof (*bridge));
685 bridge->name = xstrdup(brname);
686 hmap_insert(&dpif->bridges, &bridge->node,
687 hash_string(bridge->name, 0));
688 hmap_init(&bridge->ports);
689 list_init(&bridge->uplink_port_list);
691 port->bridge = bridge;
692 hmap_insert(&bridge->ports, &port->brnode,
695 "bridge %s", port->name, port->port_no, brname);
698 VLOG_DBG("Insert port %s into bridge %s uplink_port_list",
699 port->name, bridge->name);
700 list_push_back(&bridge->uplink_port_list, &port->uplink_node);
703 return (bridge);
711 struct dpif_solaris_bridge *bridge = port->bridge;
714 if (bridge == NULL) {
716 "to a bridge", port->port_no);
720 port->port_no, bridge->name);
727 * is to remove the uplink port from bridge's uplink_port_list.
729 LIST_FOR_EACH(i_port, uplink_node, &bridge->uplink_port_list) {
733 "uplink %s from bridge's(%s) "
735 bridge->name);
741 hmap_remove(&bridge->ports, &port->brnode);
743 if (hmap_is_empty(&bridge->ports)) {
744 VLOG_DBG("dpif_solaris_bridge_del_port destroying bridge");
745 hmap_destroy(&bridge->ports);
746 hmap_remove(&dpif->bridges, &bridge->node);
747 free(bridge->name);
748 free(bridge);
2061 struct dpif_solaris_bridge *bridge;
2072 bridge = dpif_solaris_lookup_bridge(dpif, brname);
2073 if (bridge == NULL) {
2075 "locate bridge for %s", brname);
2081 * If bridge has no uplinks migrate bridge vnic to implicit etherstub.
2086 if (list_is_empty(&bridge->uplink_port_list)) {
2090 LIST_FOR_EACH(i_port, uplink_node, &bridge->uplink_port_list) {
2113 (&(bridge->uplink_port_list))->next,
2136 * Note that the internal port's name is the same as bridge name
2139 dpif_solaris_migrate_internal_port(const char *bridge, const char *physname)
2145 VLOG_DBG("dpif_solaris_migrate_internal_port port %s on %s", bridge,
2151 if (strcmp(port->name, bridge) != 0)
2160 " on %s succeed", bridge, physname);
2163 " on %s failed %d", bridge, physname, err);
2198 * added to the bridge yet, directly drop the packet.