diff options
author | Tom Rini <trini@konsulko.com> | 2022-04-15 08:09:52 -0400 |
---|---|---|
committer | Tom Rini <trini@konsulko.com> | 2022-04-15 08:10:32 -0400 |
commit | 7f418ea59852945eeb9e5d2555d306f09643d555 (patch) | |
tree | 069dbaf3a1f62b68251189e9acdbd9affcbd98c5 /board/st | |
parent | 239fe55a6ce516f329687c0680428ca2acfc73ca (diff) | |
parent | 0154e6de37e8bbaac837939391f6d4a8f0b3fd18 (diff) |
Merge branch 'next' of https://source.denx.de/u-boot/custodians/u-boot-net
- DM9000 DM support
- tftp server bug fix
- mdio ofnode support functions
- Various phy fixes and improvements.
[trini: Fixup merge conflicts in drivers/net/phy/ethernet_id.c
drivers/net/phy/phy.c include/phy.h]
Diffstat (limited to 'board/st')
-rw-r--r-- | board/st/stm32f746-disco/stm32f746-disco.c | 13 |
1 files changed, 5 insertions, 8 deletions
diff --git a/board/st/stm32f746-disco/stm32f746-disco.c b/board/st/stm32f746-disco/stm32f746-disco.c index 95d83e73ee8..69f657c54b8 100644 --- a/board/st/stm32f746-disco/stm32f746-disco.c +++ b/board/st/stm32f746-disco/stm32f746-disco.c @@ -117,16 +117,13 @@ int board_late_init(void) int board_init(void) { #ifdef CONFIG_ETH_DESIGNWARE - const char *phy_mode; - int node; + ofnode node; - node = fdt_node_offset_by_compatible(gd->fdt_blob, 0, "st,stm32-dwmac"); - if (node < 0) + node = ofnode_by_compatible(ofnode_null(), "st,stm32-dwmac"); + if (!ofnode_valid(node)) return -1; - phy_mode = fdt_getprop(gd->fdt_blob, node, "phy-mode", NULL); - - switch (phy_get_interface_by_name(phy_mode)) { + switch (ofnode_read_phy_mode(node)) { case PHY_INTERFACE_MODE_RMII: STM32_SYSCFG->pmc |= SYSCFG_PMC_MII_RMII_SEL; break; @@ -134,7 +131,7 @@ int board_init(void) STM32_SYSCFG->pmc &= ~SYSCFG_PMC_MII_RMII_SEL; break; default: - printf("PHY interface %s not supported !\n", phy_mode); + printf("Unsupported PHY interface!\n"); } #endif |