summaryrefslogtreecommitdiffstats
path: root/drivers/atm
diff options
context:
space:
mode:
authorAlvin Šipraga <alsi@bang-olufsen.dk>2020-08-18 10:51:34 +0200
committerDavid S. Miller <davem@davemloft.net>2020-08-18 12:33:43 -0700
commit8b61fba503904acae24aeb2bd5569b4d6544d48f (patch)
treef8ec793ec2754ef16082d5e0161bb7bc784d7839 /drivers/atm
parent06a4ec1d9dc652e17ee3ac2ceb6c7cf6c2b75cdd (diff)
downloadlinux-stable-8b61fba503904acae24aeb2bd5569b4d6544d48f.tar.gz
linux-stable-8b61fba503904acae24aeb2bd5569b4d6544d48f.tar.bz2
linux-stable-8b61fba503904acae24aeb2bd5569b4d6544d48f.zip
macvlan: validate setting of multiple remote source MAC addresses
Remote source MAC addresses can be set on a 'source mode' macvlan interface via the IFLA_MACVLAN_MACADDR_DATA attribute. This commit tightens the validation of these MAC addresses to match the validation already performed when setting or adding a single MAC address via the IFLA_MACVLAN_MACADDR attribute. iproute2 uses IFLA_MACVLAN_MACADDR_DATA for its 'macvlan macaddr set' command, and IFLA_MACVLAN_MACADDR for its 'macvlan macaddr add' command, which demonstrates the inconsistent behaviour that this commit addresses: # ip link add link eth0 name macvlan0 type macvlan mode source # ip link set link dev macvlan0 type macvlan macaddr add 01:00:00:00:00:00 RTNETLINK answers: Cannot assign requested address # ip link set link dev macvlan0 type macvlan macaddr set 01:00:00:00:00:00 # ip -d link show macvlan0 5: macvlan0@eth0: <BROADCAST,MULTICAST,DYNAMIC,UP,LOWER_UP> mtu 1500 ... link/ether 2e:ac:fd:2d:69:f8 brd ff:ff:ff:ff:ff:ff promiscuity 0 macvlan mode source remotes (1) 01:00:00:00:00:00 numtxqueues 1 ... With this change, the 'set' command will (rightly) fail in the same way as the 'add' command. Signed-off-by: Alvin Šipraga <alsi@bang-olufsen.dk> Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'drivers/atm')
0 files changed, 0 insertions, 0 deletions