]> git.baikalelectronics.ru Git - kernel.git/commit
net: phy: marvell: Fix MDI-x polarity setting in 88e1118-compatible PHYs
authorBaikal Electronics <support@baikalelectronics.ru>
Sat, 5 Feb 2022 21:49:51 +0000 (00:49 +0300)
committerDavid S. Miller <davem@davemloft.net>
Sun, 6 Feb 2022 11:06:44 +0000 (11:06 +0000)
commit60fefbf0a3315549498d03fd3f930896057bfd2b
tree4c3ad9e805576f2e82f45174b206f98d41582fb0
parentf9d7fa94ec65438af00df0c0460ab2ac9586684c
net: phy: marvell: Fix MDI-x polarity setting in 88e1118-compatible PHYs

When setting up autonegotiation for 88E1118R and compatible PHYs,
a software reset of PHY is issued before setting up polarity.
This is incorrect as changes of MDI Crossover Mode bits are
disruptive to the normal operation and must be followed by a
software reset to take effect. Let's patch m88e1118_config_aneg()
to fix the issue mentioned before by invoking software reset
of the PHY just after setting up MDI-x polarity.

Fixes: cda7eded3d00 ("phy: Add support for Marvell 88E1118 PHY")
Signed-off-by: Pavel Parkhomenko <Pavel.Parkhomenko@baikalelectronics.ru>
Reviewed-by: Serge Semin <fancer.lancer@gmail.com>
Suggested-by: Andrew Lunn <andrew@lunn.ch>
Cc: stable@vger.kernel.org
Reviewed-by: Andrew Lunn <andrew@lunn.ch>
Signed-off-by: David S. Miller <davem@davemloft.net>
drivers/net/phy/marvell.c