Skip to contentSkip to conversation

net: phylink: fix function name in phylink_replay_link_end() kernel-doc

PATCH Applied Julius Bairaktaris 3 participants 3 messages Nov 29 – Dec 2

Subsystems (4)
lore
Share & tools
lore
#0 lore raw

PATCH 1/1 net: phylink: fix function name in phylink_replay_link_end() kernel-doc

The kernel-doc of phylink_replay_link_end() says that it must be called within the same rtnl_lock() critical section as a previous phylink_replay_link_start(). No such function exists. The helper that starts the replay is phylink_replay_link_begin(), and phylink_replay_link_end() warns when it is called without a prior phylink_replay_link_begin().

The wrong name came with commit 96969b132bf1 ("net: phylink: introduce helpers for replaying link callbacks").

---

Notes:
The kernel-doc of phylink_replay_link_begin() also names a pcs_link_down() method of the split PCS, which struct phylink_pcs_ops does not have. That sentence is left as it is: "net: phylink: add .pcs_link_down PCS OP" in the fwnode PCS series adds the op and calls it from phylink_link_down() [1].

Found by reading the code while porting OpenWrt to v7.4. I used Claude (Anthropic) to help write these patches.

[1] https://lore.kernel.org/netdev/[email protected]/

 drivers/net/phy/phylink.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
drivers/net/phy/phylink.c +1 -1
index d1f1142a98a..6f5af388210 100644
@@ -4648,7 +4648,7 @@ EXPORT_SYMBOL_GPL(phylink_replay_link_begin);
  * the phylib PHY.
  *
  * One must call this method only within the same rtnl_lock() critical section
- * as a previous phylink_replay_link_start().
+ * as a previous phylink_replay_link_begin().
  */
 void phylink_replay_link_end(struct phylink *pl)
 {

base-commit: f89726ffabef1b08c52e6163b7ab94b0d5f15503

Signature · 1 line
2.53.0
maintainer Reviewed-by on v1 1/1
#1 lore raw
Quoted 11 lines · Julius Bairaktaris

The kernel-doc of phylink_replay_link_end() says that it must be called within the same rtnl_lock() critical section as a previous phylink_replay_link_start(). No such function exists. The helper that starts the replay is phylink_replay_link_begin(), and phylink_replay_link_end() warns when it is called without a prior phylink_replay_link_begin().

The wrong name came with commit 96969b132bf1 ("net: phylink: introduce helpers for replaying link callbacks").

Andrew

#2 lore raw
In reply to Julius Bairaktaris
This patch was applied to netdev/net-next.git (main) by Willem de Bruijn <[email protected]>:

Hello:

This patch was applied to netdev/net-next.git (main) by Willem de Bruijn <[email protected]>:

Quoted 8 lines · On Sun, 29 Nov 2026 17:00:52 +0100 you wrote:

The kernel-doc of phylink_replay_link_end() says that it must be called within the same rtnl_lock() critical section as a previous phylink_replay_link_start(). No such function exists. The helper that starts the replay is phylink_replay_link_begin(), and phylink_replay_link_end() warns when it is called without a prior phylink_replay_link_begin().

[...]

Here is the summary with links:
- [net-next] net: phylink: fix function name in phylink_replay_link_end() kernel-doc

    https://git.kernel.org/netdev/net-next/c/4983929d45ec

You are awesome, thank you!

Signature · 2 lines
Deet-doot-dot, I am a bot.
https://korg.docs.kernel.org/patchwork/pwbot.html