]> git.ipfire.org Git - thirdparty/iproute2.git/commit
bridge: vlan: add support to filter by vlan id
authorNikolay Aleksandrov <nikolay@cumulusnetworks.com>
Mon, 11 Apr 2016 15:45:16 +0000 (17:45 +0200)
committerStephen Hemminger <stephen@networkplumber.org>
Mon, 11 Apr 2016 21:52:47 +0000 (21:52 +0000)
commit5a2d0201cce161617b30102d10b709fa24c6e833
treeee56a008b5b3be6e7f63322a0a77e766e6ddfed7
parent24687d678fd540c554f76dd43a06933ba1ca5c7d
bridge: vlan: add support to filter by vlan id

Add the optional keyword "vid" to bridge vlan show so the user can
request filtering by a specific vlan id. Currently the filtering is
implemented only in user-space. The argument name has been chosen to
match the add/del one - "vid". This filtering can be used also with the
"-compressvlans" option to see in which range is a vlan (if in any).
Also this will be used to show only specific per-vlan statistics later
when support is added to the kernel for it.

Examples:
$ bridge vlan show vid 450
port vlan ids
eth2  450

$ bridge -c vlan show vid 450
port vlan ids
eth2  400-500

$ bridge vlan show vid 1
port vlan ids
eth1  1 PVID Egress Untagged
eth2  1 PVID
br0  1 PVID Egress Untagged

Signed-off-by: Nikolay Aleksandrov <nikolay@cumulusnetworks.com>
bridge/vlan.c