]> git.dujemihanovic.xyz Git - u-boot.git/commitdiff
arm: xilinx: Fill DEVICE_TREE directly in Makefiles
authorMichal Simek <michal.simek@xilinx.com>
Thu, 13 Feb 2020 13:36:34 +0000 (14:36 +0100)
committerMichal Simek <michal.simek@xilinx.com>
Fri, 28 Feb 2020 11:15:11 +0000 (12:15 +0100)
DEVICE_TREE variable is not exported from dts/Makefile that's why it is
necessary to setup directly before use.

Fixes: 312f2c5b14fa ("arm: xilinx: Use device tree which can be passed on cmd line")
Signed-off-by: Michal Simek <michal.simek@xilinx.com>
board/xilinx/zynq/Makefile
board/xilinx/zynqmp/Makefile

index 6a2acee108faa350dd72602ea6f80a0a6842d8d0..096a7aceb939c49203e9acc8538447a02d6425d5 100644 (file)
@@ -13,6 +13,11 @@ spl/board/xilinx/zynq/ps_init_gpl.o board/xilinx/zynq/ps_init_gpl.o: $(PS_INIT_F
        $(CC) $(c_flags) -I $(srctree)/$(src) -c -o $@ $^
 endif
 
+DEVICE_TREE ?= $(CONFIG_DEFAULT_DEVICE_TREE:"%"=%)
+ifeq ($(DEVICE_TREE),)
+DEVICE_TREE := unset
+endif
+
 ifeq ($(init-objs),)
 hw-platform-y :=$(shell echo $(DEVICE_TREE))
 init-objs := $(if $(wildcard $(srctree)/$(src)/$(hw-platform-y)/ps7_init_gpl.c),\
index 174f4ed24be305485316966e7a416d2a248d31cd..398c6aaa452acd3cd8f906de8445de674f7be29b 100644 (file)
@@ -13,6 +13,11 @@ spl/board/xilinx/zynqmp/ps_init_gpl.o board/xilinx/zynqmp/ps_init_gpl.o: $(PS_IN
        $(CC) $(c_flags) -I $(srctree)/$(src) -c -o $@ $^
 endif
 
+DEVICE_TREE ?= $(CONFIG_DEFAULT_DEVICE_TREE:"%"=%)
+ifeq ($(DEVICE_TREE),)
+DEVICE_TREE := unset
+endif
+
 ifeq ($(init-objs),)
 hw-platform-y :=$(shell echo $(DEVICE_TREE))
 init-objs := $(if $(wildcard $(srctree)/$(src)/$(hw-platform-y)/psu_init_gpl.c),\