cancel
Showing results for 
Search instead for 
Did you mean: 

"EQOS_DMA_MODE_SWR stuck FAILED: -110" error for ethernet in uboot

ahamod3.1416
Associate II

Hi everyone,

recently we have developed a custom board based on stm32mp157 mpu. We have used openstlinux distribution and the branch is "kirkstone". Ethernet is working perfectly on the Linux kernel. But problem arises when I am in the uboot mode (We want to have access to the ethernet from uboot). First, the ethernet can not find the mac address. It shows the following Error:

 

 

invalid MAC address 0 in OTP 00:00:00:00:00:00

Error: ethernet@5800a000 address not set.
No ethernet found.

 

 
The I set the ethernet mac address using the "setenv" command and then I enter dhcp command to test the ethernet connection, it shows the following error:
 

 

EQOS_DMA_MODE_SWR stuck FAILED: -110 in stm32mp157 for u-boot

 

 

I have the following configuration for the ethernet in uboot device tree.

 

 

&ethernet0{
        pinctrl-names = "default", "sleep";
        pinctrl-0 = <&eth1_pins_mx>;
        pinctrl-1 = <&eth1_sleep_pins_mx>;
        status ="okay";

        /* USER CODE BEGIN ethernet0 */
        phy-mode = "rmii";
        max-speed = <100>;
        phy-handle = <&phy0>;
        phy-supply = <&vdd_usb>;
        nvmem-cells = <&ethernet_mac_address>;
        nvmem-cell-names = "mac-address";

        clock-names = "stmmaceth",
                "mac-clk-tx",
                "mac-clk-rx",
                "ethstp",
                "eth-ck",
                "syscfg-clk";
        clocks = <&rcc ETHMAC>,
                <&rcc ETHTX>,
                <&rcc ETHRX>,
                <&rcc ETHSTP>,
                <&rcc ETHCK_K>,
                <&rcc SYSCFG>;
        st,eth_ref_clk_sel;
        phy-reset-gpios = <&gpiob 0 GPIO_ACTIVE_LOW>;

        mdio0 {
                #address-cells = <1>;
                #size-cells = <0>;
                compatible = "snps,dwmac-mdio";
                phy0: ethernet-phy@0 {
                        reset-gpios = <&gpiob 0 GPIO_ACTIVE_LOW>;
                        reset-duration = <200>;
                        reg = <0>;
                };
        };
        /* USER CODE END ethernet0 */
};

 

 

Can anyone help me to solve those above two errors? Thanks in advance.

1 ACCEPTED SOLUTION

Accepted Solutions
ahamod3.1416
Associate II

Finally got the solution for the Error. This Error basically indicate the clock issue. EQOS_DMA_MODE_SWR function is being called if software reset is not done in the SWR time interval. I set the wrong clock. I figured it out by measuring the clock using oscilloscope.

View solution in original post

2 REPLIES 2
ahamod3.1416
Associate II

I got solution for the the first problem in defconfig I added "CONFIG_NET_RANDOM_ETHADDR=y".

Which is getting a random mac address. Now I do not have to set the mac address manually. But still I have the second error and can not establish the connection with the internet.

ahamod3.1416
Associate II

Finally got the solution for the Error. This Error basically indicate the clock issue. EQOS_DMA_MODE_SWR function is being called if software reset is not done in the SWR time interval. I set the wrong clock. I figured it out by measuring the clock using oscilloscope.