U-Boot Archive on lore.kernel.org
 help / color / mirror / Atom feed
From: E Shattow <e@freeshell.de>
To: Tom Rini <trini@konsulko.com>
Cc: u-boot@lists.denx.de, E Shattow <e@freeshell.de>
Subject: [PATCH v1] [v1] scripts/Makefile.lib: increase detail for dtsi debug output
Date: Wed, 27 Aug 2025 23:51:51 -0700	[thread overview]
Message-ID: <20250828065159.486850-1-e@freeshell.de> (raw)

Detailed dtsi automatic selection debug output when DEVICE_TREE_DEBUG=1
  - Indicate when key is undefined and skip undefined search pattern
  - Indicate when search pattern is found or not found, and the pattern
  - Show values of defined keys

Signed-off-by: E Shattow <e@freeshell.de>
---
 scripts/Makefile.lib | 29 ++++++++++++++++++++++++++---
 1 file changed, 26 insertions(+), 3 deletions(-)

diff --git a/scripts/Makefile.lib b/scripts/Makefile.lib
index 5db2fbc418a..3cbb20e6b9d 100644
--- a/scripts/Makefile.lib
+++ b/scripts/Makefile.lib
@@ -203,13 +203,36 @@ u_boot_dtsi_options = $(strip $(wildcard $(u_boot_dtsi_loc)$(basename $(notdir $
 	$(wildcard $(u_boot_dtsi_loc)$(subst $\",,$(CONFIG_SYS_VENDOR))-u-boot.dtsi) \
 	$(wildcard $(u_boot_dtsi_loc)u-boot.dtsi))
 
-u_boot_dtsi_options_raw = $(warning Automatic .dtsi inclusion: options: \
+u_boot_dtsi_options_raw = $(warning Automatic inclusion \
+	$(or $(u_boot_dtsi_options),(undefined)) from search order: \
+	$$<=$(if \
+	$(<),$(<) $(if $(wildcard \
 	$(u_boot_dtsi_loc)$(basename $(notdir $<))-u-boot.dtsi \
+	),,not) found @ \
+	$(u_boot_dtsi_loc)$(basename $(notdir $<))-u-boot.dtsi \
+	,(undefined)) || \
+	$$CONFIG_SYS_SOC=$(if \
+	$(CONFIG_SYS_SOC),$(CONFIG_SYS_SOC) $(if $(wildcard \
+	$(u_boot_dtsi_loc)$(subst $\",,$(CONFIG_SYS_SOC))-u-boot.dtsi \
+	),,not) found @ \
 	$(u_boot_dtsi_loc)$(subst $\",,$(CONFIG_SYS_SOC))-u-boot.dtsi \
+	,(undefined)) || \
+	$$CONFIG_SYS_CPU=$(if \
+	$(CONFIG_SYS_CPU),$(CONFIG_SYS_CPU) $(if $(wildcard \
 	$(u_boot_dtsi_loc)$(subst $\",,$(CONFIG_SYS_CPU))-u-boot.dtsi \
+	),,not) found @ \
+	$(u_boot_dtsi_loc)$(subst $\",,$(CONFIG_SYS_CPU))-u-boot.dtsi \
+	,(undefined)) || \
+	$$CONFIG_SYS_VENDOR=$(if \
+	$(CONFIG_SYS_VENDOR),$(CONFIG_SYS_VENDOR) $(if $(wildcard \
+	$(u_boot_dtsi_loc)$(subst $\",,$(CONFIG_SYS_VENDOR))-u-boot.dtsi \
+	),,not) found @ \
 	$(u_boot_dtsi_loc)$(subst $\",,$(CONFIG_SYS_VENDOR))-u-boot.dtsi \
-	$(u_boot_dtsi_loc)u-boot.dtsi ... \
-	found: $(if $(u_boot_dtsi_options),"$(u_boot_dtsi_options)",nothing!))
+	,(undefined)) || \
+	"u-boot.dtsi" $(if $(wildcard \
+	$(u_boot_dtsi_loc)u-boot.dtsi \
+	),,not) found @ \
+	$(u_boot_dtsi_loc)u-boot.dtsi)
 
 # Uncomment for debugging
 # This shows all the files that were considered and the one that we chose.

base-commit: 3dc5e9a0108bb114175b6362f9cb22367402f624
-- 
2.50.0


             reply	other threads:[~2025-08-28  6:53 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2025-08-28  6:51 E Shattow [this message]
2025-09-01  3:40 ` [PATCH v1] [v1] scripts/Makefile.lib: increase detail for dtsi debug output E Shattow

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20250828065159.486850-1-e@freeshell.de \
    --to=e@freeshell.de \
    --cc=trini@konsulko.com \
    --cc=u-boot@lists.denx.de \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox