]> git.ipfire.org Git - thirdparty/iproute2.git/commit
bridge: mdb: Add source VNI support
authorIdo Schimmel <idosch@nvidia.com>
Tue, 21 Mar 2023 13:01:25 +0000 (15:01 +0200)
committerDavid Ahern <dsahern@kernel.org>
Sat, 25 Mar 2023 00:29:46 +0000 (18:29 -0600)
commit9e49c798540c34e3df6d75e6871f4f69c1bb4e15
treee7a166975d45bb58ab98106e94169a2124a932fa
parentc5b327e5707b355fedaa8b721157d6043a07473b
bridge: mdb: Add source VNI support

In a similar fashion to VXLAN FDB entries, allow user space to program
and view the source VNI of VXLAN MDB entries. Specifically, add support
for the 'MDBE_ATTR_SRC_VNI' and 'MDBA_MDB_EATTR_SRC_VNI' attributes in
request and response messages, respectively.

The source VNI is only relevant when the VXLAN device is in external
mode, where multiple VNIs can be multiplexed over a single VXLAN device.

Example:

 # bridge mdb add dev vxlan0 port vxlan0 grp 239.1.1.1 permanent dst 198.51.100.1 src_vni 2222

 $ bridge -d -s mdb show
 dev vxlan0 port vxlan0 grp 239.1.1.1 permanent filter_mode exclude proto static dst 198.51.100.1 src_vni 2222    0.00

 $ bridge -d -s -j -p mdb show
 [ {
         "mdb": [ {
                 "index": 16,
                 "dev": "vxlan0",
                 "port": "vxlan0",
                 "grp": "239.1.1.1",
                 "state": "permanent",
                 "filter_mode": "exclude",
                 "protocol": "static",
                 "flags": [ ],
                 "dst": "198.51.100.1",
                 "src_vni": 2222,
                 "timer": "   0.00"
             } ],
         "router": {}
     } ]

Signed-off-by: Ido Schimmel <idosch@nvidia.com>
Reviewed-by: Nikolay Aleksandrov <razor@blackwall.org>
bridge/mdb.c
man/man8/bridge.8