Re: [PATCH] net: dsa: mv88e6xxx: Make *_c45 callbacks agree with phy_*_c45 callbacks

From: Andrew Lunn
Date: Tue Jan 16 2024 - 18:21:49 EST


> Hi Andrew,
>
> It bubbles up as EIO (the translation happens in get_phy_c45_ids when
> get_phy_c45_devs_in_pkg fails) and ultimately causes the probe to fail.
>
> The EIO causes the scan to stop and fail immediately - the way I read
> mdiobus_scan_bus_c45, only ENODEV is permissible.

O.K. At minimum, this should be added to the commit message.

However, i'm wondering if this is the correct fix. I would prefer that
the scan code just acts on the -EOPNOTSUPP the same was as
-ENODEV. Maybe the error code from phy_c45_probe_present() should be
returned as is. And mdiobus_scan_bus_c45() is extended to handle
-EOPNOTSUPP ?

Andrew