diff options
author | Vivien Didelot <vivien.didelot@gmail.com> | 2019-08-09 18:47:53 -0400 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2019-08-11 21:27:15 -0700 |
commit | 929938536fc0b1628fec8aff62a756e1c4f506d2 (patch) | |
tree | df1c0729d74c4d3902448025cf95ec840261f496 /drivers/net/dsa | |
parent | eb2e7f092271091f774a20c0c3b8df3c8c52e060 (diff) | |
download | linux-929938536fc0b1628fec8aff62a756e1c4f506d2.tar.bz2 |
net: dsa: mv88e6xxx: wait for 88E6185 PPU disabled
The PPU state of 88E6185 can be either "Disabled at Reset" or
"Disabled after Initialization". Because we intentionally clear the
PPU Enabled bit before checking its state, it is safe to wait for the
MV88E6185_G1_STS_PPU_STATE_DISABLED state explicitly instead of waiting
for any state different than MV88E6185_G1_STS_PPU_STATE_POLLING.
Signed-off-by: Vivien Didelot <vivien.didelot@gmail.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'drivers/net/dsa')
-rw-r--r-- | drivers/net/dsa/mv88e6xxx/global1.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/net/dsa/mv88e6xxx/global1.c b/drivers/net/dsa/mv88e6xxx/global1.c index 1323ef30a5e9..bbd31c9f8b48 100644 --- a/drivers/net/dsa/mv88e6xxx/global1.c +++ b/drivers/net/dsa/mv88e6xxx/global1.c @@ -46,7 +46,7 @@ static int mv88e6185_g1_wait_ppu_disabled(struct mv88e6xxx_chip *chip) /* Check the value of the PPUState bits 15:14 */ state &= MV88E6185_G1_STS_PPU_STATE_MASK; - if (state != MV88E6185_G1_STS_PPU_STATE_POLLING) + if (state == MV88E6185_G1_STS_PPU_STATE_DISABLED) return 0; usleep_range(1000, 2000); |