Re: [PATCH] net: mdiobus: Move all reset registration to `mdiobus_register_reset()`

From: Russell King (Oracle)
Date: Mon Aug 25 2025 - 10:54:59 EST


On Mon, Aug 25, 2025 at 04:39:12PM +0200, Csókás Bence wrote:
> Hi,
>
> On 2025. 08. 25. 16:16, Russell King (Oracle) wrote:
> > On Mon, Aug 25, 2025 at 04:09:34PM +0200, Bence Csókás wrote:
> > > Make `mdiobus_register_reset()` function handle both gpiod and
> > > reset-controller-based reset registration.
> >
> > The commit description should include not only _what_ is being done but
> > also _why_.
>
> Well, my question was, when I saw this part of code: why have it separate?
> Users shouldn't care whether a device uses gpiod or reset-controller when
> they call `mdio_device_reset()`, so why should they have to care here and
> call two separate register functions, one after another? In fact, the whole
> thing should be moved to mdio_device.c honestly. Along with the setting of
> mdiodev->reset_{,de}assert_delay.
>
> The end goal is fixing this "Can't read PHY ID because the PHY was never
> reset" bug that's been plaguing users for years.

I wasn't asking for an explanation in reply to my comment. I was
telling you that you had to do something to modify your commit message
to make your patch acceptable.

Now, I could nitpick your "because the PHY was never reset" - that's
untrue. The common problem is the PHY is _held_ in reset mode making
the PHY unresponsive on the MDIO bus.

If your goal is to fix this, then rather than submitting piecemeal
patches with no explanation, I suggest you work on the problem and
come up with a solution as a series of patches (with commit
descriptions that explain _what_ and _why_ changes are being made)
and submit it with a cover message explaining the overall issue
that is being addressed.

That means we can review the patch series as a whole rather than
being drip-fed individual patches, which is going to take a very
long time to make forward progress.

--
RMK's Patch system: https://www.armlinux.org.uk/developer/patches/
FTTP is here! 80Mbps down 10Mbps up. Decent connectivity at last!