]> git.proxmox.com Git - mirror_edk2.git/blob - MdeModulePkg/Application/UiApp/Ui.h
UiApp code split from IntelFrameworkModulePkg/Universal/BdsDxe driver.
[mirror_edk2.git] / MdeModulePkg / Application / UiApp / Ui.h
1 /** @file
2 FrontPage routines to handle the callbacks and browser calls
3
4 Copyright (c) 2015, 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
16 #ifndef _BDS_MODULE_H_
17 #define _BDS_MODULE_H_
18
19 #include <PiDxe.h>
20 #include <IndustryStandard/PeImage.h>
21 #include <IndustryStandard/SmBios.h>
22
23 #include <Guid/MdeModuleHii.h>
24 #include <Guid/FileSystemVolumeLabelInfo.h>
25 #include <Guid/HiiPlatformSetupFormset.h>
26 #include <Guid/GlobalVariable.h>
27 #include <Guid/CapsuleVendor.h>
28 #include <Guid/StatusCodeDataTypeId.h>
29 #include <Guid/FileInfo.h>
30 //#include <Guid/HiiSetupEnter.h>
31 #include <Guid/HiiBootMaintenanceFormset.h>
32
33 #include <Protocol/LoadFile.h>
34 #include <Protocol/DevicePath.h>
35 #include <Protocol/HiiConfigRouting.h>
36 #include <Protocol/Smbios.h>
37 #include <Protocol/UgaDraw.h>
38 #include <Protocol/BlockIo.h>
39 #include <Protocol/GenericMemoryTest.h>
40 #include <Protocol/FormBrowser2.h>
41 #include <Protocol/HiiConfigAccess.h>
42 #include <Protocol/GraphicsOutput.h>
43 #include <Protocol/SimpleFileSystem.h>
44 #include <Protocol/HiiDatabase.h>
45 #include <Protocol/HiiString.h>
46 #include <Protocol/SerialIo.h>
47 #include <Protocol/LegacyBios.h>
48 #include <Protocol/SimpleTextInEx.h>
49 #include <Protocol/DriverHealth.h>
50 #include <Protocol/DevicePathToText.h>
51
52 #include <Library/UefiDriverEntryPoint.h>
53 #include <Library/PrintLib.h>
54 #include <Library/DebugLib.h>
55 #include <Library/BaseMemoryLib.h>
56 #include <Library/UefiBootServicesTableLib.h>
57 #include <Library/UefiLib.h>
58 #include <Library/MemoryAllocationLib.h>
59 #include <Library/PerformanceLib.h>
60 #include <Library/ReportStatusCodeLib.h>
61 #include <Library/UefiRuntimeServicesTableLib.h>
62 #include <Library/HobLib.h>
63 #include <Library/BaseLib.h>
64 #include <Library/DevicePathLib.h>
65 #include <Library/PcdLib.h>
66 #include <Library/CapsuleLib.h>
67 #include <Library/HiiLib.h>
68 #include <Library/DevicePathLib.h>
69 #include <Library/PcdLib.h>
70 #include <Library/UefiHiiServicesLib.h>
71
72 #include <Library/UefiBootManagerLib.h>
73
74 #pragma pack(1)
75
76 ///
77 /// HII specific Vendor Device Path definition.
78 ///
79 typedef struct {
80 VENDOR_DEVICE_PATH VendorDevicePath;
81 EFI_DEVICE_PATH_PROTOCOL End;
82 } HII_VENDOR_DEVICE_PATH;
83
84 #pragma pack()
85
86
87 //
88 //The interface functions related to the Setup Browser Reset Reminder feature
89 //
90 /**
91 Enable the setup browser reset reminder feature.
92 This routine is used in a platform tip. If the platform policy needs the feature, use the routine to enable it.
93
94 **/
95 VOID
96 EFIAPI
97 EnableResetReminderFeature (
98 VOID
99 );
100
101 /**
102 Disable the setup browser reset reminder feature.
103 This routine is used in a platform tip. If the platform policy does not want the feature, use the routine to disable it.
104
105 **/
106 VOID
107 EFIAPI
108 DisableResetReminderFeature (
109 VOID
110 );
111
112 /**
113 Record the info that a reset is required.
114 A module boolean variable is used to record whether a reset is required.
115
116 **/
117 VOID
118 EFIAPI
119 EnableResetRequired (
120 VOID
121 );
122
123
124 /**
125 Record the info that no reset is required.
126 A module boolean variable is used to record whether a reset is required.
127
128 **/
129 VOID
130 EFIAPI
131 DisableResetRequired (
132 VOID
133 );
134
135 /**
136 Check whether platform policy enables the reset reminder feature. The default is enabled.
137
138 **/
139 BOOLEAN
140 EFIAPI
141 IsResetReminderFeatureEnable (
142 VOID
143 );
144
145 /**
146 Check if the user changed any option setting that needs a system reset to be effective.
147
148 **/
149 BOOLEAN
150 EFIAPI
151 IsResetRequired (
152 VOID
153 );
154
155 /**
156 Check whether a reset is needed, and finish the reset reminder feature.
157 If a reset is needed, pop up a menu to notice user, and finish the feature
158 according to the user selection.
159
160 **/
161 VOID
162 EFIAPI
163 SetupResetReminder (
164 VOID
165 );
166
167 /**
168 This function converts an input device structure to a Unicode string.
169
170 @param DevPath A pointer to the device path structure.
171
172 @return A new allocated Unicode string that represents the device path.
173
174 **/
175 CHAR16 *
176 UiDevicePathToStr (
177 IN EFI_DEVICE_PATH_PROTOCOL *DevPath
178 );
179 #endif