[PATCH v4 08/11] tools: binman: Add a test for boot and load extensions

Beleswar Padhi b-padhi at ti.com
Sat Apr 25 05:37:39 CEST 2026


Add test coverage for the boot and load extension functionality in
ti-secure certificates. This verifies that a certificate can be
generated having boot and load extensions.

Signed-off-by: Beleswar Padhi <b-padhi at ti.com>
---
Cc: Simon Glass <sjg at chromium.org>

v4: Changelog:
1. New patch. Added binman test for load & boot extensions in
   certificate.

 tools/binman/ftest.py                         | 10 ++++++++
 .../test/vendor/ti_secure_boot_load_ext.dts   | 23 +++++++++++++++++++
 2 files changed, 33 insertions(+)
 create mode 100644 tools/binman/test/vendor/ti_secure_boot_load_ext.dts

diff --git a/tools/binman/ftest.py b/tools/binman/ftest.py
index ca5149ee654..f36d760375d 100644
--- a/tools/binman/ftest.py
+++ b/tools/binman/ftest.py
@@ -7270,6 +7270,16 @@ fdt         fdtmap                Extract the devicetree blob from the fdtmap
                                 entry_args=entry_args)[0]
         self.assertGreater(len(data), len(TI_UNSECURE_DATA))
 
+    def testPackTiSecureBootLoadExt(self):
+        """Test that an image with TI secured binary having boot & load extensions can be created"""
+        keyfile = self.TestFile('security/key.key')
+        entry_args = {
+            'keyfile': keyfile,
+        }
+        data = self._DoReadFileDtb('vendor/ti_secure_boot_load_ext.dts',
+                                   entry_args=entry_args)[0]
+        self.assertGreater(len(data), len(TI_UNSECURE_DATA))
+
     def testEncryptedNoAlgo(self):
         """Test encrypted node with missing required properties"""
         with self.assertRaises(ValueError) as e:
diff --git a/tools/binman/test/vendor/ti_secure_boot_load_ext.dts b/tools/binman/test/vendor/ti_secure_boot_load_ext.dts
new file mode 100644
index 00000000000..5c29d18e627
--- /dev/null
+++ b/tools/binman/test/vendor/ti_secure_boot_load_ext.dts
@@ -0,0 +1,23 @@
+// SPDX-License-Identifier: GPL-2.0+
+
+/dts-v1/;
+
+/ {
+	#address-cells = <1>;
+	#size-cells = <1>;
+
+	binman {
+		ti-secure {
+			content = <&unsecure_binary>;
+			proc_id = <0x20>;
+			flags_set = <0x00000001>;
+			flags_clr = <0x00000002>;
+			reset_vector = <0x70000000>;
+			dest_addr = <0x80000000>;
+			auth_type = <0x02>;
+		};
+		unsecure_binary: blob-ext {
+			filename = "ti_unsecure.bin";
+		};
+	};
+};
-- 
2.34.1



More information about the U-Boot mailing list