aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorRasmus Villemoes <rasmus.villemoes@prevas.dk>2023-05-04 13:33:08 +0200
committerTom Rini <trini@konsulko.com>2023-05-15 14:08:44 -0400
commit6923f49d3ac29ac55845895887da1bfc8534de00 (patch)
tree41d5dc0ff1ecca442dc992b13aafbc3f86df471f
parentf07381529bf69f14abd18cd3bd47982f466e179f (diff)
downloadu-boot-6923f49d3ac29ac55845895887da1bfc8534de00.zip
u-boot-6923f49d3ac29ac55845895887da1bfc8534de00.tar.gz
u-boot-6923f49d3ac29ac55845895887da1bfc8534de00.tar.bz2
scripts/Makefile.dts: tweak logic for deciding which dtbs to build
The idea in 3609e1dc5f4d (dts: automatically build necessary .dtb files) was fine, but the implementation was suboptimal due to some misunderstandings on my part (and possibly defects in some defconfig files): - Sometimes DEFAULT_DEVICE_TREE is not included in OF_LIST or SPL_OF_LIST - SPL_OF_LIST is not always a subset of OF_LIST - While SPL_OF_LIST governs the list of dtbs relevant to SPL (i.e., may be built into an SPL-with-bunch-of-dtbs-to-choose-between-at-runtime), those dtbs are not actually _built_ during the SPL build phase, i.e. when $(SPL_) would expand to SPL_. fdtgrep runs on the artifacts produced during the ordinary U-Boot build. Tweak the logic so that we simply add the union of all dtbs mentioned in either DEFAULT_DEVICE_TREE, OF_LIST and SPL_OF_LIST to dtb-y. That should, for real, ensure that we always build all the dtbs that is relevant to the current board, and should in turn enable us to massively simplify arch/*/dts/Makefile. Signed-off-by: Rasmus Villemoes <rasmus.villemoes@prevas.dk> Tested-by: Tom Rini <trini@konsulko.com> Reviewed-by: Simon Glass <sjg@chromium.org>
-rw-r--r--scripts/Makefile.dts2
1 files changed, 1 insertions, 1 deletions
diff --git a/scripts/Makefile.dts b/scripts/Makefile.dts
index 2561025..5e2429c 100644
--- a/scripts/Makefile.dts
+++ b/scripts/Makefile.dts
@@ -1,3 +1,3 @@
# SPDX-License-Identifier: GPL-2.0+
-dtb-y += $(patsubst %,%.dtb,$(subst ",,$(CONFIG_$(SPL_)OF_LIST)))
+dtb-y += $(patsubst %,%.dtb,$(subst ",,$(CONFIG_DEFAULT_DEVICE_TREE) $(CONFIG_OF_LIST) $(CONFIG_SPL_OF_LIST)))