Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux
1
fork

Configure Feed

Select the types of activity you want to include in your feed.

net: phylink: expand on .pcs_config() method documentation

Expand on the requirements of the .pcs_config() method documentation,
specifically mentioning that it should cause minimal disruption to
an established link, and that it should return a positive non-zero
value when requiring the .pcs_an_restart() method to be called.

Signed-off-by: Russell King (Oracle) <rmk+kernel@armlinux.org.uk>
Link: https://patch.msgid.link/E1trb24-005oVq-Is@rmk-PC.armlinux.org.uk
Signed-off-by: Paolo Abeni <pabeni@redhat.com>

authored by

Russell King (Oracle) and committed by
Paolo Abeni
35b862ea a07f23ad

+8
+8
include/linux/phylink.h
··· 595 595 * The %neg_mode argument should be tested via the phylink_mode_*() family of 596 596 * functions, or for PCS that set pcs->neg_mode true, should be tested 597 597 * against the PHYLINK_PCS_NEG_* definitions. 598 + * 599 + * pcs_config() will be called when configuration of the PCS is required 600 + * or when the advertisement is possibly updated. It must not unnecessarily 601 + * disrupt an established link. 602 + * 603 + * When an autonegotiation restart is required for 802.3z modes, .pcs_config() 604 + * should return a positive non-zero integer (e.g. 1) to indicate to phylink 605 + * to call the pcs_an_restart() method. 598 606 */ 599 607 int pcs_config(struct phylink_pcs *pcs, unsigned int neg_mode, 600 608 phy_interface_t interface, const unsigned long *advertising,