]> git.proxmox.com Git - mirror_edk2.git/blob - IntelFrameworkModulePkg/Universal/BdsDxe/BootMngr/BootManager.h
Clean up the private GUID definition in module Level.
[mirror_edk2.git] / IntelFrameworkModulePkg / Universal / BdsDxe / BootMngr / BootManager.h
1 /** @file
2 The platform boot manager reference implement
3
4 Copyright (c) 2004 - 2011, Intel Corporation. All rights reserved.<BR>
5 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 #ifndef _EFI_BOOT_MANAGER_H_
16 #define _EFI_BOOT_MANAGER_H_
17
18 #include "Bds.h"
19 #include "FrontPage.h"
20
21 #define BOOT_MANAGER_FORM_ID 0x1000
22
23 #define LABEL_BOOT_OPTION 0x00
24 #define LABEL_BOOT_OPTION_END 0x01
25
26 //
27 // These are the VFR compiler generated data representing our VFR data.
28 //
29 extern UINT8 BootManagerVfrBin[];
30
31 #define BOOT_MANAGER_CALLBACK_DATA_SIGNATURE SIGNATURE_32 ('B', 'M', 'C', 'B')
32
33 typedef struct {
34 UINTN Signature;
35
36 //
37 // HII relative handles
38 //
39 EFI_HII_HANDLE HiiHandle;
40 EFI_HANDLE DriverHandle;
41
42 //
43 // Produced protocols
44 //
45 EFI_HII_CONFIG_ACCESS_PROTOCOL ConfigAccess;
46 } BOOT_MANAGER_CALLBACK_DATA;
47
48 /**
49 This call back function is registered with Boot Manager formset.
50 When user selects a boot option, this call back function will
51 be triggered. The boot option is saved for later processing.
52
53
54 @param This Points to the EFI_HII_CONFIG_ACCESS_PROTOCOL.
55 @param Action Specifies the type of action taken by the browser.
56 @param QuestionId A unique value which is sent to the original exporting driver
57 so that it can identify the type of data to expect.
58 @param Type The type of value for the question.
59 @param Value A pointer to the data being sent to the original exporting driver.
60 @param ActionRequest On return, points to the action requested by the callback function.
61
62 @retval EFI_SUCCESS The callback successfully handled the action.
63 @retval EFI_INVALID_PARAMETER The setup browser call this function with invalid parameters.
64
65 **/
66 EFI_STATUS
67 EFIAPI
68 BootManagerCallback (
69 IN CONST EFI_HII_CONFIG_ACCESS_PROTOCOL *This,
70 IN EFI_BROWSER_ACTION Action,
71 IN EFI_QUESTION_ID QuestionId,
72 IN UINT8 Type,
73 IN EFI_IFR_TYPE_VALUE *Value,
74 OUT EFI_BROWSER_ACTION_REQUEST *ActionRequest
75 );
76
77 /**
78
79 Registers HII packages for the Boot Manger to HII Database.
80 It also registers the browser call back function.
81
82 @retval EFI_SUCCESS HII packages for the Boot Manager were registered successfully.
83 @retval EFI_OUT_OF_RESOURCES HII packages for the Boot Manager failed to be registered.
84
85 **/
86 EFI_STATUS
87 InitializeBootManager (
88 VOID
89 );
90
91 /**
92 This function invokes Boot Manager. If all devices have not a chance to be connected,
93 the connect all will be triggered. It then enumerate all boot options. If
94 a boot option from the Boot Manager page is selected, Boot Manager will boot
95 from this boot option.
96
97 **/
98 VOID
99 CallBootManager (
100 VOID
101 );
102
103 #endif