[PATCH 4/9] binman: Override CheckOptional in fit entry

Jonas Karlman
2023-02-19T22:02:36Z

Missing optional blobs was not reported for generated entries, e.g.
tee-os on rockchip targets. Implement a CheckOptional to fix this.

After this the following can be shown:

Image 'simple-bin' is missing external blobs but is still functional: tee-os

/binman/simple-bin/fit/images/@tee-SEQ/tee-os (tee-os):
See the documentation for your board. You may need to build Open Portable
Trusted Execution Environment (OP-TEE) with TEE=/path/to/tee.bin

Signed-off-by: Jonas Karlman <jonas@kwiboo.se>
---
tools/binman/etype/fit.py | 7 +++++++
1 file changed, 7 insertions(+)

diff --git a/tools/binman/etype/fit.py b/tools/binman/etype/fit.py
index 822de7982768..314e03b4a964 100644
--- a/tools/binman/etype/fit.py
+++ b/tools/binman/etype/fit.py
@@ -828,3 +828,10 @@ class Entry_fit(Entry_section):
# missing
for entry in self._priv_entries.values():
entry.CheckMissing(missing_list)
+
+ def CheckOptional(self, optional_list):
+ # We must use our private entry list for this since generator nodes
+ # which are removed from self._entries will otherwise not show up as
+ # optional
+ for entry in self._priv_entries.values():
+ entry.CheckOptional(optional_list)
--
2.39.2