Hi Alper, On Sun, 27 Mar 2022 at 09:32, Alper Nebi Yasak <alpernebiya...@gmail.com> wrote: > > When reading images from a file, each entry's data is read from its > parent section as specified in the Entry.Create() call that created it. > The FIT entry type has been creating its subentries under its parent > (their grandparent), as creating them under the FIT entry resulted in an > error until FIT was converted into a proper section. > > FIT subentries have their offsets relative to the FIT section, and > reading those offsets in the parent section results in wrong data. The > subentries rightfully belong under the FIT entries, so create them > there. Add tests checking that we can extract the correct data for a FIT > entry and its subentries. > > Signed-off-by: Alper Nebi Yasak <alpernebiya...@gmail.com> > --- > > tools/binman/etype/fit.py | 2 +- > tools/binman/ftest.py | 35 +++++++++ > tools/binman/test/233_fit_extract_replace.dts | 74 +++++++++++++++++++ > 3 files changed, 110 insertions(+), 1 deletion(-) > create mode 100644 tools/binman/test/233_fit_extract_replace.dts
Reviewed-by: Simon Glass <s...@chromium.org> It's great to be able to replace data in FITs. It's quite a complex case, but very useful I think. Regards, Simon