diff mbox series

[v1,09/12] configs: stm32f746-disco: use CONFIG_DEFAULT_DEVICE_TREE as fdtfile

Message ID 20220413150500.23883-10-patrice.chotard@foss.st.com
State Superseded
Delegated to: Patrick Delaunay
Headers show
Series stm32: add new board support, defconfig and documentation | expand

Commit Message

Patrice CHOTARD April 13, 2022, 3:04 p.m. UTC
As stm32f46-disco, stm32f769-disco and stm32746g-eval are very similar
except their respective device tree file. These 3 boards uses the same
TARGET_STM32F746_DISCO flag (so same include/configs/stm32f746-disco.h
and same board file board/st/stm32f746-disco/stm32f746-disco.c)

To be able to compile these 3 boards, replace the hard-coded device-tree
name in include/configs/stm32f746-disco.h by CONFIG_DEFAULT_DEVICE_TREE
which is set in each board defconfig file with the correct value.

Signed-off-by: Patrice Chotard <patrice.chotard@foss.st.com>
---

 include/configs/stm32f746-disco.h | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

Comments

Patrick Delaunay April 26, 2022, 11:37 a.m. UTC | #1
Hi,


On 4/13/22 17:04, Patrice Chotard wrote:
> As stm32f46-disco, stm32f769-disco and stm32746g-eval are very similar
> except their respective device tree file. These 3 boards uses the same
> TARGET_STM32F746_DISCO flag (so same include/configs/stm32f746-disco.h
> and same board file board/st/stm32f746-disco/stm32f746-disco.c)
>
> To be able to compile these 3 boards, replace the hard-coded device-tree
> name in include/configs/stm32f746-disco.h by CONFIG_DEFAULT_DEVICE_TREE
> which is set in each board defconfig file with the correct value.
>
> Signed-off-by: Patrice Chotard <patrice.chotard@foss.st.com>
> ---
>
>   include/configs/stm32f746-disco.h | 2 +-
>   1 file changed, 1 insertion(+), 1 deletion(-)



Reviewed-by: Patrick Delaunay <patrick.delaunay@foss.st.com>

Thanks
Patrick
diff mbox series

Patch

diff --git a/include/configs/stm32f746-disco.h b/include/configs/stm32f746-disco.h
index b93acdcc1f..cc3d4b4449 100644
--- a/include/configs/stm32f746-disco.h
+++ b/include/configs/stm32f746-disco.h
@@ -34,7 +34,7 @@ 
 #include <config_distro_bootcmd.h>
 #define CONFIG_EXTRA_ENV_SETTINGS				\
 			"kernel_addr_r=0xC0008000\0"		\
-			"fdtfile=stm32f746-disco.dtb\0"	\
+			"fdtfile="CONFIG_DEFAULT_DEVICE_TREE".dtb\0"	\
 			"fdt_addr_r=0xC0408000\0"		\
 			"scriptaddr=0xC0418000\0"		\
 			"pxefile_addr_r=0xC0428000\0" \