2021-10-18 01:43 AM
Hi, I'm Mesut
I'm working STM32MP157C and use DP83867IRRGZ Ethernet Phy in RGMII Mode. There is no 125 MHz from CLK_OUT of DP83867IRRGZ on default mode.
But STM32MP157C need 125 MHz on its PG5 pin. For STM32MP157C we must provide a 125 MHz clock from DP83867IRRGZ or RCC.
I create pll4p -> ethck_k clock 125 MHz follow the https://wiki.st.com/stm32mpu/wiki/Ethernet_device_tree_configuration
. I saw this by calling the "cat /sys/kernel/debug/clk/clk_summary" command on linux.
pll4_p 0 0 0 125000000 0 0 50000
ethptp_k 0 0 0 125000000 0 0 50000
ethck_k 0 0 0 125000000 0 0 50000
But when i "ifconfig eth0 up" write, i'm getting the issue.
Why doesn't the internally set rcc clock run ethernet?
[ 23.523586] stm32-dwmac 5800a000.ethernet: Failed to reset the dma
[ 23.528343] stm32-dwmac 5800a000.ethernet eth0: stmmac_hw_setup: DMA engine initialization failed
[ 23.537298] stm32-dwmac 5800a000.ethernet eth0: stmmac_open: Hw setup failed
What could be the problem?
Best regards.
Mesut Ince
Solved! Go to Solution.
2021-10-18 10:34 PM
Hello Oliver,
Thankyo for your support.
We worked on Documentation/devicetree/bindings/net/stm32-dwmac.yaml document and we noticed that forgot to add "#include <dt-bindings/mfd/stm32h7-rcc.h>" library.
Mesut Ince
2021-10-18 10:53 AM
Hello Mesut,
I would need further information to help. Which OpenSTLinux version do you use? Could you share also your DT?
Your ethernet setup is the RCC to provide the 25MHz source clock to the phy, the phy provides the 125MHz back or you want the RCC to provide the 125MHz to the GMAC? for the latter have you recompiled the TF-A?
You could also refer to this AN for the Ethernet setup.
Regards,
Olivier
2021-10-18 10:34 PM
Hello Oliver,
Thankyo for your support.
We worked on Documentation/devicetree/bindings/net/stm32-dwmac.yaml document and we noticed that forgot to add "#include <dt-bindings/mfd/stm32h7-rcc.h>" library.
Mesut Ince
2021-10-19 09:36 AM
Hello Mesut,
Ok fine. I am surprized it compiled ok before. Are your now sorted out ?
Olivier
2021-10-19 11:15 PM
Hello Oliver,
I did not understand how it was compiled. The fact that it didn't give any errors forced me. Now everythibg is ok.
Mesut
2021-10-21 08:11 AM
Hi @aliMesut
In order to give better visibility on the answered topics, please click on 'Select as Best' on the reply which solved your issue or answered your question. See also 'Best Answers'