meta-freescale.lists.yoctoproject.org archive mirror
 help / color / mirror / Atom feed
* fec driver works on linux-imx, not linux-fslc+use-mainline-bsp (imx6dl)
@ 2020-08-17 12:32 Christian Betz
  2020-08-17 13:04 ` [meta-freescale] " Fabio Estevam
  2020-08-17 13:04 ` Andrey Zhizhikin
  0 siblings, 2 replies; 3+ messages in thread
From: Christian Betz @ 2020-08-17 12:32 UTC (permalink / raw)
  To: meta-freescale

[-- Attachment #1: Type: text/plain, Size: 3164 bytes --]

Hi,

I'm porting a custom MX6DL board from linux-imx to linux-fslc (along with
use-mainline-bsp in FEATURES). The primary reason for this choice was for
etnaviv support and a general preference for a mainline kernel. I'm pleased
to say that the etnaviv is working ok!

Problem: The ethernet connection does not work correctly. It seems to
accept pings and I can login via SSH. However, any scp or http transfer
fails. Ifconfig shows TX errors. None of these issues happen on linux-imx.
btw, i have an imx6qsabresd demo board running linux-fslc with
use-mainline-bsp and the ethernet works fine on it.

There are no errors/warnings in dmesg. If I use "ping -s 1500 $DEVICE_IP",
I definitely notice pings being lost, so this seems related to packet size
somehow.

