]> git.proxmox.com Git - mirror_edk2.git/blob - MdePkg/Library/BaseCpuLib/Ia32/CpuSleepGcc.c
MdePkg: Replace BSD License with BSD+Patent License
[mirror_edk2.git] / MdePkg / Library / BaseCpuLib / Ia32 / CpuSleepGcc.c
1 /** @file
2 CpuSleep function for Ia32/X64 GCC.
3
4 Copyright (c) 2006 - 2008, Intel Corporation. All rights reserved.<BR>
5 Portions copyright (c) 2008 - 2009, Apple Inc. All rights reserved.<BR>
6 SPDX-License-Identifier: BSD-2-Clause-Patent
7
8 **/
9
10
11 /**
12 Places the CPU in a sleep state until an interrupt is received.
13
14 Places the CPU in a sleep state until an interrupt is received. If interrupts
15 are disabled prior to calling this function, then the CPU will be placed in a
16 sleep state indefinitely.
17
18 **/
19 VOID
20 EFIAPI
21 CpuSleep (
22 VOID
23 )
24 {
25 __asm__ __volatile__ ("hlt"::: "memory");
26 }
27