]> git.proxmox.com Git - pve-common.git/commitdiff
network: support adding fdb directly in tap_plug
authorThomas Lamprecht <t.lamprecht@proxmox.com>
Sun, 20 Nov 2022 15:07:36 +0000 (16:07 +0100)
committerThomas Lamprecht <t.lamprecht@proxmox.com>
Sun, 20 Nov 2022 15:07:58 +0000 (16:07 +0100)
Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
src/PVE/Network.pm

index 33c610d71cfd860b99459d58e4fea6cec1b35edb..26d8cb14fc7d4e4573ccbd41a2d63637850777cb 100644 (file)
@@ -492,7 +492,10 @@ sub tap_plug {
        } else {
            &$bridge_add_interface($bridge, $iface, $tag, $trunks);
        }
-       $bridge_disable_interface_learning->($iface) if $no_learning;
+       if ($no_learning) {
+           $bridge_disable_interface_learning->($iface);
+           add_bridge_fdb($iface, $opts->{mac}) if defined($opts->{mac});
+       }
 
     } else {
        &$cleanup_firewall_bridge($iface); # remove stale devices