]> git.proxmox.com Git - mirror_edk2.git/blob - IntelFrameworkModulePkg/Library/PlatformBdsLibNull/BdsPlatform.c
Reviewed the code comments in the Include/Protocol directory for typos, grammar issue...
[mirror_edk2.git] / IntelFrameworkModulePkg / Library / PlatformBdsLibNull / BdsPlatform.c
1 /** @file
2 This file include all platform action which can be customized by IBV/OEM.
3
4 Copyright (c) 2004 - 2008, Intel Corporation. <BR>
5 All rights reserved. This program and the accompanying materials
6 are licensed and made available under the terms and conditions of the BSD License
7 which accompanies this distribution. The full text of the license may be found at
8 http://opensource.org/licenses/bsd-license.php
9
10 THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
11 WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
12
13 **/
14
15 #include "BdsPlatform.h"
16
17 //
18 // BDS Platform Functions
19 //
20 /**
21 Platform Bds init. Include the platform firmware vendor, revision
22 and so crc check.
23
24 @param PrivateData The EFI_BDS_ARCH_PROTOCOL_INSTANCE instance
25
26 **/
27 VOID
28 EFIAPI
29 PlatformBdsInit (
30 IN EFI_BDS_ARCH_PROTOCOL_INSTANCE *PrivateData
31 )
32 {
33 return;
34 }
35
36 /**
37 Connect the predefined platform default console device. Always try to find
38 and enable the vga device if have.
39
40 @param PlatformConsole Predefined platform default console device array.
41
42 @retval EFI_SUCCESS Success connect at least one ConIn and ConOut
43 device, there must have one ConOut device is
44 active vga device.
45 @return Return the status of BdsLibConnectAllDefaultConsoles ()
46
47 **/
48 EFI_STATUS
49 PlatformBdsConnectConsole (
50 IN BDS_CONSOLE_CONNECT_ENTRY *PlatformConsole
51 )
52 {
53 return EFI_SUCCESS;
54 }
55
56 /**
57 Connect with predefined platform connect sequence,
58 the OEM/IBV can customize with their own connect sequence.
59 **/
60 VOID
61 PlatformBdsConnectSequence (
62 VOID
63 )
64 {
65 return;
66 }
67
68 /**
69 Load the predefined driver option, OEM/IBV can customize this
70 to load their own drivers
71
72 @param BdsDriverLists - The header of the driver option link list.
73
74 **/
75 VOID
76 PlatformBdsGetDriverOption (
77 IN OUT LIST_ENTRY *BdsDriverLists
78 )
79 {
80 return;
81 }
82
83 /**
84 Perform the platform diagnostic, such like test memory. OEM/IBV also
85 can customize this function to support specific platform diagnostic.
86
87 @param MemoryTestLevel The memory test intensive level
88 @param QuietBoot Indicate if need to enable the quiet boot
89
90 **/
91 VOID
92 PlatformBdsDiagnostics (
93 IN EXTENDMEM_COVERAGE_LEVEL MemoryTestLevel,
94 IN BOOLEAN QuietBoot
95 )
96 {
97 return;
98 }
99
100 /**
101 The function will execute with as the platform policy, current policy
102 is driven by boot mode. IBV/OEM can customize this code for their specific
103 policy action.
104
105 @param PrivateData The EFI_BDS_ARCH_PROTOCOL_INSTANCE instance
106 @param DriverOptionList The header of the driver option link list
107 @param BootOptionList The header of the boot option link list
108
109 **/
110 VOID
111 EFIAPI
112 PlatformBdsPolicyBehavior (
113 IN EFI_BDS_ARCH_PROTOCOL_INSTANCE *PrivateData,
114 IN LIST_ENTRY *DriverOptionList,
115 IN LIST_ENTRY *BootOptionList
116 )
117 {
118 return ;
119 }
120
121 /**
122 Hook point after a boot attempt succeeds. We don't expect a boot option to
123 return, so the UEFI 2.0 specification defines that you will default to an
124 interactive mode and stop processing the BootOrder list in this case. This
125 is also a platform implementation and can be customized by IBV/OEM.
126
127 @param Option Pointer to Boot Option that succeeded to boot.
128
129 **/
130 VOID
131 EFIAPI
132 PlatformBdsBootSuccess (
133 IN BDS_COMMON_OPTION *Option
134 )
135 {
136 return;
137 }
138
139 /**
140 Hook point after a boot attempt fails.
141
142 @param Option Pointer to Boot Option that failed to boot.
143 @param Status Status returned from failed boot.
144 @param ExitData Exit data returned from failed boot.
145 @param ExitDataSize Exit data size returned from failed boot.
146
147 **/
148 VOID
149 EFIAPI
150 PlatformBdsBootFail (
151 IN BDS_COMMON_OPTION *Option,
152 IN EFI_STATUS Status,
153 IN CHAR16 *ExitData,
154 IN UINTN ExitDataSize
155 )
156 {
157 return;
158 }
159
160 /**
161 This function is remained for IBV/OEM to do some platform action,
162 if there no console device can be connected.
163
164 @return EFI_SUCCESS Direct return success now.
165
166 **/
167 EFI_STATUS
168 PlatformBdsNoConsoleAction (
169 VOID
170 )
171 {
172 return EFI_SUCCESS;
173 }
174
175 /**
176 This function locks platform flash that is not allowed to be updated during normal boot path.
177 The flash layout is platform specific.
178
179 @retval EFI_SUCCESS The non-updatable flash areas.
180 **/
181 EFI_STATUS
182 EFIAPI
183 PlatformBdsLockNonUpdatableFlash (
184 VOID
185 )
186 {
187 return EFI_SUCCESS;
188 }