]> git.baikalelectronics.ru Git - kernel.git/commit
net: sparx5: Fix add vlan when invalid operation
authorCasper Andersson <casper.casan@gmail.com>
Fri, 25 Feb 2022 10:15:16 +0000 (11:15 +0100)
committerDavid S. Miller <davem@davemloft.net>
Fri, 25 Feb 2022 12:54:48 +0000 (12:54 +0000)
commitb3a34dc362c03215031b268fcc0b988e69490231
tree39d8918e9fef64857e5f006c322a3c44c581bc6e
parent767b9825ed1765894e569a3d698749d40d83762a
net: sparx5: Fix add vlan when invalid operation

Check if operation is valid before changing any
settings in hardware. Otherwise it results in
changes being made despite it not being a valid
operation.

Fixes: 78eab33bb68b ("net: sparx5: add vlan support")
Signed-off-by: Casper Andersson <casper.casan@gmail.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
drivers/net/ethernet/microchip/sparx5/sparx5_vlan.c