mirror of
https://github.com/openvswitch/ovs
synced 2025-10-13 14:07:02 +00:00
vswitchd: Move config_ofproto_types call before bridge_add_port
Currently, the call to config_ofproto_types() happens at the end of bridge_reconfigure(), after missing ofprotos and ports are created. However, it might be usefull to make this call before adding missing ports through the dpif interface. With the current use case (dpif-netdev), this will save us a reconfiguration cycle. The call to config_ofproto_types() was introduced as a part of passing the Openvswitch other_config smap to dpif. However, if we want to do this before the ports are added, it needs to be done after ofproto_create() is called so that dpif_backer is added to all_dpif_backers list. Once the dpif_backer is added, the call to config_ofproto_types() will ensure that the set_config handler in dpif-netdev/netlink.c is called. Signed-off-by: Shashank Ram <rams@vmware.com> Signed-off-by: Daniele Di Proietto <diproiettod@vmware.com>
This commit is contained in:
committed by
Daniele Di Proietto
parent
33e36f1e3a
commit
83ede47a48
@@ -654,6 +654,9 @@ bridge_reconfigure(const struct ovsrec_open_vswitch *ovs_cfg)
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
config_ofproto_types(&ovs_cfg->other_config);
|
||||
|
||||
HMAP_FOR_EACH (br, node, &all_bridges) {
|
||||
bridge_add_ports(br, &br->wanted_ports);
|
||||
shash_destroy(&br->wanted_ports);
|
||||
@@ -706,8 +709,6 @@ bridge_reconfigure(const struct ovsrec_open_vswitch *ovs_cfg)
|
||||
}
|
||||
free(managers);
|
||||
|
||||
config_ofproto_types(&ovs_cfg->other_config);
|
||||
|
||||
/* The ofproto-dpif provider does some final reconfiguration in its
|
||||
* ->type_run() function. We have to call it before notifying the database
|
||||
* client that reconfiguration is complete, otherwise there is a very
|
||||
|
Reference in New Issue
Block a user