summaryrefslogtreecommitdiff
path: root/MdeModulePkg/Library/PiDxeS3BootScriptLib/BootScriptInternalFormat.h
diff options
context:
space:
mode:
authorJohnny.Fan <Johnny.Fan@cixtech.com>2026-07-07 12:11:34 +0300
committermergify[bot] <37929162+mergify[bot]@users.noreply.github.com>2026-08-12 11:13:56 +0300
commit2970e5699ba6267f3384ffab20f96647578aebc8 (patch)
tree81246904188186c97db1b2639850765615c7ec47 /MdeModulePkg/Library/PiDxeS3BootScriptLib/BootScriptInternalFormat.h
parent86ecae29c69ee6b4fd471ff395989c358bbec14e (diff)
downloadedk2-2970e5699ba6267f3384ffab20f96647578aebc8.tar.xz
EmbeddedPkg/AcpiLib: Fix memory corruption in AcpiAmlObjectUpdateIntegeredk2-stable202608
The original implementation of AcpiAmlObjectUpdateInteger had a critical bug when updating integer objects that were encoded with AML_ZERO_OP(0x00) or AML_ONE_OP(0x01), which are 1-byte optimized encodings. When the caller tried to update such an object to a value other than 0 or 1, the code would: 1. Overwrite the opcode byte with the new value's LSB 2. This changed the opcode itself, e.g. 0x0B becomes AML_WORD_PREFIX 3. Subsequent AML bytes (name segments of following objects) get misinterpreted as integer data 4. Result: silent AML structure is silently corrupted, causing the OS to fail parsing ACPI tables and eventually crash. The fix: 1. Only allow 0 -> 0 or 1 updates using the original 1-byte encoding 2. For any other value, explicitly fail with a diagnostic 3. Provide clear debug instructions on how to fix the ASL source Reviewed-by: jie.fu <jie.fu@cixtech.com> Signed-off-by: Johnny.Fan <Johnny.Fan@cixtech.com>
Diffstat (limited to 'MdeModulePkg/Library/PiDxeS3BootScriptLib/BootScriptInternalFormat.h')
0 files changed, 0 insertions, 0 deletions