IMX6Q: RMII & Fixed-link

cancel
Showing results for 
Search instead for 
Did you mean: 

IMX6Q: RMII & Fixed-link

Jump to solution
3,503 Views
woutervh
Contributor IV

Hello all,

In my setup, I have an IMX6, connected through RMII to a Marvell switch (88E6071 / 100Mbit). For the phy-bus, I make use of the fixed-phy/fixed-link driver. My kernel is linux 4.1.36.xxx

I already had 2 setups, one where The IMX6 washgenerating the ENET_REFCLOCK, and one where I let the marvell do it. Both solutions worked the same in the end:

I'm only able to output from imx towards my pc. The response never arrives. The RX packets errors is building up, without any success. If I ping from the imx towards my pc, and look in wireshark, I see the arp's coming from the board, and I'm also answering them. But for some reason, they do not arrive.

I already had it working with the same setup, but based on linux 3.14.52. What is changed, or what is preventing my system to work correctly on 4.1.36?

Relevant DTS-parts:

&fec {
   pinctrl-names = "default";
   pinctrl-0 = <&pinctrl_enet>;
   phy-mode = "rmii";
   clocks = <&clks IMX6QDL_CLK_ENET>,
               <&clks IMX6QDL_CLK_ENET>,
                <&clks IMX6QDL_CLK_ENET_REF>,
               <&clks IMX6QDL_CLK_ENET_REF>;
   clock-names = "ipg", "ahb", "ptp", "enet_out";
   fsl,magic-packet;
   status = "okay";
   label = "fec";
   fixed-link {
         speed = <100>;
         full-duplex;
   };
};

pinctrl_enet: enetgrp {
fsl,pins = <
   MX6QDL_PAD_ENET_MDIO__ENET_MDIO 0x1b0b0
   MX6QDL_PAD_ENET_MDC__ENET_MDC 0x1b0b0
   MX6QDL_PAD_ENET_TXD0__ENET_TX_DATA0 0x1b0b0
   MX6QDL_PAD_ENET_TXD1__ENET_TX_DATA1 0x1b0b0
   MX6QDL_PAD_ENET_TX_EN__ENET_TX_EN 0x1b0b0
   MX6QDL_PAD_ENET_RXD0__ENET_RX_DATA0 0x1b0b0
   MX6QDL_PAD_ENET_RXD1__ENET_RX_DATA1 0x1b0b0
   MX6QDL_PAD_ENET_CRS_DV__ENET_RX_EN 0x1b0b0
   MX6QDL_PAD_ENET_RX_ER__ENET_RX_ER 0x1b0b0
   MX6QDL_PAD_GPIO_19__ENET_TX_ER 0x1b0b0
   MX6QDL_PAD_GPIO_16__ENET_REF_CLK 0x4001b0a8
>;
};

Does anyone has a clue on where to search? If 

Labels (3)
0 Kudos
1 Solution
1,255 Views
woutervh
Contributor IV

Found the issue...

In our design, RX_ER and TX_ER are not connected at all. For TX_ER that doesn't matter, but for RX_ER, which is an input towards the IMX6, it was continuously reporting RX-errors. This also happened on the release-kernel, however traffic itself was working, only error counters were increasing. In 4.1-kernel, apparently the data was just dropped. Now I changed the internal resistor of this RX_ER pin to 100K pulldown, and now it works fine!

So MX6QDL_PAD_ENET_RX_ER__ENET_RX_ER 0x1b0b0 became MX6QDL_PAD_ENET_RX_ER__ENET_RX_ER 0x130b0

View solution in original post

5 Replies
1,256 Views
woutervh
Contributor IV

Found the issue...

In our design, RX_ER and TX_ER are not connected at all. For TX_ER that doesn't matter, but for RX_ER, which is an input towards the IMX6, it was continuously reporting RX-errors. This also happened on the release-kernel, however traffic itself was working, only error counters were increasing. In 4.1-kernel, apparently the data was just dropped. Now I changed the internal resistor of this RX_ER pin to 100K pulldown, and now it works fine!

So MX6QDL_PAD_ENET_RX_ER__ENET_RX_ER 0x1b0b0 became MX6QDL_PAD_ENET_RX_ER__ENET_RX_ER 0x130b0

1,255 Views
2072747856
Contributor I

我也遇到这个情况,RX_ER加上100K下拉后,ping不通我的电脑,通过数据分析发现,只有发送的数据包,完全没有返回的数据包,这个是什么情况?

0 Kudos
1,255 Views
woutervh
Contributor IV

Actually, when I ping my pc, I'm able to see the arp's coming from the board in wireshark. I also see myself replying, but it's as they don't arrive at the iMX... RX errors on the imx increase

0 Kudos
1,255 Views
gusarambula
NXP TechSupport
NXP TechSupport

Hello Wouter Vanhauwaert,

If your setup was working correctly on the 3.14.52 kernel from NXP BSP Release I may recommend switching to kernel 4.1.15 from the latest BSP Release as kernel 4.1.36 is not tested on the i.MX6 and may be difficult to get to the root cause of this behavior.

Hopefully another community user may have experience with this kernel and may be able to provide some inputs.

Regards,

0 Kudos
1,255 Views
woutervh
Contributor IV

Well, my initial post was a bit mistaken.

I'm on branch linux-fslc-imx-rt_4.1-1.0.x of the fslsc github repo...

0 Kudos