aboutsummaryrefslogtreecommitdiff
path: root/tools
diff options
context:
space:
mode:
authorMathieu Othacehe <m.othacehe@gmail.com>2023-12-29 12:02:18 +0100
committerFabio Estevam <festevam@gmail.com>2024-01-08 14:37:53 -0300
commitf637dfe8c468229c9fb313d13c46d51cdbb88824 (patch)
tree3e946c66e1280b5a07695e3a6c12eab6138e1c6b /tools
parentda96f93cda90213f20cb81e484b03055d233a054 (diff)
downloadu-boot-f637dfe8c468229c9fb313d13c46d51cdbb88824.zip
u-boot-f637dfe8c468229c9fb313d13c46d51cdbb88824.tar.gz
u-boot-f637dfe8c468229c9fb313d13c46d51cdbb88824.tar.bz2
mach-imx: Add i.MX93 binman support.
Add dedicated Makefile targets for the i.MX93 and a new imx93-u-boot.dtsi device-tree to create binman images. Signed-off-by: Mathieu Othacehe <m.othacehe@gmail.com>
Diffstat (limited to 'tools')
-rwxr-xr-xtools/imx9_image.sh31
1 files changed, 31 insertions, 0 deletions
diff --git a/tools/imx9_image.sh b/tools/imx9_image.sh
new file mode 100755
index 0000000..88dfcfe
--- /dev/null
+++ b/tools/imx9_image.sh
@@ -0,0 +1,31 @@
+#!/bin/sh
+# SPDX-License-Identifier: GPL-2.0+
+#
+# Script to check whether the file exists in mkimage cfg files for the i.MX9.
+#
+# usage: $0 <file.cfg>
+
+file=$1
+
+blobs=`awk '/^APPEND/ {print $2} /^IMAGE/ || /^DATA/ {print $3}' $file`
+for f in $blobs; do
+ tmp=$srctree/$f
+ if [ $f = "u-boot-spl-ddr.bin" ]; then
+ continue
+ fi
+
+ if [ -f $f ]; then
+ continue
+ fi
+
+ if [ ! -f $tmp ]; then
+ echo "WARNING '$tmp' not found, resulting binary is not-functional" >&2
+
+ # Comment-out the lines for un-existing files. This way,
+ # mkimage can keep working. This allows CI tests to pass even
+ # if the resulting binary won't boot.
+ sed -in "/$f/ s/./#&/" $file
+ fi
+done
+
+exit 0