VirtualBox

source: vbox/trunk/src/VBox/Devices/EFI/Firmware/MdePkg/Library/PeimEntryPoint/PeimEntryPoint.c

最後變更 在這個檔案是 99404,由 vboxsync 提交於 22 月 前

Devices/EFI/FirmwareNew: Update to edk2-stable202302 and make it build, bugref:4643

  • 屬性 svn:eol-style 設為 native
檔案大小: 2.0 KB
 
1/** @file
2 Entry point to a PEIM.
3
4Copyright (c) 2006 - 2018, Intel Corporation. All rights reserved.<BR>
5SPDX-License-Identifier: BSD-2-Clause-Patent
6
7**/
8
9#include <PiPei.h>
10
11#include <Library/PeimEntryPoint.h>
12#include <Library/DebugLib.h>
13
14/**
15 The entry point of PE/COFF Image for a PEIM.
16
17 This function is the entry point for a PEIM. This function must call ProcessLibraryConstructorList()
18 and ProcessModuleEntryPointList(). The return value from ProcessModuleEntryPointList() is returned.
19 If _gPeimRevision is not zero and PeiServices->Hdr.Revision is less than _gPeimRevison, then ASSERT().
20
21 @param FileHandle Handle of the file being invoked.
22 @param PeiServices Describes the list of possible PEI Services.
23
24 @retval EFI_SUCCESS The PEIM executed normally.
25 @retval !EFI_SUCCESS The PEIM failed to execute normally.
26**/
27EFI_STATUS
28EFIAPI
29_ModuleEntryPoint (
30 IN EFI_PEI_FILE_HANDLE FileHandle,
31 IN CONST EFI_PEI_SERVICES **PeiServices
32 )
33{
34 if (_gPeimRevision != 0) {
35 //
36 // Make sure that the PEI spec revision of the platform is >= PEI spec revision of the driver
37 //
38 ASSERT ((*PeiServices)->Hdr.Revision >= _gPeimRevision);
39 }
40
41 //
42 // Call constructor for all libraries
43 //
44 ProcessLibraryConstructorList (FileHandle, PeiServices);
45
46 //
47 // Call the driver entry point
48 //
49 return ProcessModuleEntryPointList (FileHandle, PeiServices);
50}
51
52/**
53 Required by the EBC compiler and identical in functionality to _ModuleEntryPoint().
54
55 This function is required to call _ModuleEntryPoint() passing in FileHandle and PeiServices.
56
57 @param FileHandle Handle of the file being invoked.
58 @param PeiServices Describes the list of possible PEI Services.
59
60 @retval EFI_SUCCESS The PEIM executed normally.
61 @retval !EFI_SUCCESS The PEIM failed to execute normally.
62
63**/
64EFI_STATUS
65EFIAPI
66EfiMain (
67 IN EFI_PEI_FILE_HANDLE FileHandle,
68 IN CONST EFI_PEI_SERVICES **PeiServices
69 )
70{
71 return _ModuleEntryPoint (FileHandle, PeiServices);
72}
注意: 瀏覽 TracBrowser 來幫助您使用儲存庫瀏覽器

© 2024 Oracle Support Privacy / Do Not Sell My Info Terms of Use Trademark Policy Automated Access Etiquette