]> git.baikalelectronics.ru Git - kernel.git/commit
net: dsa: bcm_sf2: Fix IMP setup for port different than 8
authorFlorian Fainelli <f.fainelli@gmail.com>
Thu, 31 Oct 2019 22:54:05 +0000 (15:54 -0700)
committerDavid S. Miller <davem@davemloft.net>
Fri, 1 Nov 2019 22:08:21 +0000 (15:08 -0700)
commitcd0da7a168e8bc190f5f9f123be0a307171a1d1a
treeef53f3d2d2a4894f656f182e6b6ac0f85e547490
parent6309a2a72f50adccafeb5d59c9bbafe322da87bb
net: dsa: bcm_sf2: Fix IMP setup for port different than 8

Since it became possible for the DSA core to use a CPU port different
than 8, our bcm_sf2_imp_setup() function was broken because it assumes
that registers are applicable to port 8. In particular, the port's MAC
is going to stay disabled, so make sure we clear the RX_DIS and TX_DIS
bits if we are not configured for port 8.

Fixes: 875ec329cfcf ("net: dsa: make "label" property optional for dsa2")
Signed-off-by: Florian Fainelli <f.fainelli@gmail.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
drivers/net/dsa/bcm_sf2.c