]> 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)
commit6e5fd57f3854e657547401b745c3d2637a78daea
tree0bcc2a84e87a32eba33e7f11ab7b932b722d8e2b
parentcefad5e79e8cfb8d4d1a3404e21f9087d660b9d9
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