Branch: refs/heads/master
  Home:   https://github.com/tianocore/edk2
  Commit: e93ee87643a30df3bffede2f4cdadfc7be88f0bd
      
https://github.com/tianocore/edk2/commit/e93ee87643a30df3bffede2f4cdadfc7be88f0bd
  Author: Evgenii Shatokhin <[email protected]>
  Date:   2025-11-22 (Sat, 22 Nov 2025)

  Changed paths:
    M BaseTools/Source/Python/FMMT/core/FvHandler.py

  Log Message:
  -----------
  BaseTools: FMMT: Fix incorrect size calculation in ModifyTest()

There is another issue in FvHander.py similar to the one fixed by
a60334ad59eb ("BaseTools: Fix FMMT FvHandler Padding operation issue").

For a guided section (ParTree.Data.Type == 0x02), the length of
ParTree.Data.OriData is used to obtain the original size of the data even
after ParTree.Data.OriData has changed, which is incorrect.

This caused the following issue I observed. I built OVMF image for Aarch64
and then tried to add a couple FFS modules to it with 'FMMT -a [...]'. The
resulting image turned out to be invalid: the total size of the image was
less than the size of the firmware volume within it.

UEFITool failed to load such firmware image and complained:
"parseRawArea: one of objects inside overlaps the end of data".

This patch fixes the issue.

Signed-off-by: Evgenii Shatokhin <[email protected]>



To unsubscribe from these emails, change your notification settings at 
https://github.com/tianocore/edk2/settings/notifications


_______________________________________________
edk2-commits mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/edk2-commits

Reply via email to