Re: [PATCH net-next v3 11/14] net: phy: ncn26000: Support for loopback support

From: Andrew Lunn

Date: Sun May 31 2026 - 11:37:15 EST


> +static int ncn26000_loopback(struct phy_device *phydev, bool enable,
> + int speed)
> +{
> + u16 mask = BMCR_LOOPBACK;
> + u16 ctl = 0;
> +
> + if (enable)
> + ctl = BMCR_LOOPBACK;
> + return phy_modify(phydev, MII_BMCR, mask, ctl);
> +}

dp83867_loopback().

There is already genphy_loopback(), so it will need a name to indicate
the speed does not matter, because only one speed is supported etc.

Andrew