* [PATCH RFC] linux: net: phy: realtek: changing LED behaviour for RTL8211F
@ 2023-02-09 9:44 Oliver Graute
2023-02-09 10:57 ` Simon Horman
0 siblings, 1 reply; 5+ messages in thread
From: Oliver Graute @ 2023-02-09 9:44 UTC (permalink / raw)
To: andrew
Cc: netdev, linux-kernel, Oliver Graute, Heiner Kallweit,
Russell King, David S. Miller, Eric Dumazet, Jakub Kicinski,
Paolo Abeni
This enable the LEDs for network activity and 100/1000Link for the RTL8211F
Signed-off-by: Oliver Graute <oliver.graute@kococonnector.com>
---
drivers/net/phy/realtek.c | 5 +++++
1 file changed, 5 insertions(+)
diff --git a/drivers/net/phy/realtek.c b/drivers/net/phy/realtek.c
index 3d99fd6664d7..5c796883cad3 100644
--- a/drivers/net/phy/realtek.c
+++ b/drivers/net/phy/realtek.c
@@ -416,6 +416,11 @@ static int rtl8211f_config_init(struct phy_device *phydev)
}
}
+ phy_write(phydev, RTL821x_PAGE_SELECT, 0xd04);
+ phy_write(phydev, 0x10, 0x15B);
+
+ phy_write(phydev, RTL821x_PAGE_SELECT, 0x0);
+
return genphy_soft_reset(phydev);
}
--
2.17.1
^ permalink raw reply related [flat|nested] 5+ messages in thread
* Re: [PATCH RFC] linux: net: phy: realtek: changing LED behaviour for RTL8211F
2023-02-09 9:44 [PATCH RFC] linux: net: phy: realtek: changing LED behaviour for RTL8211F Oliver Graute
@ 2023-02-09 10:57 ` Simon Horman
2023-02-09 12:39 ` Oliver Graute
0 siblings, 1 reply; 5+ messages in thread
From: Simon Horman @ 2023-02-09 10:57 UTC (permalink / raw)
To: Oliver Graute
Cc: andrew, netdev, linux-kernel, Heiner Kallweit, Russell King,
David S. Miller, Eric Dumazet, Jakub Kicinski, Paolo Abeni
On Thu, Feb 09, 2023 at 10:44:05AM +0100, Oliver Graute wrote:
> This enable the LEDs for network activity and 100/1000Link for the RTL8211F
>
> Signed-off-by: Oliver Graute <oliver.graute@kococonnector.com>
> ---
> drivers/net/phy/realtek.c | 5 +++++
> 1 file changed, 5 insertions(+)
>
> diff --git a/drivers/net/phy/realtek.c b/drivers/net/phy/realtek.c
> index 3d99fd6664d7..5c796883cad3 100644
> --- a/drivers/net/phy/realtek.c
> +++ b/drivers/net/phy/realtek.c
> @@ -416,6 +416,11 @@ static int rtl8211f_config_init(struct phy_device *phydev)
> }
> }
>
> + phy_write(phydev, RTL821x_PAGE_SELECT, 0xd04);
> + phy_write(phydev, 0x10, 0x15B);
> +
> + phy_write(phydev, RTL821x_PAGE_SELECT, 0x0);
> +
nit: it looks like the indentation in the new lines above should
be using a single tab rather than 8 spaces.
> return genphy_soft_reset(phydev);
> }
>
> --
> 2.17.1
>
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: [PATCH RFC] linux: net: phy: realtek: changing LED behaviour for RTL8211F
2023-02-09 10:57 ` Simon Horman
@ 2023-02-09 12:39 ` Oliver Graute
2023-02-09 13:30 ` Michael Walle
0 siblings, 1 reply; 5+ messages in thread
From: Oliver Graute @ 2023-02-09 12:39 UTC (permalink / raw)
To: Simon Horman
Cc: andrew, netdev, linux-kernel, Heiner Kallweit, Russell King,
David S. Miller, Eric Dumazet, Jakub Kicinski, Paolo Abeni
On 09/02/23, Simon Horman wrote:
> On Thu, Feb 09, 2023 at 10:44:05AM +0100, Oliver Graute wrote:
> > This enable the LEDs for network activity and 100/1000Link for the RTL8211F
> >
> > Signed-off-by: Oliver Graute <oliver.graute@kococonnector.com>
> > ---
> > drivers/net/phy/realtek.c | 5 +++++
> > 1 file changed, 5 insertions(+)
> >
> > diff --git a/drivers/net/phy/realtek.c b/drivers/net/phy/realtek.c
> > index 3d99fd6664d7..5c796883cad3 100644
> > --- a/drivers/net/phy/realtek.c
> > +++ b/drivers/net/phy/realtek.c
> > @@ -416,6 +416,11 @@ static int rtl8211f_config_init(struct phy_device *phydev)
> > }
> > }
> >
> > + phy_write(phydev, RTL821x_PAGE_SELECT, 0xd04);
> > + phy_write(phydev, 0x10, 0x15B);
> > +
> > + phy_write(phydev, RTL821x_PAGE_SELECT, 0x0);
> > +
>
> nit: it looks like the indentation in the new lines above should
> be using a single tab rather than 8 spaces.
thx, I will fix the indentation.
is this the right place to turn on the realtek phy LEDs for RTL8211F?
Best regards,
Oliver
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: [PATCH RFC] linux: net: phy: realtek: changing LED behaviour for RTL8211F
2023-02-09 12:39 ` Oliver Graute
@ 2023-02-09 13:30 ` Michael Walle
2023-02-09 14:20 ` Oliver Graute
0 siblings, 1 reply; 5+ messages in thread
From: Michael Walle @ 2023-02-09 13:30 UTC (permalink / raw)
To: oliver.graute
Cc: andrew, davem, edumazet, hkallweit1, kuba, linux-kernel, linux,
netdev, pabeni, simon.horman, Michael Walle
> is this the right place to turn on the realtek phy LEDs for RTL8211F?
Probably not. There are a few issues. This will only work one particular
board. Therefore, you'd need some kind of runtime configuration to also
support other boards. But lately any LED related patches for PHYs were
NAK'd because they need to integrate with the LED subsystem. See [1].
-michael
[1] https://lore.kernel.org/r/YyxOTKJ8OTxXgWcA@lunn.ch/
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: [PATCH RFC] linux: net: phy: realtek: changing LED behaviour for RTL8211F
2023-02-09 13:30 ` Michael Walle
@ 2023-02-09 14:20 ` Oliver Graute
0 siblings, 0 replies; 5+ messages in thread
From: Oliver Graute @ 2023-02-09 14:20 UTC (permalink / raw)
To: Michael Walle
Cc: andrew, davem, edumazet, hkallweit1, kuba, linux-kernel, linux,
netdev, pabeni, simon.horman
On 09/02/23, Michael Walle wrote:
> > is this the right place to turn on the realtek phy LEDs for RTL8211F?
>
> Probably not. There are a few issues. This will only work one particular
> board. Therefore, you'd need some kind of runtime configuration to also
> support other boards. But lately any LED related patches for PHYs were
> NAK'd because they need to integrate with the LED subsystem. See [1].
>
> -michael
>
> [1] https://lore.kernel.org/r/YyxOTKJ8OTxXgWcA@lunn.ch/
ok thx for this information.
Best Regards,
Oliver
^ permalink raw reply [flat|nested] 5+ messages in thread
end of thread, other threads:[~2023-02-09 14:20 UTC | newest]
Thread overview: 5+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2023-02-09 9:44 [PATCH RFC] linux: net: phy: realtek: changing LED behaviour for RTL8211F Oliver Graute
2023-02-09 10:57 ` Simon Horman
2023-02-09 12:39 ` Oliver Graute
2023-02-09 13:30 ` Michael Walle
2023-02-09 14:20 ` Oliver Graute
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).