linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH] cmd_dtc: Enable generation of device tree symbols
@ 2021-01-25 10:57 Uwe Kleine-König
  2021-01-25 11:15 ` Cyril Brulebois
                   ` (2 more replies)
  0 siblings, 3 replies; 12+ messages in thread
From: Uwe Kleine-König @ 2021-01-25 10:57 UTC (permalink / raw)
  To: Masahiro Yamada, Michal Marek
  Cc: linux-kbuild, linux-kernel, linux-arm-kernel, cyril,
	Arnd Bergmann, Maxime Ripard

Adding the -@ switch to dtc results in the binary devicetrees containing
a list of symbolic references and their paths. This is necessary to
apply device tree overlays e.g. on Raspberry Pi as described on
https://www.raspberrypi.org/documentation/configuration/device-tree.md.

Obviously the downside of this change is an increas of the size of the
generated dtbs, for an arm out-of-tree build (multi_v7_defconfig):

	$ du -s arch/arm/boot/dts*
	101380	arch/arm/boot/dts-pre
	114308	arch/arm/boot/dts-post

so this is in average an increase of 12.8% in size.

Signed-off-by: Uwe Kleine-König <uwe@kleine-koenig.org>
---
 scripts/Makefile.lib | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/scripts/Makefile.lib b/scripts/Makefile.lib
index 213677a5ed33..0683a5808f7f 100644
--- a/scripts/Makefile.lib
+++ b/scripts/Makefile.lib
@@ -319,7 +319,7 @@ $(obj)/%.dtb.S: $(obj)/%.dtb FORCE
 
 quiet_cmd_dtc = DTC     $@
 cmd_dtc = $(HOSTCC) -E $(dtc_cpp_flags) -x assembler-with-cpp -o $(dtc-tmp) $< ; \
-	$(DTC) -O $(patsubst .%,%,$(suffix $@)) -o $@ -b 0 \
+	$(DTC) -@ -O $(patsubst .%,%,$(suffix $@)) -o $@ -b 0 \
 		$(addprefix -i,$(dir $<) $(DTC_INCLUDE)) $(DTC_FLAGS) \
 		-d $(depfile).dtc.tmp $(dtc-tmp) ; \
 	cat $(depfile).pre.tmp $(depfile).dtc.tmp > $(depfile)
-- 
2.29.2


^ permalink raw reply related	[flat|nested] 12+ messages in thread

end of thread, other threads:[~2021-01-27  7:09 UTC | newest]

Thread overview: 12+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-01-25 10:57 [PATCH] cmd_dtc: Enable generation of device tree symbols Uwe Kleine-König
2021-01-25 11:15 ` Cyril Brulebois
2021-01-26 18:01   ` Frank Rowand
2021-01-25 21:53 ` Masahiro Yamada
2021-01-26  7:20   ` Uwe Kleine-König
2021-01-26  8:43     ` Geert Uytterhoeven
2021-01-26 18:03       ` Frank Rowand
2021-01-26 13:42     ` Rob Herring
2021-01-26 18:03     ` Frank Rowand
2021-01-26 18:26       ` Frank Rowand
2021-01-26 18:02   ` Frank Rowand
2021-01-26 18:01 ` Frank Rowand

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).