]> git.baikalelectronics.ru Git - kernel.git/commit
phy: marvell: Fix and unify reg-init behavior
authorClemens Gruber <clemens.gruber@pqgruber.com>
Mon, 15 Feb 2016 22:46:45 +0000 (23:46 +0100)
committerDavid S. Miller <davem@davemloft.net>
Wed, 17 Feb 2016 21:20:40 +0000 (16:20 -0500)
commit53d4a9b16ea295c278c02891948a8a9355187a7e
tree9b00795238d8390e4ec3d0aef554de35f9790c9e
parentd723908195f751d513be616f89a8c05ec343e9e5
phy: marvell: Fix and unify reg-init behavior

For the Marvell 88E1510, marvell_of_reg_init was called too late, in the
config_aneg function.
Since commit 85a542251748 ("net: phy: turn carrier off on phy attach"),
this lead to the link not coming up at boot anymore, due to the phy
state machine being stuck at waiting for interrupts (off by default on
the 88E1510).
For seven other Marvell PHYs, marvell_of_reg_init was not called at all.

Add a generic marvell_config_init function, which in turn calls
marvell_of_reg_init.
PHYs, which already have a specific config_init function with a call to
marvell_of_reg_init, are left untouched. The generic marvell_config_init
function is called for all the others, to get consistent behavior across
all Marvell PHYs.

Fixes: 85a542251748 ("net: phy: turn carrier off on phy attach")
Signed-off-by: Clemens Gruber <clemens.gruber@pqgruber.com>
Reviewed-by: Andrew Lunn <andrew@lunn.ch>
Reviewed-by: Florian Fainelli <f.fainelli@gmail.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
drivers/net/phy/marvell.c