]> git.proxmox.com Git - mirror_ubuntu-kernels.git/commitdiff
ARM: dts: imx6qdl-icore: Add fec phy-handle
authorMichael Trimarchi <michael@amarulasolutions.com>
Mon, 30 Dec 2019 12:00:21 +0000 (17:30 +0530)
committerShawn Guo <shawnguo@kernel.org>
Thu, 9 Jan 2020 07:43:48 +0000 (15:43 +0800)
LAN8720 needs a reset of every clock enable. The reset needs
to be done at device level, due the flag PHY_RST_AFTER_CLK_EN.

So, add phy-handle by creating mdio child node inside fec.
This will eventually move the phy-reset-gpio which is defined
in fec node.

Signed-off-by: Michael Trimarchi <michael@amarulasolutions.com>
Signed-off-by: Jagan Teki <jagan@amarulasolutions.com>
Signed-off-by: Shawn Guo <shawnguo@kernel.org>
arch/arm/boot/dts/imx6qdl-icore.dtsi

index 7814f1ef08043e67b2ad89dcf479365396e06ea3..756f3a9f1b4fed2cafb4766ea63a095890c6b318 100644 (file)
 &fec {
        pinctrl-names = "default";
        pinctrl-0 = <&pinctrl_enet>;
-       phy-reset-gpios = <&gpio7 12 GPIO_ACTIVE_LOW>;
        clocks = <&clks IMX6QDL_CLK_ENET>, <&clks IMX6QDL_CLK_ENET>, <&rmii_clk>;
        phy-mode = "rmii";
+       phy-handle = <&eth_phy>;
        status = "okay";
+
+       mdio {
+               #address-cells = <1>;
+               #size-cells = <0>;
+
+               eth_phy: ethernet-phy@0 {
+                       compatible = "ethernet-phy-ieee802.3-c22";
+                       reg = <0>;
+                       reset-gpios = <&gpio7 12 GPIO_ACTIVE_LOW>;
+                       reset-assert-us = <4000>;
+                       reset-deassert-us = <4000>;
+               };
+       };
 };
 
 &gpmi {