In our design, which is similar to Ethernet (ENET1) on MCIMX6ULL-EVK, I am trying to determine a reasonable device tree. To rule out a hardware issue, I am trying to get the EVK board to work with only ENET1.
I am using U-Boot 2020, and patching file:
arch/arm/dts/imx6ul-14x14-evk.dtsi
I wrote a patch, but the patch causes the MDIO bus to not function:
Net: FEC: can't find phy-handle
Could not get PHY for FEC0: addr 2
FEC: can't find phy-handle
Could not get PHY for FEC0: addr 2
No ethernet found.
Fastboot: Normal
Normal Boot
Hit any key to stop autoboot: 0
=>
=> mdio list
No MDIO bus found
When I take my patch out, I get both ports successfully, but I am trying to simulate having only one port. Why would removing enet2 cause mdio not to work?
I added the mdio signals with the pin control for ENET1:
MX6UL_PAD_ENET1_TX_DATA1__ENET1_TDATA01 0x1b0b0
MX6UL_PAD_ENET1_TX_CLK__ENET1_REF_CLK1 0x4001b031
+ MX6UL_PAD_GPIO1_IO07__ENET2_MDC 0x1b0b0
+ MX6UL_PAD_GPIO1_IO06__ENET2_MDIO 0x1b0b0
>;
I moved the phy section for ENET1 into fec1:
phy-handle = <ðphy0>;
status = "okay";
+ ethphy0: ethernet-phy@2 {
+ reg = <2>;
+ micrel,led-mode = <1>;
+ clocks = <&clks IMX6UL_CLK_ENET_REF>;
+ clock-names = "rmii-ref";
+ };
I created a dummy enet2 that replaced the original:
+&fec2 {
+ status = "disabled";
+};
Solved! Go to Solution.
Thinking about this some more, it probably didn't make sense to disable ENET2, yet use the ENET2 MDIO path. I changed the pad for IO06 and IO07 to ENET1, and the MDIO worked, and Ethernet worked as well.
Thinking about this some more, it probably didn't make sense to disable ENET2, yet use the ENET2 MDIO path. I changed the pad for IO06 and IO07 to ENET1, and the MDIO worked, and Ethernet worked as well.