summaryrefslogtreecommitdiff
path: root/Documentation/networking
diff options
context:
space:
mode:
authorVladimir Oltean <vladimir.oltean@nxp.com>2019-12-27 19:45:22 +0200
committerJason Liu <jason.hui.liu@nxp.com>2020-02-26 04:17:35 +0800
commit2e0c8d40ce87a800da9fda583b6a619fbe7d348a (patch)
tree2562698eaea17acae03dfd03d5b4e942cee1f29d /Documentation/networking
parentfd7c7eb42f1339efd15ae8a7aea267cb1aa2f2ca (diff)
net: phylink: add support for polling MAC PCS
Some MAC PCS blocks are unable to provide interrupts when their status changes. As we already have support in phylink for polling status, use this to provide a hook for MACs to enable polling mode. The patch idea was picked up from Russell King's suggestion on the macb phylink patch thread here [0] but the implementation was changed. Instead of introducing a new phylink_start_poll() function, which would make the implementation cumbersome for common PHYLINK implementations for multiple types of devices, like DSA, just add a boolean property to the phylink_config structure, which is just as backwards-compatible. https://lkml.org/lkml/2019/12/16/603 Suggested-by: Russell King <rmk+kernel@armlinux.org.uk> Signed-off-by: Vladimir Oltean <vladimir.oltean@nxp.com> Conflicts: drivers/net/phy/phylink.c with upstream commit 24cf0e693bb5 ("net: phylink: split link_an_mode configured and current settings") submitted for net-next and merged during v5.5-rc1. (cherry picked from commit ac7420c5ede06ebe049c6bce8ba9e9d7d3a51d11)
Diffstat (limited to 'Documentation/networking')
-rw-r--r--Documentation/networking/sfp-phylink.rst3
1 files changed, 2 insertions, 1 deletions
diff --git a/Documentation/networking/sfp-phylink.rst b/Documentation/networking/sfp-phylink.rst
index a5e00a159d21..d753a309f9d1 100644
--- a/Documentation/networking/sfp-phylink.rst
+++ b/Documentation/networking/sfp-phylink.rst
@@ -251,7 +251,8 @@ this documentation.
phylink_mac_change(priv->phylink, link_is_up);
where ``link_is_up`` is true if the link is currently up or false
- otherwise.
+ otherwise. If a MAC is unable to provide these interrupts, then
+ it should set ``priv->phylink_config.pcs_poll = true;`` in step 9.
11. Verify that the driver does not call::