]> git.proxmox.com Git - mirror_edk2.git/commit
ArmPkg/ArmExceptionLib: use static buffer for sp_el0
authorHeyi Guo <guoheyi@linux.alibaba.com>
Tue, 9 Jun 2020 01:26:30 +0000 (09:26 +0800)
committermergify[bot] <37929162+mergify[bot]@users.noreply.github.com>
Wed, 10 Jun 2020 18:06:45 +0000 (18:06 +0000)
commite1d24410da356731da70b3334f86343e11e207d2
tree60fc661f433ff225e1290ce51ea8301823d3a35d
parent14c7ed8b51f60097ad771277da69f74b22a7a759
ArmPkg/ArmExceptionLib: use static buffer for sp_el0

The exception library is also used in DxeMain before memory services
are available, and AllocatePages() will fail in this case and cause
sp_el0 remains 0. Then if any exception occurs before CpuDxe driver is
loaded, a recursive exception will be trigged by page translation
fault for sp = 0 - 0x130.

Use static buffer instead to fix this issue.

Signed-off-by: Heyi Guo <guoheyi@linux.alibaba.com>
Reviewed-by: Ard Biesheuvel <ard.biesheuvel@arm.com>
ArmPkg/Library/ArmExceptionLib/AArch64/AArch64Exception.c