]> git.proxmox.com Git - mirror_edk2.git/blame - EdkCompatibilityPkg/Foundation/Library/Pei/PeiLib/Ipf/Processor.c
Update the copyright notice format
[mirror_edk2.git] / EdkCompatibilityPkg / Foundation / Library / Pei / PeiLib / Ipf / Processor.c
CommitLineData
3eb9473e 1/*++\r
2\r
4ea9375a
HT
3Copyright (c) 2004, Intel Corporation. All rights reserved.<BR>\r
4This program and the accompanying materials \r
3eb9473e 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 Processor.c\r
15\r
16Abstract:\r
17\r
18--*/\r
19\r
20#include "Tiano.h"\r
21#include "EfiJump.h"\r
22#include "PeiHob.h"\r
23#include EFI_GUID_DEFINITION (PeiFlushInstructionCache)\r
24#include EFI_GUID_DEFINITION (PeiTransferControl)\r
25\r
26EFI_STATUS\r
27WinNtFlushInstructionCacheFlush (\r
28 IN EFI_PEI_FLUSH_INSTRUCTION_CACHE_PROTOCOL *This,\r
29 IN EFI_PHYSICAL_ADDRESS Start,\r
30 IN UINT64 Length\r
31 );\r
32\r
33EFI_PEI_TRANSFER_CONTROL_PROTOCOL mTransferControl = {\r
89f04816 34 (EFI_PEI_TRANSFER_CONTROL_SET_JUMP) SetJump,\r
35 (EFI_PEI_TRANSFER_CONTROL_LONG_JUMP) LongJump,\r
3eb9473e 36 sizeof (EFI_JUMP_BUFFER)\r
37};\r
38\r
39EFI_PEI_FLUSH_INSTRUCTION_CACHE_PROTOCOL mFlushInstructionCache = {\r
40 WinNtFlushInstructionCacheFlush\r
41};\r
42\r
43EFI_STATUS\r
44InstallEfiPeiTransferControl (\r
45 IN OUT EFI_PEI_TRANSFER_CONTROL_PROTOCOL **This\r
46 )\r
47/*++\r
48\r
49Routine Description:\r
50\r
51 Installs the pointer to the transfer control mechanism\r
52\r
53Arguments:\r
54\r
55 This - Pointer to transfer control mechanism.\r
56\r
57Returns:\r
58\r
59 EFI_SUCCESS - Successfully installed.\r
60\r
61--*/\r
62{\r
63 *This = &mTransferControl;\r
64 return EFI_SUCCESS;\r
65}\r
66\r
67EFI_STATUS\r
68InstallEfiPeiFlushInstructionCache (\r
69 IN OUT EFI_PEI_FLUSH_INSTRUCTION_CACHE_PROTOCOL **This\r
70 )\r
71/*++\r
72\r
73Routine Description:\r
74\r
75 Installs the pointer to the flush instruction cache mechanism\r
76\r
77Arguments:\r
78\r
79 This - Pointer to flush instruction cache mechanism.\r
80\r
81Returns:\r
82\r
83 EFI_SUCCESS - Successfully installed\r
84\r
85--*/\r
86{\r
87 *This = &mFlushInstructionCache;\r
88 return EFI_SUCCESS;\r
89}\r
90\r
91EFI_STATUS\r
92WinNtFlushInstructionCacheFlush (\r
93 IN EFI_PEI_FLUSH_INSTRUCTION_CACHE_PROTOCOL *This,\r
94 IN EFI_PHYSICAL_ADDRESS Start,\r
95 IN UINT64 Length\r
96 )\r
97/*++\r
98\r
99Routine Description:\r
100\r
101 This routine would provide support for flushing the CPU instruction cache.\r
102\r
103Arguments:\r
104\r
105 This - Pointer to CPU Architectural Protocol interface\r
106 Start - Start adddress in memory to flush\r
107 Length - Length of memory to flush\r
108\r
109Returns:\r
110\r
111 Status\r
112 EFI_SUCCESS\r
113\r
114--*/\r
115{\r
116 RtPioICacheFlush ((UINT8 *) Start, (UINTN) Length);\r
117 return EFI_SUCCESS;\r
118}\r