]> git.baikalelectronics.ru Git - kernel.git/commit
net: phy: at803x: select correct page on config init
authorDavid Bauer <mail@david-bauer.net>
Thu, 15 Apr 2021 01:26:50 +0000 (03:26 +0200)
committerDavid S. Miller <davem@davemloft.net>
Thu, 15 Apr 2021 23:49:32 +0000 (16:49 -0700)
commit9bf0222d424b355761a86b1920084888d6a6a603
tree399015a121b3e405ca225f1454b88f8e348bf065
parent13248525d89d8bc3773e9b9fff1d6101b149a1ff
net: phy: at803x: select correct page on config init

The Atheros AR8031 and AR8033 expose different registers for SGMII/Fiber
as well as the copper side of the PHY depending on the BT_BX_REG_SEL bit
in the chip configure register.

The driver assumes the copper side is selected on probe, but this might
not be the case depending which page was last selected by the
bootloader. Notably, Ubiquiti UniFi bootloaders show this behavior.

Select the copper page when probing to circumvent this.

Signed-off-by: David Bauer <mail@david-bauer.net>
Signed-off-by: David S. Miller <davem@davemloft.net>
drivers/net/phy/at803x.c