summaryrefslogtreecommitdiff
path: root/tools/binman/test/189_vblock_content.dts
diff options
context:
space:
mode:
authorSimon Glass <sjg@chromium.org>2021-01-06 21:35:17 -0700
committerSimon Glass <sjg@chromium.org>2021-01-30 14:25:41 -0700
commit5af9ebc4bcbcca91b21257c18cb94c78e7356980 (patch)
tree517a599dd61cef56a2249c3eae4074239c59b9f0 /tools/binman/test/189_vblock_content.dts
parent939d1062d05fb4990ca7898613bcc753574f7c56 (diff)
downloadu-boot-5af9ebc4bcbcca91b21257c18cb94c78e7356980.tar.gz
binman: Allow vblock to include devicetree blobs
At present if a devicetree blob is included in a vblock it does not deal with updates. This is because the vblock is created once at the start and does not have a method to update itself later, after all the entry contents are finalised. Fix this by adjusting how the vblock is created. Also simplify Image.ProcessEntryContents() since it effectively duplicates the code in Section.ProcessContents(). Signed-off-by: Simon Glass <sjg@chromium.org>
Diffstat (limited to 'tools/binman/test/189_vblock_content.dts')
-rw-r--r--tools/binman/test/189_vblock_content.dts31
1 files changed, 31 insertions, 0 deletions
diff --git a/tools/binman/test/189_vblock_content.dts b/tools/binman/test/189_vblock_content.dts
new file mode 100644
index 0000000000..dcc74449c1
--- /dev/null
+++ b/tools/binman/test/189_vblock_content.dts
@@ -0,0 +1,31 @@
+// SPDX-License-Identifier: GPL-2.0+
+/dts-v1/;
+
+/ {
+ #address-cells = <1>;
+ #size-cells = <1>;
+
+ binman {
+ u_boot: u-boot {
+ };
+
+ dtb: u-boot-dtb {
+ };
+
+ /*
+ * Put the vblock after the dtb so that the dtb is updated
+ * before the vblock reads its data. At present binman does not
+ * understand dependencies between entries, but simply
+ * iterates again when it thinks something needs to be
+ * recalculated.
+ */
+ vblock {
+ content = <&u_boot &dtb>;
+ keyblock = "firmware.keyblock";
+ signprivate = "firmware_data_key.vbprivk";
+ version = <1>;
+ kernelkey = "kernel_subkey.vbpubk";
+ preamble-flags = <1>;
+ };
+ };
+};