Re: [PATCH net v3 1/4] net: phy: as21xxx: handle stale link status during autoneg

From: netdev-bot+sashiko

Date: Fri Oct 30 2026 - 06:38:26 EST


Thank you for your contribution! Sashiko AI review found more severe
issue(s) in other patches of this series. This mail is only an FYI, in case
you want to address the nit picks below when you respin.

Low priority / nit picks for your consideration:

- [Low] The commit message for "net: phy: as21xxx: handle stale link
status during autoneg" says "MDIO_STAT1_ANEGCOMPLETE may be cleared…

--

net: phy: as21xxx: handle stale link status during autoneg

The patch makes as21xxx_read_link() record whether autonegotiation has
completed. If autoneg is enabled but not yet complete, it forces
phydev->link down, so a stale link up bit cannot be reported with an
unknown speed.

> When autonegotiation is restarted, MDIO_STAT1_ANEGCOMPLETE may be
> cleared before MDIO_STAT1_LSTATUS. In this case, the link status bit
> may still indicate link up even though autonegotiation has not
> completed.

[Severity: Low]
This isn't a bug, but MDIO_STAT1_ANEGCOMPLETE doesn't seem to exist
anywhere in the tree.

The code in as21xxx_read_link() tests a different macro:

phydev->autoneg_complete = !!(status & MDIO_AN_STAT1_COMPLETE);

That macro is defined in include/uapi/linux/mdio.h:

#define MDIO_AN_STAT1_COMPLETE BMSR_ANEGCOMPLETE

Could the commit message say MDIO_AN_STAT1_COMPLETE instead, so it matches
the code and the name can be found with grep?

--
Sashiko AI review · https://netdev-ai.bots.linux.dev/sashiko/#/patchset/20261028073024.25175-1-ansuelsmth%40gmail.com