]> git.proxmox.com Git - mirror_edk2.git/commitdiff
UefiPayloadPkg: Align Attribute value with UPL spec
authorGua Guo <gua.guo@intel.com>
Mon, 27 Jun 2022 03:05:08 +0000 (11:05 +0800)
committermergify[bot] <37929162+mergify[bot]@users.noreply.github.com>
Thu, 30 Jun 2022 03:45:38 +0000 (03:45 +0000)
REF: https://bugzilla.tianocore.org/show_bug.cgi?id=3963

Based on UPL spec 2.12.2. Universal Payload Information Section,
it defines item "Attribute" on UPLD_INFO_HEADER for Debug build
should be "1", and Release build should be "0".

Currently, The value of item "Attribute" is always "0"

Cc: Guo Dong <guo.dong@intel.com>
Reviewed-by: Ray Ni <ray.ni@intel.com>
Cc: James Lu <james.lu@intel.com>
Signed-off-by: Gua Guo <gua.guo@intel.com>
UefiPayloadPkg/UniversalPayloadBuild.py

index ab4c977ba52190910dca9dc48dca0734023efa3a..6003de36d13915a42e265834ddd0d8969f7ef53a 100644 (file)
@@ -111,6 +111,7 @@ def BuildUniversalPayload(Args, MacroList):
     #\r
     upld_info_hdr = UPLD_INFO_HEADER()\r
     upld_info_hdr.ImageId = Args.ImageId.encode()[:16]\r
+    upld_info_hdr.Attribute |= 1 if BuildTarget == "DEBUG" else 0\r
     fp = open(UpldInfoFile, 'wb')\r
     fp.write(bytearray(upld_info_hdr))\r
     fp.close()\r