]> git.proxmox.com Git - mirror_edk2.git/blame_incremental - Tools/Source/TianoTools/Common/PeiLib/Ipf/efijump.h
Add <FrameworkModules> in EdkModulePkg-All-Archs.fpd and MdePkg-All-Archs.fpd file...
[mirror_edk2.git] / Tools / Source / TianoTools / Common / PeiLib / Ipf / efijump.h
... / ...
CommitLineData
1/*++\r
2\r
3Copyright (c) 2004, Intel Corporation \r
4All rights reserved. This program and the accompanying materials \r
5are licensed and made available under the terms and conditions of the BSD License \r
6which accompanies this distribution. The full text of the license may be found at \r
7http://opensource.org/licenses/bsd-license.php \r
8 \r
9THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS, \r
10WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED. \r
11\r
12Module Name:\r
13 \r
14 EfiJump.h\r
15\r
16Abstract:\r
17\r
18 This is the Setjump/Longjump pair for an IA32 processor.\r
19\r
20--*/\r
21\r
22#ifndef _EFI_JUMP_H_\r
23#define _EFI_JUMP_H_\r
24\r
25#include EFI_GUID_DEFINITION (PeiTransferControl)\r
26\r
27//\r
28// NOTE:Set/LongJump needs to have this buffer start\r
29// at 16 byte boundary. Either fix the structure\r
30// which call this buffer or fix inside SetJump/LongJump\r
31// Choosing 1K buffer storage for now\r
32//\r
33typedef struct {\r
34 CHAR8 Buffer[1024];\r
35} EFI_JUMP_BUFFER;\r
36\r
37EFI_STATUS\r
38SetJump (\r
39 IN EFI_PEI_TRANSFER_CONTROL_PROTOCOL *This,\r
40 IN EFI_JUMP_BUFFER *Jump\r
41 )\r
42/*++\r
43\r
44Routine Description:\r
45\r
46 SetJump stores the current register set in the area pointed to\r
47by "save". It returns zero. Subsequent calls to "LongJump" will\r
48restore the registers and return non-zero to the same location.\r
49 On entry, r32 contains the pointer to the jmp_buffer\r
50 \r
51Arguments:\r
52 \r
53 This - Calling context\r
54 Jump - Jump buffer\r
55\r
56Returns:\r
57\r
58 Status code\r
59\r
60--*/\r
61;\r
62\r
63EFI_STATUS\r
64LongJump (\r
65 IN EFI_PEI_TRANSFER_CONTROL_PROTOCOL *This,\r
66 IN EFI_JUMP_BUFFER *Jump\r
67 )\r
68/*++\r
69\r
70Routine Description:\r
71\r
72 LongJump initializes the register set to the values saved by a\r
73previous 'SetJump' and jumps to the return location saved by that\r
74'SetJump'. This has the effect of unwinding the stack and returning\r
75for a second time to the 'SetJump'.\r
76\r
77Arguments:\r
78\r
79 This - Calling context\r
80 Jump - Jump buffer\r
81\r
82Returns:\r
83\r
84 Status code\r
85\r
86--*/\r
87;\r
88\r
89VOID\r
90RtPioICacheFlush (\r
91 IN VOID *StartAddress,\r
92 IN UINTN SizeInBytes\r
93 )\r
94/*++\r
95\r
96Routine Description:\r
97\r
98 Flushing the CPU instruction cache.\r
99\r
100Arguments:\r
101\r
102 StartAddress - Start address to flush\r
103 SizeInBytes - Length in bytes to flush\r
104\r
105Returns:\r
106\r
107 None\r
108\r
109--*/\r
110;\r
111\r
112#endif\r