]> git.baikalelectronics.ru Git - kernel.git/commit
rtnetlink: Fix regression in bridge VLAN configuration
authorIdo Schimmel <idosch@nvidia.com>
Wed, 9 Jun 2021 11:17:53 +0000 (14:17 +0300)
committerDavid S. Miller <davem@davemloft.net>
Wed, 9 Jun 2021 21:58:26 +0000 (14:58 -0700)
commit3b86b61f8fadef70e4f918a331bd8621af41a3ce
treeac45c880b975c22644e94f9a9aed5e14c6e790b2
parent5b667bf5ae9b6db255d65faaad36df1af3b64994
rtnetlink: Fix regression in bridge VLAN configuration

Cited commit started returning errors when notification info is not
filled by the bridge driver, resulting in the following regression:

 # ip link add name br1 type bridge vlan_filtering 1
 # bridge vlan add dev br1 vid 555 self pvid untagged
 RTNETLINK answers: Invalid argument

As long as the bridge driver does not fill notification info for the
bridge device itself, an empty notification should not be considered as
an error. This is explained in commit 3ee8bf8ceb32 ("bridge: dont send
notification when skb->len == 0 in rtnl_bridge_notify").

Fix by removing the error and add a comment to avoid future bugs.

Fixes: 9dfd13134a0d ("rtnetlink: Fix missing error code in rtnl_bridge_notify()")
Signed-off-by: Ido Schimmel <idosch@nvidia.com>
Reviewed-by: Nikolay Aleksandrov <nikolay@nvidia.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
net/core/rtnetlink.c