netdev.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* LAN8720: RX errors / packet loss when using smsc PHY driver on i.MX6Q
@ 2025-11-13 22:25 Fabio Estevam
  2025-11-13 22:35 ` Andrew Lunn
  0 siblings, 1 reply; 15+ messages in thread
From: Fabio Estevam @ 2025-11-13 22:25 UTC (permalink / raw)
  To: Andrew Lunn, Heiner Kallweit, Russell King - ARM Linux; +Cc: edumazet, netdev

Hi,

On a custom i.MX6Q-based board using a LAN8720 PHY, we are observing
consistent packet loss when the LAN8720-specific PHY driver
(drivers/net/phy/smsc.c) is in use.

Kernel versions tested: 6.18-rc4 and 6.12
MAC driver: FEC (i.MX6)
PHY: LAN8720 (RMII) providing the 50 MHz ENET_REF clock to the SoC.

Behavior:

- Packet loss occurs when the LAN8720 is bound to the smsc PHY driver.

- No packet loss when using the generic PHY driver.

- No packet loss when the smsc driver is used and the link is forced
to 10 Mbps using ethtool.

The issue is easily reproduced with:

ping -c 1000 -i 0.2 -s 1300 <board-ip>

The board’s relevant DT fragment:

&fec {
    status = "okay";
    pinctrl-names = "default";
    pinctrl-0 = <&pinctrl_fec>;

    /* FEC ENET REF clock comes from LAN8720 */
    clocks = <&clks IMX6QDL_CLK_ENET>,
             <&clks IMX6QDL_CLK_ENET>,
             <&clks IMX6QDL_CLK_ENET>,
             <&clks IMX6QDL_CLK_ENET_REF>;
    clock-names = "ipg", "ahb", "ptp", "enet_out";

    phy-mode = "rmii";
    phy-reset-gpios = <&gpio2 4 GPIO_ACTIVE_LOW>;
    phy-reset-duration = <100>;
    phy-handle = <&ethphy0>;

    mdio {
        #address-cells = <1>;
        #size-cells = <0>;
        status = "okay";

        ethphy0: ethernet-phy@0 {
            reg = <0>;
            compatible = "ethernet-phy-ieee802.3-c22";
            max-speed = <100>;
            smsc,disable-energy-detect;
        };
    };
};

Has anyone seen similar behavior with LAN8720 or the smsc PHY driver
on i.MX platforms?
Any guidance on how to further debug this or what additional
information would be useful is appreciated.

Thanks,

Fabio Estevam

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

end of thread, other threads:[~2025-11-16 15:55 UTC | newest]

Thread overview: 15+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2025-11-13 22:25 LAN8720: RX errors / packet loss when using smsc PHY driver on i.MX6Q Fabio Estevam
2025-11-13 22:35 ` Andrew Lunn
2025-11-14 21:15   ` Fabio Estevam
2025-11-14 21:33     ` Heiner Kallweit
2025-11-14 21:48       ` Florian Fainelli
2025-11-14 22:48         ` Andrew Lunn
2025-11-15 21:01       ` Fabio Estevam
2025-11-15 21:26         ` Heiner Kallweit
2025-11-15 21:54           ` Fabio Estevam
2025-11-15 22:01             ` Russell King (Oracle)
2025-11-15 22:25               ` Fabio Estevam
2025-11-15 21:37         ` Russell King (Oracle)
2025-11-16  0:57           ` Fabio Estevam
2025-11-16  2:14             ` Fabio Estevam
2025-11-16 15:55               ` Andrew Lunn

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).