cancel
Showing results for 
Search instead for 
Did you mean: 

DP83867 phy clock problem (don't bring up)

aliMesut
Associate III

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

1 ACCEPTED SOLUTION

Accepted Solutions

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

View solution in original post

5 REPLIES 5
OlivierK
ST Employee

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.

https://www.st.com/resource/en/application_note/dm00389996-getting-started-with-stm32mp151-stm32mp153-and-stm32mp157-line-hardware-development-stmicroelectronics.pdf

Regards,

Olivier

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

OlivierK
ST Employee

Hello Mesut,

Ok fine. I am surprized it compiled ok before. Are your now sorted out ?

Olivier

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

PatrickF
ST Employee

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'

In order to give better visibility on the answered topics, please click on 'Accept as Solution' on the reply which solved your issue or answered your question.