fdt: Update Makefile rules with the new OF_REAL Kconfig
Simplify some of the Makefile rules using this Kconfig. Signed-off-by: Simon Glass <sjg@chromium.org>
This commit is contained in:
parent
dcfc42b12f
commit
f99cbe4e86
7
Makefile
7
Makefile
@ -1292,10 +1292,6 @@ u-boot.ldr: u-boot
|
|||||||
# Use 'make BINMAN_VERBOSE=3' to set vebosity level
|
# Use 'make BINMAN_VERBOSE=3' to set vebosity level
|
||||||
default_dt := $(if $(DEVICE_TREE),$(DEVICE_TREE),$(CONFIG_DEFAULT_DEVICE_TREE))
|
default_dt := $(if $(DEVICE_TREE),$(DEVICE_TREE),$(CONFIG_DEFAULT_DEVICE_TREE))
|
||||||
|
|
||||||
# Tell binman whether we have a devicetree for SPL and TPL
|
|
||||||
have_spl_dt := $(if $(CONFIG_SPL_OF_PLATDATA),,$(CONFIG_SPL_OF_CONTROL))
|
|
||||||
have_tpl_dt := $(if $(CONFIG_TPL_OF_PLATDATA),,$(CONFIG_TPL_OF_CONTROL))
|
|
||||||
|
|
||||||
quiet_cmd_binman = BINMAN $@
|
quiet_cmd_binman = BINMAN $@
|
||||||
cmd_binman = $(srctree)/tools/binman/binman $(if $(BINMAN_DEBUG),-D) \
|
cmd_binman = $(srctree)/tools/binman/binman $(if $(BINMAN_DEBUG),-D) \
|
||||||
--toolpath $(objtree)/tools \
|
--toolpath $(objtree)/tools \
|
||||||
@ -1309,7 +1305,8 @@ cmd_binman = $(srctree)/tools/binman/binman $(if $(BINMAN_DEBUG),-D) \
|
|||||||
-a scp-path=$(SCP) \
|
-a scp-path=$(SCP) \
|
||||||
-a spl-bss-pad=$(if $(CONFIG_SPL_SEPARATE_BSS),,1) \
|
-a spl-bss-pad=$(if $(CONFIG_SPL_SEPARATE_BSS),,1) \
|
||||||
-a tpl-bss-pad=$(if $(CONFIG_TPL_SEPARATE_BSS),,1) \
|
-a tpl-bss-pad=$(if $(CONFIG_TPL_SEPARATE_BSS),,1) \
|
||||||
-a spl-dtb=$(have_spl_dt) -a tpl-dtb=$(have_tpl_dt) \
|
-a spl-dtb=$(CONFIG_SPL_OF_REAL) \
|
||||||
|
-a tpl-dtb=$(CONFIG_SPL_OF_REAL) \
|
||||||
$(BINMAN_$(@F))
|
$(BINMAN_$(@F))
|
||||||
|
|
||||||
OBJCOPYFLAGS_u-boot.ldr.hex := -I binary -O ihex
|
OBJCOPYFLAGS_u-boot.ldr.hex := -I binary -O ihex
|
||||||
|
@ -80,10 +80,7 @@ obj-$(CONFIG_$(SPL_)LIB_RATIONAL) += rational.o
|
|||||||
obj-$(CONFIG_LIBAVB) += libavb/
|
obj-$(CONFIG_LIBAVB) += libavb/
|
||||||
|
|
||||||
obj-$(CONFIG_$(SPL_TPL_)OF_LIBFDT) += libfdt/
|
obj-$(CONFIG_$(SPL_TPL_)OF_LIBFDT) += libfdt/
|
||||||
ifneq ($(CONFIG_$(SPL_TPL_)BUILD)$(CONFIG_$(SPL_TPL_)OF_PLATDATA),yy)
|
obj-$(CONFIG_$(SPL_TPL_)OF_REAL) += fdtdec_common.o fdtdec.o
|
||||||
obj-$(CONFIG_$(SPL_TPL_)OF_CONTROL) += fdtdec_common.o
|
|
||||||
obj-$(CONFIG_$(SPL_TPL_)OF_CONTROL) += fdtdec.o
|
|
||||||
endif
|
|
||||||
|
|
||||||
ifdef CONFIG_SPL_BUILD
|
ifdef CONFIG_SPL_BUILD
|
||||||
obj-$(CONFIG_SPL_YMODEM_SUPPORT) += crc16.o
|
obj-$(CONFIG_SPL_YMODEM_SUPPORT) += crc16.o
|
||||||
|
@ -295,18 +295,15 @@ else
|
|||||||
FINAL_DTB_CONTAINER = $(obj)/$(SPL_BIN).multidtb.fit
|
FINAL_DTB_CONTAINER = $(obj)/$(SPL_BIN).multidtb.fit
|
||||||
endif
|
endif
|
||||||
|
|
||||||
# Build the .dtb file if:
|
# Build the .dtb file if needed
|
||||||
# - we are not using OF_PLATDATA
|
# - OF_REAL is enabled
|
||||||
# - we are using OF_CONTROL
|
|
||||||
# - we have either OF_SEPARATE or OF_HOSTFILE
|
# - we have either OF_SEPARATE or OF_HOSTFILE
|
||||||
build_dtb :=
|
build_dtb :=
|
||||||
ifeq ($(CONFIG_$(SPL_TPL_)OF_PLATDATA),)
|
ifneq ($(CONFIG_$(SPL_TPL_)OF_REAL),)
|
||||||
ifneq ($(CONFIG_$(SPL_TPL_)OF_CONTROL),)
|
|
||||||
ifeq ($(CONFIG_OF_SEPARATE)$(CONFIG_OF_HOSTFILE),y)
|
ifeq ($(CONFIG_OF_SEPARATE)$(CONFIG_OF_HOSTFILE),y)
|
||||||
build_dtb := y
|
build_dtb := y
|
||||||
endif
|
endif
|
||||||
endif
|
endif
|
||||||
endif
|
|
||||||
|
|
||||||
ifneq ($(build_dtb),)
|
ifneq ($(build_dtb),)
|
||||||
$(obj)/$(SPL_BIN)-dtb.bin: $(obj)/$(SPL_BIN)-nodtb.bin \
|
$(obj)/$(SPL_BIN)-dtb.bin: $(obj)/$(SPL_BIN)-nodtb.bin \
|
||||||
|
Loading…
Reference in New Issue
Block a user