From: Ahmad Fatoum <a.fatoum@pengutronix.de>
To: barebox@lists.infradead.org
Cc: Ahmad Fatoum <a.fatoum@pengutronix.de>
Subject: [PATCH v2 1/2] scripts: gen-dtb-s: reference OF IMD entries automatically
Date: Tue, 4 Apr 2023 12:17:05 +0200 [thread overview]
Message-ID: <20230404101706.2237453-1-a.fatoum@pengutronix.de> (raw)
We currently require IMD_OF_USED to get the DT compatible into the
barebox image data meta section. As the PBL is already referencing the
DT to pass it along to barebox proper, let's add a reference from the DT
to the image data section to make IMD_OF_USED unnecessary.
Suggested-by: Antony Pavlov <antonynpavlov@gmail.com>
Signed-off-by: Ahmad Fatoum <a.fatoum@pengutronix.de>
--
v1 -> v2:
- use dword, to fix build for 64-bit (Sascha)
- place IMD reference before STRUCT_ALIGNMENT
---
scripts/gen-dtb-s | 6 ++++++
1 file changed, 6 insertions(+)
diff --git a/scripts/gen-dtb-s b/scripts/gen-dtb-s
index c5c46a4d8675..6309a814a483 100755
--- a/scripts/gen-dtb-s
+++ b/scripts/gen-dtb-s
@@ -49,6 +49,9 @@ echo "__dtb_${name}_start:"
echo ".incbin \"$dtb\""
echo "__dtb_${name}_end:"
echo ".global __dtb_${name}_end"
+if [ "$imd" = "y" ]; then
+ echo ".dword __barebox_imd_OF_${name}"
+fi
echo ".balign STRUCT_ALIGNMENT"
compressed=$(${CONFIG_SHELL} "${srctree}/scripts/file-size.sh" $dtb.z)
@@ -65,5 +68,8 @@ printf ".int 0x%08x\n" $uncompressed
echo ".incbin \"$dtb.z\""
echo "__dtb_z_${name}_end:"
echo ".global __dtb_z_${name}_end"
+if [ "$imd" = "y" ]; then
+ echo ".dword __barebox_imd_OF_${name}"
+fi
echo ".balign STRUCT_ALIGNMENT"
echo "#endif"
--
2.39.2
next reply other threads:[~2023-04-04 10:18 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2023-04-04 10:17 Ahmad Fatoum [this message]
2023-04-04 10:17 ` [PATCH v2 2/2] treewide: remove no-longer needed IMD_USED_OF Ahmad Fatoum
2023-04-11 13:10 ` [PATCH v2 1/2] scripts: gen-dtb-s: reference OF IMD entries automatically Sascha Hauer
2023-04-12 10:58 ` Sascha Hauer
2023-04-12 11:22 ` [PATCH] fixup! " Ahmad Fatoum
2023-04-12 14:12 ` Sascha Hauer
2023-04-13 7:26 ` Sascha Hauer
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=20230404101706.2237453-1-a.fatoum@pengutronix.de \
--to=a.fatoum@pengutronix.de \
--cc=barebox@lists.infradead.org \
/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