Message ID | 20240623194225.76667-1-marex@denx.de (mailing list archive) |
---|---|
State | Superseded |
Delegated to: | Netdev Maintainers |
Headers | show |
Series | [net-next] dt-bindings: net: realtek,rtl82xx: Document known PHY IDs as compatible strings | expand |
> - $ref: ethernet-phy.yaml# > > properties: > + compatible: > + enum: > + - ethernet-phy-id0000.8201 I'm not sure that one should be listed. It is not an official ID, since it does not have an OUI. In fact, this is one of the rare cases where actually listing a compatible in DT makes sense, because you can override the broken hardware and give a correct ID in realtek address space. Andrew
On 6/23/24 10:00 PM, Andrew Lunn wrote: >> - $ref: ethernet-phy.yaml# >> >> properties: >> + compatible: >> + enum: >> + - ethernet-phy-id0000.8201 > > I'm not sure that one should be listed. It is not an official ID, > since it does not have an OUI. In fact, this is one of the rare cases > where actually listing a compatible in DT makes sense, because you can > override the broken hardware and give a correct ID in realtek address > space. Hmmm, so, shall I drop this ID or keep it ? I generally put the PHY IDs into DT so the PHY drivers can correctly handle clock and reset sequencing for those PHYs, before the PHY ID registers can be read out of the PHY.
On Mon, Jun 24, 2024 at 01:52:49AM +0200, Marek Vasut wrote: > On 6/23/24 10:00 PM, Andrew Lunn wrote: > > > - $ref: ethernet-phy.yaml# > > > properties: > > > + compatible: > > > + enum: > > > + - ethernet-phy-id0000.8201 > > > > I'm not sure that one should be listed. It is not an official ID, > > since it does not have an OUI. In fact, this is one of the rare cases > > where actually listing a compatible in DT makes sense, because you can > > override the broken hardware and give a correct ID in realtek address > > space. > > Hmmm, so, shall I drop this ID or keep it ? > > I generally put the PHY IDs into DT so the PHY drivers can correctly handle > clock and reset sequencing for those PHYs, before the PHY ID registers can > be read out of the PHY. Are there any in kernel .dts files using it? We could add it, if it is needed to keep the DT validation tools are happy. But we should also be deprecating this compatible, replacing it with one allocated from realteks range. Andrew
On 6/24/24 3:52 PM, Andrew Lunn wrote: > On Mon, Jun 24, 2024 at 01:52:49AM +0200, Marek Vasut wrote: >> On 6/23/24 10:00 PM, Andrew Lunn wrote: >>>> - $ref: ethernet-phy.yaml# >>>> properties: >>>> + compatible: >>>> + enum: >>>> + - ethernet-phy-id0000.8201 >>> >>> I'm not sure that one should be listed. It is not an official ID, >>> since it does not have an OUI. In fact, this is one of the rare cases >>> where actually listing a compatible in DT makes sense, because you can >>> override the broken hardware and give a correct ID in realtek address >>> space. >> >> Hmmm, so, shall I drop this ID or keep it ? >> >> I generally put the PHY IDs into DT so the PHY drivers can correctly handle >> clock and reset sequencing for those PHYs, before the PHY ID registers can >> be read out of the PHY. > > Are there any in kernel .dts files using it? git grep ethernet-phy-id0000.8201 on current next-20240624 says no. > We could add it, if it is > needed to keep the DT validation tools are happy. But we should also > be deprecating this compatible, replacing it with one allocated from > realteks range. I think we should drop from the bindings after all, I will prepare a V2 like that, OK ?
> git grep ethernet-phy-id0000.8201 on current next-20240624 says no. > > > We could add it, if it is > > needed to keep the DT validation tools are happy. But we should also > > be deprecating this compatible, replacing it with one allocated from > > realteks range. > > I think we should drop from the bindings after all, I will prepare a V2 like > that, OK ? Yes, please drop it. Andrew
On 6/25/24 3:17 PM, Andrew Lunn wrote: >> git grep ethernet-phy-id0000.8201 on current next-20240624 says no. >> >>> We could add it, if it is >>> needed to keep the DT validation tools are happy. But we should also >>> be deprecating this compatible, replacing it with one allocated from >>> realteks range. >> >> I think we should drop from the bindings after all, I will prepare a V2 like >> that, OK ? > > Yes, please drop it. Done in V2, thanks.
diff --git a/Documentation/devicetree/bindings/net/realtek,rtl82xx.yaml b/Documentation/devicetree/bindings/net/realtek,rtl82xx.yaml index bb94a2388520b..8db4d66f1a961 100644 --- a/Documentation/devicetree/bindings/net/realtek,rtl82xx.yaml +++ b/Documentation/devicetree/bindings/net/realtek,rtl82xx.yaml @@ -18,6 +18,30 @@ allOf: - $ref: ethernet-phy.yaml# properties: + compatible: + enum: + - ethernet-phy-id0000.8201 + - ethernet-phy-id001c.c800 + - ethernet-phy-id001c.c816 + - ethernet-phy-id001c.c838 + - ethernet-phy-id001c.c840 + - ethernet-phy-id001c.c848 + - ethernet-phy-id001c.c849 + - ethernet-phy-id001c.c84a + - ethernet-phy-id001c.c862 + - ethernet-phy-id001c.c878 + - ethernet-phy-id001c.c880 + - ethernet-phy-id001c.c910 + - ethernet-phy-id001c.c912 + - ethernet-phy-id001c.c913 + - ethernet-phy-id001c.c914 + - ethernet-phy-id001c.c915 + - ethernet-phy-id001c.c916 + - ethernet-phy-id001c.c942 + - ethernet-phy-id001c.c961 + - ethernet-phy-id001c.cad0 + - ethernet-phy-id001c.cb00 + realtek,clkout-disable: type: boolean description:
Extract known PHY IDs from Linux kernel realtek PHY driver and convert them into supported compatible string list for this DT binding document. Signed-off-by: Marek Vasut <marex@denx.de> --- Cc: Andrew Lunn <andrew@lunn.ch> Cc: Conor Dooley <conor+dt@kernel.org> Cc: David S. Miller <davem@davemloft.net> Cc: Eric Dumazet <edumazet@google.com> Cc: Florian Fainelli <f.fainelli@gmail.com> Cc: Heiner Kallweit <hkallweit1@gmail.com> Cc: Jakub Kicinski <kuba@kernel.org> Cc: Joakim Zhang <qiangqing.zhang@nxp.com> Cc: Krzysztof Kozlowski <krzk+dt@kernel.org> Cc: Paolo Abeni <pabeni@redhat.com> Cc: Rob Herring <robh@kernel.org> Cc: devicetree@vger.kernel.org Cc: kernel@dh-electronics.com Cc: netdev@vger.kernel.org --- .../bindings/net/realtek,rtl82xx.yaml | 24 +++++++++++++++++++ 1 file changed, 24 insertions(+)