android_kernel_motorola_sm6375/drivers/phy
Repository files (latest commit first)
Filename Latest commit message Latest commit date
Russell King db2eabff57 phy: armada-38x: fix NETA lockup when repeatedly switching speeds
[ Upstream commit 1dea06cd643da38931382ebdc151efced201ffad ]

The mvneta hardware appears to lock up in various random ways when
repeatedly switching speeds between 1G and 2.5G, which involves
reprogramming the COMPHY.  It is not entirely clear why this happens,
but best guess is that reprogramming the COMPHY glitches mvneta clocks
causing the hardware to fail.  It seems that rebooting resolves the
failure, but not down/up cycling the interface alone.

Various other approaches have been tried, such as trying to cleanly
power down the COMPHY and then take it back through the power up
initialisation, but this does not seem to help.

It was finally noticed that u-boot's last step when configuring a
COMPHY for "SGMII" mode was to poke at a register described as
"GBE_CONFIGURATION_REG", which is undocumented in any external
documentation.  All that we have is the fact that u-boot sets a bit
corresponding to the "SGMII" lane at the end of COMPHY initialisation.

Experimentation shows that if we clear this bit prior to changing the
speed, and then set it afterwards, mvneta does not suffer this problem
on the SolidRun Clearfog when switching speeds between 1G and 2.5G.

This problem was found while script-testing phylink.

This fix also requires the corresponding change to DT to be effective.
See "ARM: dts: armada-38x: fix NETA lockup when repeatedly switching
speeds".

Fixes: 14dc100b44 ("phy: armada38x: add common phy support")
Signed-off-by: Russell King <rmk+kernel@armlinux.org.uk>
Reviewed-by: Andrew Lunn <andrew@lunn.ch>
Link: https://lore.kernel.org/r/E1jxtRj-0003Tz-CG@rmk-PC.armlinux.org.uk
Signed-off-by: Vinod Koul <vkoul@kernel.org>
Signed-off-by: Sasha Levin <sashal@kernel.org>
2020-08-19 08:16:14 +02:00
..
allwinner phy: sun4i-usb: fix dereference of pointer phy0 before it is null checked 2020-07-22 09:33:01 +02:00
amlogic
broadcom drivers: phy: sr-usb: do not use internal fsm for USB2 phy init 2020-06-24 17:50:28 +02:00
cadence
freescale
hisilicon
lantiq
marvell phy: armada-38x: fix NETA lockup when repeatedly switching speeds 2020-08-19 08:16:14 +02:00
mediatek
motorola phy: mapphone-mdm6600: Fix write timeouts with shorter GPIO toggle interval 2020-03-12 13:00:27 +01:00
mscc
qualcomm phy: qualcomm: Adjust indentation in read_poll_timeout 2020-02-11 04:35:45 -08:00
ralink
renesas phy: renesas: rcar-gen3-usb2: move irq registration to init 2020-08-19 08:16:13 +02:00
rockchip phy/rockchip: inno-hdmi: round clock rate down to closest 1000 Hz 2020-01-26 10:01:09 +01:00
samsung phy: exynos5-usbdrd: Calibrating makes sense only for USB2.0 PHY 2020-08-19 08:16:11 +02:00
socionext phy: uniphier-usb3ss: Add Pro5 support 2020-04-23 10:36:33 +02:00
st
tegra
ti phy: ti: gmii-sel: do not fail in case of gmii 2020-03-25 08:25:42 +01:00
Kconfig
Makefile
phy-core-mipi-dphy.c
phy-core.c
phy-lpc18xx-usb-otg.c
phy-pistachio-usb.c
phy-xgene.c