Re: [net-next RFC PATCH 03/14] dt-bindings: net: document ethernet PHY package nodes

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Mon, Nov 20, 2023 at 10:25:10PM +0100, Andrew Lunn wrote:
> > A real DT that use this is (ipq807x):
> > 
> > &mdio {
> > 	status = "okay";
> > 	pinctrl-0 = <&mdio_pins>;
> > 	pinctrl-names = "default";
> > 	reset-gpios = <&tlmm 37 GPIO_ACTIVE_LOW>;
> > 
> > 	ethernet-phy-package {
> > 		compatible = "ethernet-phy-package";
> > 		phy-mode = "psgmii";
> > 
> > 		global-phys = <&qca8075_4>, <&qca8075_psgmii>;
> > 		global-phy-names = "combo", "analog_psgmii";
> > 
> > 		qca8075_0: ethernet-phy@0 {
> > 			compatible = "ethernet-phy-ieee802.3-c22";
> > 			reg = <0>;
> > 		};
> 
> ...
> 
> > 	};
> > 
> > 	qca8081: ethernet-phy@28 {
> > 		compatible = "ethernet-phy-id004d.d101";
> > 		reg = <28>;
> > 		reset-gpios = <&tlmm 31 GPIO_ACTIVE_LOW>;
> > 	};
> 
> I've no idea if DT allows this. The issue is that reg is the same for
> both nodes within the ethernet-phy-package container, and
> ethernet-phy@28. They are all addresses on the same MDIO bus.  We are
> parsing this bus structure ourselves in __of_mdiobus_register(), so we
> could make it work, but i don't know if we should make it work.
>

And that is why I have some reserve on the idea of defining a reg for
ethernet-phy-package. Adding a reg would create some duplicate. Is it
really a problem to have a node with no reg in the mdio node?

(patch 04 of this series already updates the parsing function to check
one level deeper in the presence of the ethernet-phy-compatible treating
any node found as it was defined in the upper mdio node)

-- 
	Ansuel




[Index of Archives]     [Linux ARM Kernel]     [Linux ARM]     [Linux Omap]     [Fedora ARM]     [Linux for Sparc]     [IETF Annouce]     [Security]     [Bugtraq]     [Linux MIPS]     [ECOS]     [Asterisk Internet PBX]     [Linux API]

  Powered by Linux