summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorTao Liu <thomas.liu@ucloud.cn>2022-06-30 16:34:05 +0800
committerIlya Maximets <i.maximets@ovn.org>2022-07-26 12:51:18 +0200
commitc6bd6cb06bb23bcc53bfb7c32587772b94d9f270 (patch)
tree39a416fba000da170161975cd1494d6f3f8daea3
parente9f25e020b862de65aba69e78d600b030f506042 (diff)
downloadopenvswitch-c6bd6cb06bb23bcc53bfb7c32587772b94d9f270.tar.gz
netdev-linux: Do not touch LAG members if master is not attached to OVS.
Bond master netdev may be created without a classification type, due to routing or tunneling code. If bond master is not attached to ovs, the ingress block on LAG members should not be updated. Simple reproducer: tc q ls dev net3 ingress ip a add 10.1.1.1/30 dev bond0 ip l set net3 master bond0 tc q ls dev net3 ingress Fixes: d22f8927c3c9 ("netdev-linux: monitor and offload LAG slaves to TC") Signed-off-by: Tao Liu <thomas.liu@ucloud.cn> Acked-by: Roi Dayan <roid@nvidia.com> Signed-off-by: Ilya Maximets <i.maximets@ovn.org>
-rw-r--r--lib/netdev-linux.c5
1 files changed, 4 insertions, 1 deletions
diff --git a/lib/netdev-linux.c b/lib/netdev-linux.c
index d1bd23e25..24b59d4d5 100644
--- a/lib/netdev-linux.c
+++ b/lib/netdev-linux.c
@@ -680,7 +680,10 @@ netdev_linux_update_lag(struct rtnetlink_change *change)
return;
}
- if (is_netdev_linux_class(master_netdev->netdev_class)) {
+ /* If LAG master is not attached to ovs, ingress block on LAG
+ * members shoud not be updated. */
+ if (!master_netdev->auto_classified &&
+ is_netdev_linux_class(master_netdev->netdev_class)) {
block_id = netdev_get_block_id(master_netdev);
if (!block_id) {
netdev_close(master_netdev);