V1: Assign the length and revision of UniversalPayload ExtraData V2: Force int to UINT16
Cc: Guo Dong <[email protected]> Cc: Ray Ni <[email protected]> Cc: Maurice Ma <[email protected]> Cc: Benjamin You <[email protected]> Signed-off-by: DunTan <[email protected]> --- UefiPayloadPkg/PayloadLoaderPeim/PayloadLoaderPeim.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/UefiPayloadPkg/PayloadLoaderPeim/PayloadLoaderPeim.c b/UefiPayloadPkg/PayloadLoaderPeim/PayloadLoaderPeim.c index c619470dbb..0e25bef516 100644 --- a/UefiPayloadPkg/PayloadLoaderPeim/PayloadLoaderPeim.c +++ b/UefiPayloadPkg/PayloadLoaderPeim/PayloadLoaderPeim.c @@ -110,6 +110,8 @@ PeiLoadFileLoadPayload ( sizeof (UNIVERSAL_PAYLOAD_EXTRA_DATA) + ExtraDataCount * sizeof (UNIVERSAL_PAYLOAD_EXTRA_DATA_ENTRY) ); ExtraData->Count = ExtraDataCount; + ExtraData->Header.Revision = UNIVERSAL_PAYLOAD_EXTRA_DATA_REVISION; + ExtraData->Header.Length = (UINT16) (sizeof (UNIVERSAL_PAYLOAD_EXTRA_DATA) + ExtraDataCount * sizeof (UNIVERSAL_PAYLOAD_EXTRA_DATA_ENTRY)); if (ExtraDataCount != 0) { for (ExtraDataIndex = 0, Index = 0; Index < Context.ShNum; Index++) { Status = GetElfSectionName (&Context, Index, &SectionName); -- 2.31.1.windows.1 -=-=-=-=-=-=-=-=-=-=-=- Groups.io Links: You receive all messages sent to this group. View/Reply Online (#77472): https://edk2.groups.io/g/devel/message/77472 Mute This Topic: https://groups.io/mt/83992081/21656 Group Owner: [email protected] Unsubscribe: https://edk2.groups.io/g/devel/unsub [[email protected]] -=-=-=-=-=-=-=-=-=-=-=-
