]> git.baikalelectronics.ru Git - kernel.git/commit
net: phy: adin: implement downshift configuration via phy-tunable
authorAlexandru Ardelean <alexandru.ardelean@analog.com>
Fri, 16 Aug 2019 13:10:09 +0000 (16:10 +0300)
committerDavid S. Miller <davem@davemloft.net>
Fri, 16 Aug 2019 18:56:26 +0000 (11:56 -0700)
commitb708817e4aba2245cd143717395e7118de4721fd
tree7547f49eede8582e43e0f28c76cf5a2bd5a397df
parentfe747b173f4d8ab621383b676dfb5ba77bd83de6
net: phy: adin: implement downshift configuration via phy-tunable

Down-speed auto-negotiation may not always be enabled, in which case the
PHY won't down-shift to 100 or 10 during auto-negotiation.

This change enables downshift and configures the number of retries to
default 4 (which is also in the datasheet

The downshift control mechanism can also be controlled via the phy-tunable
interface (ETHTOOL_PHY_DOWNSHIFT control).

The change has been adapted from the Aquantia PHY driver.

Reviewed-by: Florian Fainelli <f.fainelli@gmail.com>
Reviewed-by: Andrew Lunn <andrew@lunn.ch>
Signed-off-by: Alexandru Ardelean <alexandru.ardelean@analog.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
drivers/net/phy/adin.c