]> git.proxmox.com Git - mirror_ubuntu-hirsute-kernel.git/commit
net: phy: micrel: add 125MHz reference clock workaround
authorMarkus Niebel <Markus.Niebel@tqs.de>
Tue, 15 May 2018 08:18:56 +0000 (10:18 +0200)
committerDavid S. Miller <davem@davemloft.net>
Wed, 16 May 2018 16:20:03 +0000 (12:20 -0400)
commite1b505a60366399d735312ca38b0a6753a684123
tree157dcbfa944715e317d33c5199e6ffe274124018
parent7f582b248d0a86bae5788c548d7bb5bca6f7691a
net: phy: micrel: add 125MHz reference clock workaround

The micrel KSZ9031 phy has a optional clock pin (CLK125_NDO) which can be
used as reference clock for the MAC unit. The clock signal must meet the
RGMII requirements to ensure the correct data transmission between the
MAC and the PHY. The KSZ9031 phy does not fulfill the duty cycle
requirement if the phy is configured as slave. For a complete
describtion look at the errata sheets: DS80000691D or DS80000692D.

The errata sheet recommends to force the phy into master mode whenever
there is a 1000Base-T link-up as work around. Only set the
"micrel,force-master" property if you use the phy reference clock provided
by CLK125_NDO pin as MAC reference clock in your application.

Attenation, this workaround is only usable if the link partner can
be configured to slave mode for 1000Base-T.

Signed-off-by: Markus Niebel <Markus.Niebel@tqs.de>
[m.felsch@pengutronix.de: fix dt-binding documentation]
[m.felsch@pengutronix.de: use already existing result var for read/write]
[m.felsch@pengutronix.de: add error handling]
[m.felsch@pengutronix.de: add more comments]
Signed-off-by: Marco Felsch <m.felsch@pengutronix.de>
Reviewed-by: Andrew Lunn <andrew@lunn.ch>
Signed-off-by: David S. Miller <davem@davemloft.net>
Documentation/devicetree/bindings/net/micrel-ksz90x1.txt
drivers/net/phy/micrel.c