diff --git a/vppcfg/_version.py b/vppcfg/_version.py index ca6b006..81b2935 100644 --- a/vppcfg/_version.py +++ b/vppcfg/_version.py @@ -1,3 +1,3 @@ """Version information for vppcfg.""" -__version__ = "1.1.1" +__version__ = "1.1.2" diff --git a/vppcfg/vpp/planner_sync.py b/vppcfg/vpp/planner_sync.py index 8aaf413..bf1a886 100644 --- a/vppcfg/vpp/planner_sync.py +++ b/vppcfg/vpp/planner_sync.py @@ -327,11 +327,14 @@ class PlannerSyncOperations(PlannerBase): # pylint: disable=too-few-public-meth """Synchronize the VPP Dataplane max frame size (link MTU), where 'shrink' determines the direction (if shrink is True, go from inner-most (QinQ) to outer-most (untagged), and the other direction if shrink is False""" + lcp_tap_sw_if_indexes = {lcp.host_sw_if_index for lcp in self.vpp.cache["lcps"].values()} for _idx, vpp_iface in self.vpp.cache["interfaces"].items(): if vpp_iface.sub_number_of_tags != 0: continue if vpp_iface.interface_dev_type in ["local", "Loopback", "VXLAN", "virtio"]: continue + if vpp_iface.sw_if_index in lcp_tap_sw_if_indexes: + continue _config_ifname, config_iface = interface.get_by_name( self.cfg, vpp_iface.interface_name diff --git a/vppcfg/vpp/vppapi.py b/vppcfg/vpp/vppapi.py index 02adf48..68e73c6 100644 --- a/vppcfg/vpp/vppapi.py +++ b/vppcfg/vpp/vppapi.py @@ -508,6 +508,7 @@ class VPPApi: def get_phys(self): """Return all interfaces for which the super interface has the same sw_if_index and aren't known to be virtual interfaces""" + lcp_tap_sw_if_indexes = {lcp.host_sw_if_index for lcp in self.cache["lcps"].values()} phys = [ self.cache["interfaces"][x].interface_name for x in self.cache["interfaces"] @@ -515,6 +516,7 @@ class VPPApi: == self.cache["interfaces"][x].sup_sw_if_index and self.cache["interfaces"][x].interface_dev_type not in ["virtio", "BVI", "Loopback", "VXLAN", "local", "bond"] + and self.cache["interfaces"][x].sw_if_index not in lcp_tap_sw_if_indexes ] return phys @@ -547,7 +549,7 @@ class VPPApi: or False otherwise.""" vpp_iface = self.get_interface_by_name(tap_ifname) - if not vpp_iface or not vpp_iface.interface_dev_type == "virtio": + if not vpp_iface: return False for _idx, lcp in self.cache["lcps"].items():