Subject: Re: [PATCH] net: phy: marvell-88q2xxx: Add support for PHY LEDs on 88q2xxx

From: Dimitri Fedrau <[email-masked]>
Date: Fri, 10 Jan 2025 19:40:58 +0100

Am Fri, Jan 10, 2025 at 06:52:15PM +0100 schrieb Andrew Lunn:
> > > +		if (index == MV88Q2XXX_LED_INDEX_TX_ENABLE)
> > > +			ret = phy_clear_bits_mmd(phydev, MDIO_MMD_PCS,
> > > +						 MDIO_MMD_PCS_MV_RESET_CTRL,
> > > +						 MDIO_MMD_PCS_MV_RESET_CTRL_TX_DISABLE);
> > 
> > If I understand it correctly, this switches the function of the pin from
> > TX_DISABLE to GPIO? Can you maybe add a comment here?
> 
> What is TX_DISABLE used for? I know it from SFPs, where it will
> disable the laser. But here we are talking about a T1 PHY.
> 

If pin input is LOW, then Tx packets will be stopped after link up, but Rx
packets are still received normally. The link will stay up and only idles
will be sent out the Tx media side.

> Do we have to be careful of use cases where the TX_DISABLE pin is
> being used for TX_DISABLE?

The pin can be used for feature described above(default) or as a LED. So
when the LED function should be used we have to setup DT otherwise we
are already fine.

Dimitri