Re: [PATCH net-next v3 6/8] net: phy: add calibration callbacks to phy_driver

From: Andrew Lunn
Date: Tue Nov 14 2023 - 14:14:56 EST


> +static inline
> +int phy_start_calibration(struct phy_device *phydev)
> +{
> + if (!(phydev->drv &&
> + phydev->drv->calibration_start &&
> + phydev->drv->calibration_stop))
> + return -EOPNOTSUPP;
> +
> + return phydev->drv->calibration_start(phydev);
> +}
> +
> +static inline
> +int phy_stop_calibration(struct phy_device *phydev)
> +{
> + if (!(phydev->drv &&
> + phydev->drv->calibration_stop))
> + return -EOPNOTSUPP;
> +
> + return phydev->drv->calibration_stop(phydev);
> +}
> +

What is the locking model?

Andrew