I'm looking for some suggestions on next steps to troubleshoot this issue,
or some idea of what is different between linux-imx and linux-fslc when it
comes to the fec driver. Note: i'm running kernel 5.4.46 based on revision
38d6c352 (Otavio's merge on June 15th).

As far as can tell, our ethernet-related customizations are minimal,
basically these changes to 'pinctrl_enet' imx6qdl-sabresd.dtsi. Again,
these changes seem to work fine on linux-imx but not linux-fslc with
use-mainline-bsp.

                pinctrl_enet: enetgrp {
                        fsl,pins = <
                                MX6QDL_PAD_ENET_MDIO__ENET_MDIO
0x1b0b0
                                MX6QDL_PAD_ENET_MDC__ENET_MDC
0x1b0b0
                                MX6QDL_PAD_RGMII_TXC__RGMII_TXC
0x1b030
                                MX6QDL_PAD_RGMII_TD0__RGMII_TD0
0x1b030
                                MX6QDL_PAD_RGMII_TD1__RGMII_TD1
0x1b030
                                MX6QDL_PAD_RGMII_TD2__RGMII_TD2
0x1b030
                                MX6QDL_PAD_RGMII_TD3__RGMII_TD3
0x1b030
                                MX6QDL_PAD_RGMII_TX_CTL__RGMII_TX_CTL
0x1b030
-                               MX6QDL_PAD_ENET_REF_CLK__ENET_TX_CLK
 0x1b0b0
+                               /* MX6QDL_PAD_ENET_REF_CLK__ENET_TX_CLK
0x1b0b0
+                                * Changes to CONFIG_BITS
+                                *  Turn off PAD_CTL_HYS, PAT_CTL_PUS_22KUP
+                                *  Turn on SRE_FAST
+                                */
+                               MX6QDL_PAD_ENET_REF_CLK__ENET_TX_CLK
 0x100b1
                                MX6QDL_PAD_RGMII_RXC__RGMII_RXC
0x1b030
                                MX6QDL_PAD_RGMII_RD0__RGMII_RD0
0x1b030
                                MX6QDL_PAD_RGMII_RD1__RGMII_RD1
0x1b030
                                MX6QDL_PAD_RGMII_RD2__RGMII_RD2
0x1b030
                                MX6QDL_PAD_RGMII_RD3__RGMII_RD3
0x1b030
                                MX6QDL_PAD_RGMII_RX_CTL__RGMII_RX_CTL
0x1b030
-                               MX6QDL_PAD_GPIO_16__ENET_REF_CLK
 0x4001b0a8
+                               /* Completely disable ENET_REF_CLK (???) */
+                               /*MX6QDL_PAD_GPIO_16__ENET_REF_CLK
 0x4001b0a8*/
                        >;
                };

[-- Attachment #2: Type: text/html, Size: 4059 bytes --]

^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: [meta-freescale] fec driver works on linux-imx, not linux-fslc+use-mainline-bsp (imx6dl)
  2020-08-17 12:32 fec driver works on linux-imx, not linux-fslc+use-mainline-bsp (imx6dl) Christian Betz
@ 2020-08-17 13:04 ` Fabio Estevam
  2020-08-17 13:04 ` Andrey Zhizhikin
  1 sibling, 0 replies; 3+ messages in thread
From: Fabio Estevam @ 2020-08-17 13:04 UTC (permalink / raw)
  To: Christian Betz; +Cc: meta-freescale

Hi Christian,

On Mon, Aug 17, 2020 at 9:32 AM Christian Betz <christian.betz@gmail.com> wrote:
>
> Hi,
>
> I'm porting a custom MX6DL board from linux-imx to linux-fslc (along with use-mainline-bsp in FEATURES). The primary reason for this choice was for etnaviv support and a general preference for a mainline kernel. I'm pleased to say that the etnaviv is working ok!
>
> Problem: The ethernet connection does not work correctly. It seems to accept pings and I can login via SSH. However, any scp or http transfer fails. Ifconfig shows TX errors. None of these issues happen on linux-imx. btw, i have an imx6qsabresd demo board running linux-fslc with use-mainline-bsp and the ethernet works fine on it.
>
> There are no errors/warnings in dmesg. If I use "ping -s 1500 $DEVICE_IP", I definitely notice pings being lost, so this seems related to packet size somehow.
>
> I'm looking for some suggestions on next steps to troubleshoot this issue, or some idea of what is different between linux-imx and linux-fslc when it comes to the fec driver. Note: i'm running kernel 5.4.46 based on revision 38d6c352 (Otavio's merge on June 15th).
>
> As far as can tell, our ethernet-related customizations are minimal, basically these changes to 'pinctrl_enet' imx6qdl-sabresd.dtsi. Again, these changes seem to work fine on linux-imx but not linux-fslc with use-mainline-bsp.

What is the Ethernet PHY on your board? Is it getting detected by
looking at the dmesg log?

Could you share the schematics and device tree?

^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: [meta-freescale] fec driver works on linux-imx, not linux-fslc+use-mainline-bsp (imx6dl)
  2020-08-17 12:32 fec driver works on linux-imx, not linux-fslc+use-mainline-bsp (imx6dl) Christian Betz
  2020-08-17 13:04 ` [meta-freescale] " Fabio Estevam
@ 2020-08-17 13:04 ` Andrey Zhizhikin
  1 sibling, 0 replies; 3+ messages in thread
From: Andrey Zhizhikin @ 2020-08-17 13:04 UTC (permalink / raw)
  To: Christian Betz; +Cc: meta-freescale

Hello Christian,

On Mon, Aug 17, 2020 at 2:32 PM Christian Betz <christian.betz@gmail.com> wrote:
>
> Hi,
>
> I'm porting a custom MX6DL board from linux-imx to linux-fslc (along with use-mainline-bsp in FEATURES). The primary reason for this choice was for etnaviv support and a general preference for a mainline kernel. I'm pleased to say that the etnaviv is working ok!
>
> Problem: The ethernet connection does not work correctly. It seems to accept pings and I can login via SSH. However, any scp or http transfer fails. Ifconfig shows TX errors. None of these issues happen on linux-imx. btw, i have an imx6qsabresd demo board running linux-fslc with use-mainline-bsp and the ethernet works fine on it.
>
> There are no errors/warnings in dmesg. If I use "ping -s 1500 $DEVICE_IP", I definitely notice pings being lost, so this seems related to packet size somehow.
>
> I'm looking for some suggestions on next steps to troubleshoot this issue, or some idea of what is different between linux-imx and linux-fslc when it comes to the fec driver. Note: i'm running kernel 5.4.46 based on revision 38d6c352 (Otavio's merge on June 15th).

Do you see the same behavior with linux-fslc-imx kernel tree? It is
basically NXP kernel + latest patch level from upstream.

Can you test that one and let here know if you have the same thing
there? If it happened that it is not exhibiting the same errors - then
there is something definitely missing in the mainline kernel, which
should be cherry-picked from NXP BSP and sent to upstream.

I cannot test that since I do not have i.MX6 HW on hands...

>
> As far as can tell, our ethernet-related customizations are minimal, basically these changes to 'pinctrl_enet' imx6qdl-sabresd.dtsi. Again, these changes seem to work fine on linux-imx but not linux-fslc with use-mainline-bsp.
>
>                 pinctrl_enet: enetgrp {
>                         fsl,pins = <
>                                 MX6QDL_PAD_ENET_MDIO__ENET_MDIO         0x1b0b0
>                                 MX6QDL_PAD_ENET_MDC__ENET_MDC           0x1b0b0
>                                 MX6QDL_PAD_RGMII_TXC__RGMII_TXC         0x1b030
>                                 MX6QDL_PAD_RGMII_TD0__RGMII_TD0         0x1b030
>                                 MX6QDL_PAD_RGMII_TD1__RGMII_TD1         0x1b030
>                                 MX6QDL_PAD_RGMII_TD2__RGMII_TD2         0x1b030
>                                 MX6QDL_PAD_RGMII_TD3__RGMII_TD3         0x1b030
>                                 MX6QDL_PAD_RGMII_TX_CTL__RGMII_TX_CTL   0x1b030
> -                               MX6QDL_PAD_ENET_REF_CLK__ENET_TX_CLK    0x1b0b0
> +                               /* MX6QDL_PAD_ENET_REF_CLK__ENET_TX_CLK 0x1b0b0
> +                                * Changes to CONFIG_BITS
> +                                *  Turn off PAD_CTL_HYS, PAT_CTL_PUS_22KUP
> +                                *  Turn on SRE_FAST
> +                                */
> +                               MX6QDL_PAD_ENET_REF_CLK__ENET_TX_CLK    0x100b1
>                                 MX6QDL_PAD_RGMII_RXC__RGMII_RXC         0x1b030
>                                 MX6QDL_PAD_RGMII_RD0__RGMII_RD0         0x1b030
>                                 MX6QDL_PAD_RGMII_RD1__RGMII_RD1         0x1b030
>                                 MX6QDL_PAD_RGMII_RD2__RGMII_RD2         0x1b030
>                                 MX6QDL_PAD_RGMII_RD3__RGMII_RD3         0x1b030
>                                 MX6QDL_PAD_RGMII_RX_CTL__RGMII_RX_CTL   0x1b030
> -                               MX6QDL_PAD_GPIO_16__ENET_REF_CLK        0x4001b0a8
> +                               /* Completely disable ENET_REF_CLK (???) */
> +                               /*MX6QDL_PAD_GPIO_16__ENET_REF_CLK      0x4001b0a8*/
>                         >;
>                 };
>
>
>
> 



-- 
Regards,
Andrey.

^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2020-08-17 13:04 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-08-17 12:32 fec driver works on linux-imx, not linux-fslc+use-mainline-bsp (imx6dl) Christian Betz
2020-08-17 13:04 ` [meta-freescale] " Fabio Estevam
2020-08-17 13:04 ` Andrey Zhizhikin

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).