Hi ,
I am working on ethernet driver and using imx6dl custom board with phy LAN8720.
in u-boot , it is working fine and able to do tftp. when kernel up i am getting the below failure.
I enabled the SMSC related kernel configuration and also update the device tree and pinctrl pin .
&fec {
pinctrl-names = "default";
pinctrl-0 = <&pinctrl_enet>;
phy-mode = "rmii";
phy-handle = <ðphy0>;
fsl,magic-packet;
/*Set ethernet clock to 50MHz for LAN87X0*/
assigned-clocks = <&clks IMX6QDL_CLK_ENET_REF>;
assigned-clock-rates = <50000000>;
status = "okay";
mdio {
#address-cells = <1>;
#size-cells = <0>;
ethphy0: ethernet-phy@0 {
reg = <0>;
// max-speed = <100>;
reset-gpios = <&gpio6 14 GPIO_ACTIVE_HIGH>;
reset-assert-us = <10000>;
reset-deassert-us = <1000>;
smsc,disable-energy-detect; /* Make plugin detection reliable */
};
};
};
pinctrl_enet: enetgrp {
fsl,pins = <
/* MDIO */
MX6QDL_PAD_ENET_MDC__ENET_MDC 0x1b0b0
MX6QDL_PAD_ENET_MDIO__ENET_MDIO 0x1a8b0
MX6QDL_PAD_ENET_RXD0__ENET_RX_DATA0 0x1a830
MX6QDL_PAD_ENET_RXD1__ENET_RX_DATA1 0x1a830
MX6QDL_PAD_ENET_RX_ER__ENET_RX_ER 0x1b030
MX6QDL_PAD_ENET_CRS_DV__ENET_RX_EN 0x1a830
MX6QDL_PAD_ENET_TX_EN__ENET_TX_EN 0x10030
MX6QDL_PAD_ENET_TXD0__ENET_TX_DATA0 0x1b030
MX6QDL_PAD_ENET_TXD1__ENET_TX_DATA1 0x1b030
MX6QDL_PAD_RGMII_TX_CTL__ENET_REF_CLK 0x0b0a8
MX6QDL_PAD_NANDF_CS0__ENET_IRQ 0x1a8b1
MX6QDL_PAD_NANDF_CS1__GPIO6_IO14 0x80000000
>;
};
[ 2.746064] fec 2188000.ethernet eth0: registered PHC device 0
[ 15.939547] SMSC LAN8710/LAN8720 2188000.ethernet-1:00: phy_poll_reset failed: -110
[ 15.939640] fec 2188000.ethernet eth0: Unable to connect to phy
[ 18.169362] SMSC LAN8710/LAN8720 2188000.ethernet-1:00: phy_poll_reset failed: -110
[ 18.169452] fec 2188000.ethernet eth0: Unable to connect to phy
FYI. https://community.nxp.com/t5/i-MX-Processors-Knowledge-Base/Porting-KSZ9031-to-i-MX-BSP/ta-p/1112601
As the tftp is working in u-boot, please double check the setting in dts between u-boot and kernel.