]> git.proxmox.com Git - mirror_edk2.git/commit
ArmPkg/AsmMacroIoLibV8: remove undocumented assumption from ELx macros
authorArd Biesheuvel <ard.biesheuvel@linaro.org>
Thu, 17 Mar 2016 08:07:28 +0000 (09:07 +0100)
committerArd Biesheuvel <ard.biesheuvel@linaro.org>
Tue, 22 Mar 2016 13:39:01 +0000 (14:39 +0100)
commita34608ca9670e07d8a4b6de2914b2960132d4b16
tree2f6e00f8792682634ae704c7f22e6ccf6dc40d90
parent725cdb8fbfb034cd73574ed9c356b0dca14ff843
ArmPkg/AsmMacroIoLibV8: remove undocumented assumption from ELx macros

The macros EL1_OR_EL2() and EL1_OR_EL2_OR_EL3() allow conditional execution
of assembly sequences based on the current exception level, by jumping to
caller supplied labels 1f, 2f or 3f. However, the jump to 1f is actually
a fallthrough, which means the EL1 code needs to follow right after the
macro invocation, and the 1f label is ignored.

So let's fix this by making all jumps explicit.

Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Ard Biesheuvel <ard.biesheuvel@linaro.org>
Reviewed-by: Leif Lindholm <leif.lindholm@linaro.org>
Reviewed-by: Eugene Cohen <eugene@hp.com>
ArmPkg/Include/AsmMacroIoLibV8.h