]> git.proxmox.com Git - mirror_edk2.git/blame - MdePkg/Library/BaseLib/AArch64/SpeculationBarrier.S
MdePkg: Replace BSD License with BSD+Patent License
[mirror_edk2.git] / MdePkg / Library / BaseLib / AArch64 / SpeculationBarrier.S
CommitLineData
c0959b44
AB
1##------------------------------------------------------------------------------\r
2#\r
3# SpeculationBarrier() for AArch64\r
4#\r
5# Copyright (c) 2019, Linaro Ltd. All rights reserved.\r
6#\r
9344f092 7# SPDX-License-Identifier: BSD-2-Clause-Patent\r
c0959b44
AB
8#\r
9##------------------------------------------------------------------------------\r
10\r
11.text\r
12.p2align 2\r
13\r
14GCC_ASM_EXPORT(SpeculationBarrier)\r
15\r
16\r
17#/**\r
18# Uses as a barrier to stop speculative execution.\r
19#\r
20# Ensures that no later instruction will execute speculatively, until all prior\r
21# instructions have completed.\r
22#\r
23#**/\r
24#VOID\r
25#EFIAPI\r
26#SpeculationBarrier (\r
27# VOID\r
28# );\r
29#\r
30ASM_PFX(SpeculationBarrier):\r
31 dsb sy\r
32 isb\r
33 ret\r