]> git.baikalelectronics.ru Git - kernel.git/commit
net: ethernet: mvneta: Fix Serdes configuration for SoCs without comphy
authorSascha Hauer <s.hauer@pengutronix.de>
Tue, 16 Jun 2020 08:31:39 +0000 (10:31 +0200)
committerDavid S. Miller <davem@davemloft.net>
Fri, 19 Jun 2020 02:59:49 +0000 (19:59 -0700)
commiteab544d2c6669ff8abf5a878f9cfb1dae1664b73
tree0bcc2a84e87a32eba33e7f11ab7b932b722d8e2b
parentaa6226e92328b6b336fc32ed0ac0f8d65308e963
net: ethernet: mvneta: Fix Serdes configuration for SoCs without comphy

The MVNETA_SERDES_CFG register is only available on older SoCs like the
Armada XP. On newer SoCs like the Armada 38x the fields are moved to
comphy. This patch moves the writes to this register next to the comphy
initialization, so that depending on the SoC either comphy or
MVNETA_SERDES_CFG is configured.
With this we no longer write to the MVNETA_SERDES_CFG on SoCs where it
doesn't exist.

Suggested-by: Russell King <rmk+kernel@armlinux.org.uk>
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
Signed-off-by: David S. Miller <davem@davemloft.net>
drivers/net/ethernet/marvell/mvneta.c