]> git.proxmox.com Git - mirror_edk2.git/blame - MdePkg/Library/BaseLib/Ipf/CpuBreakpoint.c
Fix MASM build break
[mirror_edk2.git] / MdePkg / Library / BaseLib / Ipf / CpuBreakpoint.c
CommitLineData
878ddf1f 1/** @file\r
2 Base Library CPU functions for Itanium\r
3\r
4 Copyright (c) 2006, Intel Corporation<BR>\r
5 All rights reserved. This program and the accompanying materials\r
6 are licensed and made available under the terms and conditions of the BSD License\r
7 which accompanies this distribution. The full text of the license may be found at\r
8 http://opensource.org/licenses/bsd-license.php\r
9\r
10 THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,\r
11 WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.\r
12\r
13**/\r
14\r
15//void __mfa (void);\r
16\r
17#pragma intrinsic (_enable)\r
18#pragma intrinsic (_disable)\r
19#pragma intrinsic (__break)\r
20#pragma intrinsic (__mfa)\r
21\r
22/**\r
23 Generates a breakpoint on the CPU.\r
24\r
25 Generates a breakpoint on the CPU. The breakpoint must be implemented such\r
26 that code can resume normal execution after the breakpoint.\r
27\r
28**/\r
29VOID\r
30EFIAPI\r
31CpuBreakpoint (\r
32 VOID\r
33 )\r
34{\r
35 __break (0);\r
36}\r
37\r
38/**\r
39 Used to serialize load and store operations.\r
40\r
41 All loads and stores that proceed calls to this function are guaranteed to be\r
42 globally visible when this function returns.\r
43\r
44**/\r
45VOID\r
46EFIAPI\r
47MemoryFence (\r
48 VOID\r
49 )\r
50{\r
51 __mfa ();\r
52}\r
53\r
54/**\r
55 Disables CPU interrupts.\r
56\r
57 Disables CPU interrupts.\r
58\r
59**/\r
60VOID\r
61EFIAPI\r
62DisableInterrupts (\r
63 VOID\r
64 )\r
65{\r
66 _disable ();\r
67}\r
68\r
69/**\r
70 Enables CPU interrupts.\r
71\r
72 Enables CPU interrupts.\r
73\r
74**/\r
75VOID\r
76EFIAPI\r
77EnableInterrupts (\r
78 VOID\r
79 )\r
80{\r
81 _enable ();\r
82}\r
83\r
84/**\r
85 Retrieves the current CPU interrupt state.\r
86\r
87 Retrieves the current CPU interrupt state. Returns TRUE is interrupts are\r
88 currently enabled. Otherwise returns FALSE.\r
89\r
90 @retval TRUE CPU interrupts are enabled.\r
91 @retval FALSE CPU interrupts are disabled.\r
92\r
93**/\r
94BOOLEAN\r
95EFIAPI\r
96GetInterruptState (\r
97 VOID\r
98 )\r
99{\r
100 return FALSE;\r
101}\r