From c919ccd485060ec0511dda559c220f81b790c41c Mon Sep 17 00:00:00 2001 From: elajkat Date: Tue, 1 Feb 2022 11:50:51 +0100 Subject: [PATCH] Use ovs TUNNEL_ constants from new location [0] rehomed some ovs related constants to separate module, use the new location in taas as well. [0]: https://review.opendev.org/c/openstack/neutron-lib/+/822131 Change-Id: I346eaabff3c4869429c827c8955d41b621f82304 --- .../services/taas/drivers/linux/ovs_taas.py | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) diff --git a/neutron_taas/services/taas/drivers/linux/ovs_taas.py b/neutron_taas/services/taas/drivers/linux/ovs_taas.py index 6ffb5858..52b8cdd2 100644 --- a/neutron_taas/services/taas/drivers/linux/ovs_taas.py +++ b/neutron_taas/services/taas/drivers/linux/ovs_taas.py @@ -17,7 +17,7 @@ from neutron.agent.common import ovs_lib from neutron.agent.linux import utils from neutron.conf.agent import common -from neutron_lib import constants as n_consts +from neutron_lib.plugins.ml2 import ovs_constants as n_ovs_consts from neutron_taas.services.taas.agents.extensions import taas as taas_base import neutron_taas.services.taas.drivers.linux.ovs_constants \ @@ -236,8 +236,8 @@ class OvsTaasDriver(taas_base.TaasAgentDriver): actions="output:%s" % str(patch_tap_int_id)) # Add flow(s) in br-tun - for tunnel_type in n_consts.TUNNEL_NETWORK_TYPES: - self.tun_br.add_flow(table=n_consts.TUN_TABLE[tunnel_type], + for tunnel_type in n_ovs_consts.TUNNEL_NETWORK_TYPES: + self.tun_br.add_flow(table=n_ovs_consts.TUN_TABLE[tunnel_type], priority=1, tun_id=taas_id, actions=( @@ -294,8 +294,8 @@ class OvsTaasDriver(taas_base.TaasAgentDriver): dl_vlan=taas_id) # Delete flow(s) from br-tun - for tunnel_type in n_consts.TUNNEL_NETWORK_TYPES: - self.tun_br.delete_flows(table=n_consts.TUN_TABLE[tunnel_type], + for tunnel_type in n_ovs_consts.TUNNEL_NETWORK_TYPES: + self.tun_br.delete_flows(table=n_ovs_consts.TUN_TABLE[tunnel_type], tun_id=taas_id) self.tun_br.delete_flows(table=taas_ovs_consts.TAAS_DST_CHECK, @@ -363,8 +363,8 @@ class OvsTaasDriver(taas_base.TaasAgentDriver): # patch_int_tap_id) # Add flow(s) in br-tun - for tunnel_type in n_consts.TUNNEL_NETWORK_TYPES: - self.tun_br.add_flow(table=n_consts.TUN_TABLE[tunnel_type], + for tunnel_type in n_ovs_consts.TUNNEL_NETWORK_TYPES: + self.tun_br.add_flow(table=n_ovs_consts.TUN_TABLE[tunnel_type], priority=1, tun_id=taas_id, actions=(