MdePkg/BaseCpuLib AARCH64: Make asm files BTI compatible

Add the BTI instructions and the associated note to make the AArch64 asm
objects compatible with BTI enforcement.

Signed-off-by: Ard Biesheuvel <ardb@kernel.org>
Reviewed-by: Leif Lindholm <quic_llindhol@quicinc.com>
Reviewed-by: Oliver Smith-Denny <osd@smith-denny.com>
This commit is contained in:
Ard Biesheuvel 2023-03-25 17:34:58 +01:00 committed by Mikhail Krichanov
parent 010d2e0ff5
commit 3310b2120f
2 changed files with 2 additions and 0 deletions

View File

@ -26,6 +26,7 @@ GCC_ASM_EXPORT(CpuFlushTlb)
# )#
#
ASM_PFX(CpuFlushTlb):
AARCH64_BTI(c)
tlbi vmalle1 // Invalidate Inst TLB and Data TLB
dsb sy
isb

View File

@ -29,5 +29,6 @@ GCC_ASM_EXPORT(CpuSleep)
#
ASM_PFX(CpuSleep):
AARCH64_BTI(c)
wfi
ret