]> git.proxmox.com Git - mirror_edk2.git/blame - MdeModulePkg/Universal/SetupBrowserDxe/Setup.h
Export one interface to support 3rd party to change question attribute, such as hide...
[mirror_edk2.git] / MdeModulePkg / Universal / SetupBrowserDxe / Setup.h
CommitLineData
7936fb6a 1/** @file\r
d66e6c16 2Private MACRO, structure and function definitions for Setup Browser module.\r
7936fb6a 3\r
80a047f0 4Copyright (c) 2007 - 2013, Intel Corporation. All rights reserved.<BR>\r
e5eed7d3 5This program and the accompanying materials\r
7936fb6a 6are licensed and made available under the terms and conditions of the BSD License\r
7which accompanies this distribution. The full text of the license may be found at\r
8http://opensource.org/licenses/bsd-license.php\r
9\r
10THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,\r
11WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.\r
12\r
13\r
14**/\r
15\r
16#ifndef _SETUP_H_\r
17#define _SETUP_H_\r
18\r
19\r
39099938 20#include <PiDxe.h>\r
7936fb6a 21\r
7936fb6a 22#include <Protocol/SimpleTextOut.h>\r
23#include <Protocol/SimpleTextIn.h>\r
24#include <Protocol/FormBrowser2.h>\r
7c6c064c
ED
25#include <Protocol/FormBrowserEx2.h>\r
26#include <Protocol/DisplayProtocol.h>\r
7936fb6a 27#include <Protocol/DevicePath.h>\r
28#include <Protocol/UnicodeCollation.h>\r
29#include <Protocol/HiiConfigAccess.h>\r
30#include <Protocol/HiiConfigRouting.h>\r
31#include <Protocol/HiiDatabase.h>\r
32#include <Protocol/HiiString.h>\r
cbf73e50 33#include <Protocol/UserManager.h>\r
80a047f0 34#include <Protocol/DevicePathFromText.h>\r
7936fb6a 35\r
5c526736 36#include <Guid/MdeModuleHii.h>\r
0a1147ed 37#include <Guid/HiiPlatformSetupFormset.h>\r
2573712e 38#include <Guid/HiiFormMapMethodGuid.h>\r
7936fb6a 39\r
7936fb6a 40#include <Library/PrintLib.h>\r
41#include <Library/DebugLib.h>\r
42#include <Library/BaseMemoryLib.h>\r
43#include <Library/UefiRuntimeServicesTableLib.h>\r
44#include <Library/UefiDriverEntryPoint.h>\r
45#include <Library/UefiBootServicesTableLib.h>\r
46#include <Library/BaseLib.h>\r
47#include <Library/MemoryAllocationLib.h>\r
7936fb6a 48#include <Library/HiiLib.h>\r
f511d656 49#include <Library/PcdLib.h>\r
cb7d01c0 50#include <Library/DevicePathLib.h>\r
7c6c064c 51#include <Library/UefiLib.h>\r
7936fb6a 52\r
7936fb6a 53\r
54//\r
55// This is the generated header file which includes whatever needs to be exported (strings + IFR)\r
56//\r
57\r
7c6c064c
ED
58#define UI_ACTION_NONE 0\r
59#define UI_ACTION_REFRESH_FORM 1\r
60#define UI_ACTION_REFRESH_FORMSET 2\r
61#define UI_ACTION_EXIT 3\r
7936fb6a 62\r
63//\r
7936fb6a 64//\r
65// Time definitions\r
66//\r
67#define ONE_SECOND 10000000\r
68\r
7936fb6a 69// Incremental string lenght of ConfigRequest\r
70//\r
71#define CONFIG_REQUEST_STRING_INCREMENTAL 1024\r
72\r
7936fb6a 73//\r
74// Incremental size of stack for expression\r
75//\r
76#define EXPRESSION_STACK_SIZE_INCREMENT 0x100\r
77\r
0269d14b 78#define EFI_IFR_SPECIFICATION_VERSION (UINT16) (((EFI_SYSTEM_TABLE_REVISION >> 16) << 8) | (((EFI_SYSTEM_TABLE_REVISION & 0xFFFF) / 10) << 4) | ((EFI_SYSTEM_TABLE_REVISION & 0xFFFF) % 10))\r
7936fb6a 79\r
7936fb6a 80\r
f3f2e05d 81#define SETUP_DRIVER_SIGNATURE SIGNATURE_32 ('F', 'B', 'D', 'V')\r
7936fb6a 82typedef struct {\r
83 UINT32 Signature;\r
84\r
85 EFI_HANDLE Handle;\r
86\r
87 //\r
88 // Produced protocol\r
89 //\r
7c6c064c
ED
90 EFI_FORM_BROWSER2_PROTOCOL FormBrowser2;\r
91 EFI_FORM_BROWSER_EXTENSION_PROTOCOL FormBrowserEx;\r
7936fb6a 92\r
7c6c064c 93 EDKII_FORM_BROWSER_EXTENSION2_PROTOCOL FormBrowserEx2;\r
7936fb6a 94\r
7c6c064c 95} SETUP_DRIVER_PRIVATE_DATA;\r
25361615 96\r
7936fb6a 97//\r
98// IFR relative definition\r
99//\r
100#define EFI_HII_EXPRESSION_INCONSISTENT_IF 0\r
101#define EFI_HII_EXPRESSION_NO_SUBMIT_IF 1\r
102#define EFI_HII_EXPRESSION_GRAY_OUT_IF 2\r
103#define EFI_HII_EXPRESSION_SUPPRESS_IF 3\r
104#define EFI_HII_EXPRESSION_DISABLE_IF 4\r
105#define EFI_HII_EXPRESSION_VALUE 5\r
106#define EFI_HII_EXPRESSION_RULE 6\r
2573712e
LG
107#define EFI_HII_EXPRESSION_READ 7\r
108#define EFI_HII_EXPRESSION_WRITE 8\r
1c0d306f 109#define EFI_HII_EXPRESSION_WARNING_IF 9\r
7936fb6a 110\r
111#define EFI_HII_VARSTORE_BUFFER 0\r
112#define EFI_HII_VARSTORE_NAME_VALUE 1\r
c0462ea7
ED
113#define EFI_HII_VARSTORE_EFI_VARIABLE 2 // EFI Varstore type follow UEFI spec before 2.3.1.\r
114#define EFI_HII_VARSTORE_EFI_VARIABLE_BUFFER 3 // EFI varstore type follow UEFI spec 2.3.1 and later.\r
7936fb6a 115\r
116#define FORM_INCONSISTENT_VALIDATION 0\r
117#define FORM_NO_SUBMIT_VALIDATION 1\r
118\r
f3f2e05d 119#define NAME_VALUE_NODE_SIGNATURE SIGNATURE_32 ('N', 'V', 'S', 'T')\r
7936fb6a 120\r
121typedef struct {\r
122 UINTN Signature;\r
123 LIST_ENTRY Link;\r
124 CHAR16 *Name;\r
125 CHAR16 *Value;\r
126 CHAR16 *EditValue;\r
127} NAME_VALUE_NODE;\r
128\r
129#define NAME_VALUE_NODE_FROM_LINK(a) CR (a, NAME_VALUE_NODE, Link, NAME_VALUE_NODE_SIGNATURE)\r
130\r
94f3aae7 131#define BROWSER_STORAGE_SIGNATURE SIGNATURE_32 ('B', 'S', 'T', 'G')\r
7936fb6a 132\r
133typedef struct {\r
134 UINTN Signature;\r
135 LIST_ENTRY Link;\r
136\r
137 UINT8 Type; // Storage type\r
138\r
7936fb6a 139 EFI_GUID Guid;\r
140\r
141 CHAR16 *Name; // For EFI_IFR_VARSTORE\r
142 UINT16 Size;\r
143 UINT8 *Buffer;\r
144 UINT8 *EditBuffer; // Edit copy for Buffer Storage\r
145\r
146 LIST_ENTRY NameValueListHead; // List of NAME_VALUE_NODE\r
147\r
148 UINT32 Attributes; // For EFI_IFR_VARSTORE_EFI: EFI Variable attribute\r
149\r
150 CHAR16 *ConfigHdr; // <ConfigHdr>\r
efffd9c1
ED
151 CHAR16 *ConfigRequest; // <ConfigRequest> = <ConfigHdr> + <RequestElement>\r
152 // <RequestElement> includes all fields which is used by current form sets.\r
153 UINTN SpareStrLen; // Spare length of ConfigRequest string buffer\r
94f3aae7
ED
154 UINT8 ReferenceCount; // How many form set storage refrence this storage.\r
155} BROWSER_STORAGE;\r
156\r
157#define BROWSER_STORAGE_FROM_LINK(a) CR (a, BROWSER_STORAGE, Link, BROWSER_STORAGE_SIGNATURE)\r
158\r
159#define FORMSET_STORAGE_SIGNATURE SIGNATURE_32 ('F', 'S', 'T', 'G')\r
160\r
161typedef struct {\r
162 UINTN Signature;\r
163 LIST_ENTRY Link;\r
164\r
165 UINT16 VarStoreId;\r
166\r
167 BROWSER_STORAGE *BrowserStorage;\r
168\r
7936fb6a 169 CHAR16 *ConfigRequest; // <ConfigRequest> = <ConfigHdr> + <RequestElement>\r
7c6c064c 170 CHAR16 *ConfigElements;// Elements need to load initial data.\r
7936fb6a 171 UINTN ElementCount; // Number of <RequestElement> in the <ConfigRequest>\r
172 UINTN SpareStrLen; // Spare length of ConfigRequest string buffer\r
173} FORMSET_STORAGE;\r
174\r
175#define FORMSET_STORAGE_FROM_LINK(a) CR (a, FORMSET_STORAGE, Link, FORMSET_STORAGE_SIGNATURE)\r
176\r
2573712e
LG
177typedef union {\r
178 EFI_STRING_ID VarName;\r
179 UINT16 VarOffset;\r
180} VAR_STORE_INFO;\r
181\r
f3f2e05d 182#define EXPRESSION_OPCODE_SIGNATURE SIGNATURE_32 ('E', 'X', 'O', 'P')\r
7936fb6a 183\r
184typedef struct {\r
185 UINTN Signature;\r
186 LIST_ENTRY Link;\r
187\r
188 UINT8 Operand;\r
189\r
190 UINT8 Format; // For EFI_IFR_TO_STRING, EFI_IFR_FIND\r
191 UINT8 Flags; // For EFI_IFR_SPAN\r
192 UINT8 RuleId; // For EFI_IFR_RULE_REF\r
193\r
194 EFI_HII_VALUE Value; // For EFI_IFR_EQ_ID_VAL, EFI_IFR_UINT64, EFI_IFR_UINT32, EFI_IFR_UINT16, EFI_IFR_UINT8, EFI_IFR_STRING_REF1\r
195\r
2654f642 196 EFI_QUESTION_ID QuestionId; // For EFI_IFR_EQ_ID_ID, EFI_IFR_EQ_ID_VAL_LIST, EFI_IFR_QUESTION_REF1\r
7936fb6a 197 EFI_QUESTION_ID QuestionId2;\r
198\r
2654f642 199 UINT16 ListLength; // For EFI_IFR_EQ_ID_VAL_LIST\r
7936fb6a 200 UINT16 *ValueList;\r
201\r
202 EFI_STRING_ID DevicePath; // For EFI_IFR_QUESTION_REF3_2, EFI_IFR_QUESTION_REF3_3\r
203 EFI_GUID Guid;\r
2573712e 204\r
94f3aae7 205 BROWSER_STORAGE *VarStorage; // For EFI_IFR_SET, EFI_IFR_GET\r
2573712e
LG
206 VAR_STORE_INFO VarStoreInfo;// For EFI_IFR_SET, EFI_IFR_GET\r
207 UINT8 ValueType; // For EFI_IFR_SET, EFI_IFR_GET\r
208 UINT8 ValueWidth; // For EFI_IFR_SET, EFI_IFR_GET\r
209 CHAR16 *ValueName; // For EFI_IFR_SET, EFI_IFR_GET\r
210 LIST_ENTRY MapExpressionList; // nested expressions inside of Map opcode.\r
7936fb6a 211} EXPRESSION_OPCODE;\r
212\r
213#define EXPRESSION_OPCODE_FROM_LINK(a) CR (a, EXPRESSION_OPCODE, Link, EXPRESSION_OPCODE_SIGNATURE)\r
214\r
f3f2e05d 215#define FORM_EXPRESSION_SIGNATURE SIGNATURE_32 ('F', 'E', 'X', 'P')\r
7936fb6a 216\r
217typedef struct {\r
218 UINTN Signature;\r
219 LIST_ENTRY Link;\r
220\r
221 UINT8 Type; // Type for this expression\r
222\r
223 UINT8 RuleId; // For EFI_IFR_RULE only\r
224 EFI_STRING_ID Error; // For EFI_IFR_NO_SUBMIT_IF, EFI_IFR_INCONSISTENT_IF only\r
225\r
226 EFI_HII_VALUE Result; // Expression evaluation result\r
227\r
1c0d306f
ED
228 UINT8 TimeOut; // For EFI_IFR_WARNING_IF\r
229\r
7936fb6a 230 LIST_ENTRY OpCodeListHead; // OpCodes consist of this expression (EXPRESSION_OPCODE)\r
231} FORM_EXPRESSION;\r
232\r
233#define FORM_EXPRESSION_FROM_LINK(a) CR (a, FORM_EXPRESSION, Link, FORM_EXPRESSION_SIGNATURE)\r
234\r
31585af4
ED
235#define FORM_EXPRESSION_LIST_SIGNATURE SIGNATURE_32 ('F', 'E', 'X', 'R')\r
236\r
237typedef struct {\r
238 UINTN Signature;\r
239 UINTN Count;\r
240 FORM_EXPRESSION *Expression[1]; // Array[Count] of expressions\r
241} FORM_EXPRESSION_LIST;\r
242\r
f3f2e05d 243#define QUESTION_DEFAULT_SIGNATURE SIGNATURE_32 ('Q', 'D', 'F', 'T')\r
7936fb6a 244\r
245typedef struct {\r
246 UINTN Signature;\r
247 LIST_ENTRY Link;\r
248\r
249 UINT16 DefaultId;\r
250 EFI_HII_VALUE Value; // Default value\r
251\r
252 FORM_EXPRESSION *ValueExpression; // Not-NULL indicates default value is provided by EFI_IFR_VALUE\r
253} QUESTION_DEFAULT;\r
254\r
255#define QUESTION_DEFAULT_FROM_LINK(a) CR (a, QUESTION_DEFAULT, Link, QUESTION_DEFAULT_SIGNATURE)\r
256\r
f3f2e05d 257#define QUESTION_OPTION_SIGNATURE SIGNATURE_32 ('Q', 'O', 'P', 'T')\r
7936fb6a 258\r
259typedef struct {\r
31585af4
ED
260 UINTN Signature;\r
261 LIST_ENTRY Link;\r
7c6c064c
ED
262 \r
263 EFI_IFR_ONE_OF_OPTION *OpCode; // OneOfOption Data\r
7936fb6a 264\r
31585af4
ED
265 EFI_STRING_ID Text;\r
266 UINT8 Flags;\r
267 EFI_HII_VALUE Value;\r
268 EFI_IMAGE_ID ImageId;\r
7936fb6a 269\r
31585af4 270 FORM_EXPRESSION_LIST *SuppressExpression; // Non-NULL indicates nested inside of SuppressIf\r
7936fb6a 271} QUESTION_OPTION;\r
272\r
273#define QUESTION_OPTION_FROM_LINK(a) CR (a, QUESTION_OPTION, Link, QUESTION_OPTION_SIGNATURE)\r
274\r
31585af4
ED
275typedef enum {\r
276 ExpressFalse = 0,\r
277 ExpressGrayOut, \r
278 ExpressSuppress,\r
279 ExpressDisable\r
280} EXPRESS_RESULT;\r
281\r
282typedef enum {\r
283 ExpressNone = 0,\r
284 ExpressForm, \r
285 ExpressStatement,\r
286 ExpressOption\r
287} EXPRESS_LEVEL;\r
288\r
f3f2e05d 289#define FORM_BROWSER_STATEMENT_SIGNATURE SIGNATURE_32 ('F', 'S', 'T', 'A')\r
1ccdbf2a 290\r
7936fb6a 291typedef struct {\r
292 UINTN Signature;\r
293 LIST_ENTRY Link;\r
294\r
295 UINT8 Operand; // The operand (first byte) of this Statement or Question\r
7c6c064c 296 EFI_IFR_OP_HEADER *OpCode;\r
7936fb6a 297\r
298 //\r
299 // Statement Header\r
300 //\r
301 EFI_STRING_ID Prompt;\r
302 EFI_STRING_ID Help;\r
303 EFI_STRING_ID TextTwo; // For EFI_IFR_TEXT\r
304\r
7c6c064c
ED
305 //\r
306 // Fake Question Id, used for statement not has true QuestionId.\r
307 //\r
308 EFI_QUESTION_ID FakeQuestionId;\r
309\r
7936fb6a 310 //\r
311 // Question Header\r
312 //\r
313 EFI_QUESTION_ID QuestionId; // The value of zero is reserved\r
314 EFI_VARSTORE_ID VarStoreId; // A value of zero indicates no variable storage\r
94f3aae7 315 BROWSER_STORAGE *Storage;\r
1ccdbf2a 316 VAR_STORE_INFO VarStoreInfo;\r
7936fb6a 317 UINT16 StorageWidth;\r
318 UINT8 QuestionFlags;\r
319 CHAR16 *VariableName; // Name/Value or EFI Variable name\r
320 CHAR16 *BlockName; // Buffer storage block name: "OFFSET=...WIDTH=..."\r
321\r
322 EFI_HII_VALUE HiiValue; // Edit copy for checkbox, numberic, oneof\r
323 UINT8 *BufferValue; // Edit copy for string, password, orderedlist\r
d02847d3 324 UINT8 ValueType; // Data type for orderedlist value array\r
7936fb6a 325\r
326 //\r
327 // OpCode specific members\r
328 //\r
329 UINT8 Flags; // for EFI_IFR_CHECKBOX, EFI_IFR_DATE, EFI_IFR_NUMERIC, EFI_IFR_ONE_OF,\r
330 // EFI_IFR_ORDERED_LIST, EFI_IFR_STRING,EFI_IFR_SUBTITLE,EFI_IFR_TIME, EFI_IFR_BANNER\r
331 UINT8 MaxContainers; // for EFI_IFR_ORDERED_LIST\r
332\r
333 UINT16 BannerLineNumber; // for EFI_IFR_BANNER, 1-based line number\r
334 EFI_STRING_ID QuestionConfig; // for EFI_IFR_ACTION, if 0 then no configuration string will be processed\r
335\r
336 UINT64 Minimum; // for EFI_IFR_ONE_OF/EFI_IFR_NUMERIC, it's Min/Max value\r
337 UINT64 Maximum; // for EFI_IFR_STRING/EFI_IFR_PASSWORD, it's Min/Max length\r
338 UINT64 Step;\r
339\r
340 EFI_DEFAULT_ID DefaultId; // for EFI_IFR_RESET_BUTTON\r
211cc6e5 341 EFI_GUID RefreshGuid; // for EFI_IFR_REFRESH_ID\r
f67c4382 342 BOOLEAN Locked; // Whether this statement is locked.\r
7c6c064c 343 BOOLEAN ValueChanged; // Whether this statement's value is changed.\r
7936fb6a 344 //\r
345 // Get from IFR parsing\r
346 //\r
347 FORM_EXPRESSION *ValueExpression; // nested EFI_IFR_VALUE, provide Question value and indicate Question is ReadOnly\r
348 LIST_ENTRY DefaultListHead; // nested EFI_IFR_DEFAULT list (QUESTION_DEFAULT), provide default values\r
349 LIST_ENTRY OptionListHead; // nested EFI_IFR_ONE_OF_OPTION list (QUESTION_OPTION)\r
350\r
351 EFI_IMAGE_ID ImageId; // nested EFI_IFR_IMAGE\r
352 UINT8 RefreshInterval; // nested EFI_IFR_REFRESH, refresh interval(in seconds) for Question value, 0 means no refresh\r
353 BOOLEAN InSubtitle; // nesting inside of EFI_IFR_SUBTITLE\r
354\r
355 LIST_ENTRY InconsistentListHead;// nested inconsistent expression list (FORM_EXPRESSION)\r
356 LIST_ENTRY NoSubmitListHead; // nested nosubmit expression list (FORM_EXPRESSION)\r
1c0d306f 357 LIST_ENTRY WarningListHead; // nested warning expression list (FORM_EXPRESSION)\r
31585af4 358 FORM_EXPRESSION_LIST *Expression; // nesting inside of GrayOutIf/DisableIf/SuppressIf\r
7936fb6a 359\r
2573712e
LG
360 FORM_EXPRESSION *ReadExpression; // nested EFI_IFR_READ, provide this question value by read expression.\r
361 FORM_EXPRESSION *WriteExpression; // nested EFI_IFR_WRITE, evaluate write expression after this question value is set.\r
7936fb6a 362} FORM_BROWSER_STATEMENT;\r
363\r
364#define FORM_BROWSER_STATEMENT_FROM_LINK(a) CR (a, FORM_BROWSER_STATEMENT, Link, FORM_BROWSER_STATEMENT_SIGNATURE)\r
365\r
b18e7050
ED
366#define FORM_BROWSER_CONFIG_REQUEST_SIGNATURE SIGNATURE_32 ('F', 'C', 'R', 'S')\r
367typedef struct {\r
368 UINTN Signature;\r
369 LIST_ENTRY Link;\r
370\r
371 CHAR16 *ConfigRequest; // <ConfigRequest> = <ConfigHdr> + <RequestElement>\r
372 UINTN ElementCount; // Number of <RequestElement> in the <ConfigRequest> \r
373 UINTN SpareStrLen;\r
374\r
94f3aae7 375 BROWSER_STORAGE *Storage;\r
b18e7050
ED
376} FORM_BROWSER_CONFIG_REQUEST;\r
377#define FORM_BROWSER_CONFIG_REQUEST_FROM_LINK(a) CR (a, FORM_BROWSER_CONFIG_REQUEST, Link, FORM_BROWSER_CONFIG_REQUEST_SIGNATURE)\r
378\r
f3f2e05d 379#define FORM_BROWSER_FORM_SIGNATURE SIGNATURE_32 ('F', 'F', 'R', 'M')\r
2573712e 380#define STANDARD_MAP_FORM_TYPE 0x01\r
7936fb6a 381\r
382typedef struct {\r
31585af4
ED
383 UINTN Signature;\r
384 LIST_ENTRY Link;\r
7936fb6a 385\r
31585af4
ED
386 UINT16 FormId; // FormId of normal form or formmap form.\r
387 EFI_STRING_ID FormTitle; // FormTile of normal form, or FormMapMethod title of formmap form.\r
388 UINT16 FormType; // Specific form type for the different form.\r
7936fb6a 389\r
31585af4 390 EFI_IMAGE_ID ImageId;\r
7936fb6a 391\r
31585af4
ED
392 BOOLEAN ModalForm; // Whether this is a modal form.\r
393 BOOLEAN Locked; // Whether this form is locked.\r
b00964a9 394\r
31585af4
ED
395 LIST_ENTRY ExpressionListHead; // List of Expressions (FORM_EXPRESSION)\r
396 LIST_ENTRY StatementListHead; // List of Statements and Questions (FORM_BROWSER_STATEMENT)\r
397 LIST_ENTRY ConfigRequestHead; // List of configreques for all storage.\r
398 FORM_EXPRESSION_LIST *SuppressExpression; // nesting inside of SuppressIf\r
7936fb6a 399} FORM_BROWSER_FORM;\r
400\r
401#define FORM_BROWSER_FORM_FROM_LINK(a) CR (a, FORM_BROWSER_FORM, Link, FORM_BROWSER_FORM_SIGNATURE)\r
402\r
f3f2e05d 403#define FORMSET_DEFAULTSTORE_SIGNATURE SIGNATURE_32 ('F', 'D', 'F', 'S')\r
7936fb6a 404\r
405typedef struct {\r
406 UINTN Signature;\r
407 LIST_ENTRY Link;\r
408\r
409 UINT16 DefaultId;\r
410 EFI_STRING_ID DefaultName;\r
411} FORMSET_DEFAULTSTORE;\r
412\r
413#define FORMSET_DEFAULTSTORE_FROM_LINK(a) CR (a, FORMSET_DEFAULTSTORE, Link, FORMSET_DEFAULTSTORE_SIGNATURE)\r
414\r
48a9d5f7
LG
415#define FORM_BROWSER_FORMSET_SIGNATURE SIGNATURE_32 ('F', 'B', 'F', 'S')\r
416\r
7936fb6a 417typedef struct {\r
48a9d5f7
LG
418 UINTN Signature;\r
419 LIST_ENTRY Link;\r
420 EFI_HII_HANDLE HiiHandle; // unique id for formset.\r
7936fb6a 421 EFI_HANDLE DriverHandle;\r
422 EFI_HII_CONFIG_ACCESS_PROTOCOL *ConfigAccess;\r
423 EFI_DEVICE_PATH_PROTOCOL *DevicePath;\r
424\r
425 UINTN IfrBinaryLength;\r
426 UINT8 *IfrBinaryData;\r
427\r
7c6c064c 428 BOOLEAN QuestionInited; // Have finished question initilization?\r
7936fb6a 429 EFI_GUID Guid;\r
430 EFI_STRING_ID FormSetTitle;\r
431 EFI_STRING_ID Help;\r
0a1147ed
LG
432 UINT8 NumberOfClassGuid;\r
433 EFI_GUID ClassGuid[3]; // Up to three ClassGuid\r
434 UINT16 Class; // Tiano extended Class code\r
435 UINT16 SubClass; // Tiano extended Subclass code\r
7936fb6a 436 EFI_IMAGE_ID ImageId;\r
437\r
438 FORM_BROWSER_STATEMENT *StatementBuffer; // Buffer for all Statements and Questions\r
439 EXPRESSION_OPCODE *ExpressionBuffer; // Buffer for all Expression OpCode\r
440\r
7c6c064c 441 LIST_ENTRY StatementListOSF; // Statement list out side of the form.\r
7936fb6a 442 LIST_ENTRY StorageListHead; // Storage list (FORMSET_STORAGE)\r
443 LIST_ENTRY DefaultStoreListHead; // DefaultStore list (FORMSET_DEFAULTSTORE)\r
444 LIST_ENTRY FormListHead; // Form list (FORM_BROWSER_FORM)\r
0c66bc76 445 LIST_ENTRY ExpressionListHead; // List of Expressions (FORM_EXPRESSION)\r
7936fb6a 446} FORM_BROWSER_FORMSET;\r
25361615 447#define FORM_BROWSER_FORMSET_FROM_LINK(a) CR (a, FORM_BROWSER_FORMSET, Link, FORM_BROWSER_FORMSET_SIGNATURE)\r
b9feb4bd 448\r
7c6c064c
ED
449typedef struct {\r
450 LIST_ENTRY Link;\r
451 EFI_EVENT RefreshEvent;\r
452} FORM_BROWSER_REFRESH_EVENT_NODE;\r
453\r
454#define FORM_BROWSER_REFRESH_EVENT_FROM_LINK(a) BASE_CR (a, FORM_BROWSER_REFRESH_EVENT_NODE, Link)\r
455\r
b9feb4bd 456\r
48a9d5f7 457typedef struct {\r
7c6c064c 458 EFI_HII_HANDLE Handle;\r
48a9d5f7 459\r
7c6c064c
ED
460 //\r
461 // Target formset/form/Question information\r
462 //\r
463 EFI_GUID FormSetGuid;\r
464 UINT16 FormId;\r
465 UINT16 QuestionId;\r
466 UINTN Sequence; // used for time/date only.\r
467\r
468 UINTN TopRow;\r
469 UINTN BottomRow;\r
470 UINTN PromptCol;\r
471 UINTN OptionCol;\r
472 UINTN CurrentRow;\r
473\r
474 //\r
475 // Ation for Browser to taken:\r
476 // UI_ACTION_NONE - navigation inside a form\r
477 // UI_ACTION_REFRESH_FORM - re-evaluate expressions and repaint form\r
478 // UI_ACTION_REFRESH_FORMSET - re-parse formset IFR binary\r
479 //\r
480 UINTN Action;\r
481\r
482 //\r
483 // Current selected fomset/form/Question\r
484 //\r
485 FORM_BROWSER_FORMSET *FormSet;\r
486 FORM_BROWSER_FORM *Form;\r
487 FORM_BROWSER_STATEMENT *Statement;\r
488\r
489 //\r
490 // Whether the Form is editable\r
491 //\r
492 BOOLEAN FormEditable;\r
493\r
494 FORM_ENTRY_INFO *CurrentMenu;\r
495} UI_MENU_SELECTION;\r
48a9d5f7 496\r
5a9f73bf
ED
497#define BROWSER_CONTEXT_SIGNATURE SIGNATURE_32 ('B', 'C', 'T', 'X')\r
498\r
499typedef struct {\r
500 UINTN Signature;\r
501 LIST_ENTRY Link;\r
502\r
503 //\r
504 // Globals defined in Setup.c\r
505 //\r
506 BOOLEAN ResetRequired;\r
507 BOOLEAN ExitRequired;\r
508 EFI_HII_HANDLE HiiHandle;\r
509 EFI_GUID FormSetGuid;\r
510 EFI_FORM_ID FormId;\r
511 UI_MENU_SELECTION *Selection;\r
512\r
513 LIST_ENTRY FormHistoryList;\r
514} BROWSER_CONTEXT;\r
515\r
516#define BROWSER_CONTEXT_FROM_LINK(a) CR (a, BROWSER_CONTEXT, Link, BROWSER_CONTEXT_SIGNATURE)\r
517\r
09cdd7d2
ED
518//\r
519// Scope for get defaut value. It may be GetDefaultForNoStorage, GetDefaultForStorage or GetDefaultForAll.\r
520//\r
521typedef enum {\r
522 GetDefaultForNoStorage, // Get default value for question which not has storage.\r
523 GetDefaultForStorage, // Get default value for question which has storage.\r
524 GetDefaultForAll, // Get default value for all questions.\r
525 GetDefaultForMax // Invalid value.\r
526} BROWSER_GET_DEFAULT_VALUE;\r
527\r
816a7110
ED
528//\r
529// Get/set question value from/to.\r
530//\r
531typedef enum {\r
532 GetSetValueWithEditBuffer, // Get/Set question value from/to editbuffer in the storage.\r
533 GetSetValueWithBuffer, // Get/Set question value from/to buffer in the storage.\r
534 GetSetValueWithHiiDriver, // Get/Set question value from/to hii driver.\r
535 GetSetValueWithMax // Invalid value.\r
536} GET_SET_QUESTION_VALUE_WITH;\r
537\r
7936fb6a 538extern EFI_HII_DATABASE_PROTOCOL *mHiiDatabase;\r
7936fb6a 539extern EFI_HII_CONFIG_ROUTING_PROTOCOL *mHiiConfigRouting;\r
80a047f0 540extern EFI_DEVICE_PATH_FROM_TEXT_PROTOCOL *mPathFromText;\r
7c6c064c 541extern EDKII_FORM_DISPLAY_ENGINE_PROTOCOL *mFormDisplay;\r
7936fb6a 542\r
7936fb6a 543extern BOOLEAN gResetRequired;\r
7c6c064c 544extern BOOLEAN gExitRequired;\r
7936fb6a 545\r
48a9d5f7
LG
546extern LIST_ENTRY gBrowserFormSetList;\r
547extern LIST_ENTRY gBrowserHotKeyList;\r
548extern BROWSER_SETTING_SCOPE gBrowserSettingScope;\r
549extern EXIT_HANDLER ExitHandlerFunction;\r
7c6c064c 550extern EFI_HII_HANDLE mCurrentHiiHandle;\r
184f3a02 551extern SETUP_DRIVER_PRIVATE_DATA mPrivateData;\r
7936fb6a 552//\r
553// Browser Global Strings\r
554//\r
7936fb6a 555extern CHAR16 *gEmptyString;\r
7936fb6a 556\r
557extern EFI_GUID gZeroGuid;\r
7936fb6a 558\r
7c6c064c
ED
559extern UI_MENU_SELECTION *gCurrentSelection;\r
560\r
7936fb6a 561//\r
562// Global Procedure Defines\r
563//\r
7c6c064c 564#include "Expression.h"\r
7936fb6a 565\r
566/**\r
567 Initialize the HII String Token to the correct values.\r
568\r
569**/\r
570VOID\r
571InitializeBrowserStrings (\r
572 VOID\r
ed66e1bc 573 );\r
7936fb6a 574\r
7936fb6a 575/**\r
576 Parse opcodes in the formset IFR binary.\r
577\r
578 @param FormSet Pointer of the FormSet data structure.\r
579\r
580 @retval EFI_SUCCESS Opcode parse success.\r
581 @retval Other Opcode parse fail.\r
582\r
583**/\r
584EFI_STATUS\r
585ParseOpCodes (\r
586 IN FORM_BROWSER_FORMSET *FormSet\r
ed66e1bc 587 );\r
7936fb6a 588\r
589/**\r
590 Free resources allocated for a FormSet.\r
591\r
592 @param FormSet Pointer of the FormSet\r
593\r
594**/\r
595VOID\r
596DestroyFormSet (\r
597 IN OUT FORM_BROWSER_FORMSET *FormSet\r
ed66e1bc 598 );\r
7936fb6a 599\r
7936fb6a 600\r
601/**\r
602 Create a new string in HII Package List.\r
603\r
604 @param String The String to be added\r
605 @param HiiHandle The package list in the HII database to insert the\r
606 specified string.\r
607\r
608 @return The output string.\r
609\r
610**/\r
611EFI_STRING_ID\r
612NewString (\r
613 IN CHAR16 *String,\r
614 IN EFI_HII_HANDLE HiiHandle\r
ed66e1bc 615 );\r
7936fb6a 616\r
617/**\r
618 Delete a string from HII Package List.\r
619\r
620 @param StringId Id of the string in HII database.\r
621 @param HiiHandle The HII package list handle.\r
622\r
623 @retval EFI_SUCCESS The string was deleted successfully.\r
624\r
625**/\r
626EFI_STATUS\r
627DeleteString (\r
628 IN EFI_STRING_ID StringId,\r
629 IN EFI_HII_HANDLE HiiHandle\r
ed66e1bc 630 );\r
7936fb6a 631\r
632/**\r
633 Get the string based on the StringId and HII Package List Handle.\r
634\r
635 @param Token The String's ID.\r
636 @param HiiHandle The package list in the HII database to search for\r
637 the specified string.\r
638\r
639 @return The output string.\r
640\r
641**/\r
642CHAR16 *\r
643GetToken (\r
644 IN EFI_STRING_ID Token,\r
645 IN EFI_HII_HANDLE HiiHandle\r
ed66e1bc 646 );\r
7936fb6a 647\r
2573712e
LG
648/**\r
649 Get Value for given Name from a NameValue Storage.\r
650\r
651 @param Storage The NameValue Storage.\r
652 @param Name The Name.\r
653 @param Value The retured Value.\r
816a7110 654 @param GetValueFrom Where to get source value, from EditValue or Value.\r
2573712e
LG
655\r
656 @retval EFI_SUCCESS Value found for given Name.\r
657 @retval EFI_NOT_FOUND No such Name found in NameValue storage.\r
658\r
659**/\r
660EFI_STATUS\r
661GetValueByName (\r
94f3aae7 662 IN BROWSER_STORAGE *Storage,\r
816a7110
ED
663 IN CHAR16 *Name,\r
664 IN OUT CHAR16 **Value,\r
665 IN GET_SET_QUESTION_VALUE_WITH GetValueFrom\r
2573712e
LG
666 );\r
667\r
668/**\r
669 Set Value of given Name in a NameValue Storage.\r
670\r
671 @param Storage The NameValue Storage.\r
672 @param Name The Name.\r
673 @param Value The Value to set.\r
816a7110 674 @param SetValueTo Whether update editValue or Value.\r
7c6c064c 675 @param ReturnNode The node use the input name.\r
2573712e
LG
676\r
677 @retval EFI_SUCCESS Value found for given Name.\r
678 @retval EFI_NOT_FOUND No such Name found in NameValue storage.\r
679\r
680**/\r
681EFI_STATUS\r
682SetValueByName (\r
7c6c064c
ED
683 IN BROWSER_STORAGE *Storage,\r
684 IN CHAR16 *Name,\r
685 IN CHAR16 *Value,\r
686 IN GET_SET_QUESTION_VALUE_WITH SetValueTo,\r
687 OUT NAME_VALUE_NODE **ReturnNode\r
688 );\r
689\r
690/**\r
691 Validate whether this question's value has changed.\r
692\r
693 @param FormSet FormSet data structure.\r
694 @param Form Form data structure.\r
695 @param Question Question to be initialized.\r
696 @param GetValueFrom Where to get value, may from editbuffer, buffer or hii driver.\r
697\r
698 @retval TRUE Question's value has changed.\r
699 @retval FALSE Question's value has not changed\r
700\r
701**/\r
702BOOLEAN\r
703IsQuestionValueChanged (\r
704 IN FORM_BROWSER_FORMSET *FormSet,\r
705 IN FORM_BROWSER_FORM *Form,\r
706 IN OUT FORM_BROWSER_STATEMENT *Question,\r
707 IN GET_SET_QUESTION_VALUE_WITH GetValueFrom\r
2573712e
LG
708 );\r
709\r
7936fb6a 710/**\r
711 Get Question's current Value.\r
712\r
713 @param FormSet FormSet data structure.\r
714 @param Form Form data structure.\r
715 @param Question Question to be initialized.\r
816a7110 716 @param GetValueFrom Where to get value, may from editbuffer, buffer or hii driver.\r
7936fb6a 717\r
718 @retval EFI_SUCCESS The function completed successfully.\r
719\r
720**/\r
721EFI_STATUS\r
722GetQuestionValue (\r
723 IN FORM_BROWSER_FORMSET *FormSet,\r
724 IN FORM_BROWSER_FORM *Form,\r
725 IN OUT FORM_BROWSER_STATEMENT *Question,\r
816a7110 726 IN GET_SET_QUESTION_VALUE_WITH GetValueFrom\r
ed66e1bc 727 );\r
7936fb6a 728\r
729/**\r
730 Save Question Value to edit copy(cached) or Storage(uncached).\r
731\r
732 @param FormSet FormSet data structure.\r
733 @param Form Form data structure.\r
734 @param Question Pointer to the Question.\r
816a7110 735 @param SetValueTo Update the question value to editbuffer , buffer or hii driver.\r
7936fb6a 736\r
737 @retval EFI_SUCCESS The function completed successfully.\r
738\r
739**/\r
740EFI_STATUS\r
741SetQuestionValue (\r
742 IN FORM_BROWSER_FORMSET *FormSet,\r
743 IN FORM_BROWSER_FORM *Form,\r
744 IN OUT FORM_BROWSER_STATEMENT *Question,\r
816a7110 745 IN GET_SET_QUESTION_VALUE_WITH SetValueTo\r
ed66e1bc 746 );\r
7936fb6a 747\r
748/**\r
749 Perform inconsistent check for a Form.\r
750\r
751 @param FormSet FormSet data structure.\r
752 @param Form Form data structure.\r
753 @param Question The Question to be validated.\r
754 @param Type Validation type: InConsistent or NoSubmit\r
755\r
756 @retval EFI_SUCCESS Form validation pass.\r
757 @retval other Form validation failed.\r
758\r
759**/\r
760EFI_STATUS\r
761ValidateQuestion (\r
762 IN FORM_BROWSER_FORMSET *FormSet,\r
763 IN FORM_BROWSER_FORM *Form,\r
764 IN FORM_BROWSER_STATEMENT *Question,\r
765 IN UINTN Type\r
ed66e1bc 766 );\r
7936fb6a 767\r
48a9d5f7 768\r
7936fb6a 769/**\r
48a9d5f7 770 Discard data based on the input setting scope (Form, FormSet or System).\r
7936fb6a 771\r
772 @param FormSet FormSet data structure.\r
773 @param Form Form data structure.\r
48a9d5f7 774 @param SettingScope Setting Scope for Discard action.\r
b18e7050
ED
775\r
776 @retval EFI_SUCCESS The function completed successfully.\r
48a9d5f7 777 @retval EFI_UNSUPPORTED Unsupport SettingScope.\r
b18e7050
ED
778\r
779**/\r
780EFI_STATUS\r
781DiscardForm (\r
782 IN FORM_BROWSER_FORMSET *FormSet,\r
783 IN FORM_BROWSER_FORM *Form,\r
48a9d5f7 784 IN BROWSER_SETTING_SCOPE SettingScope\r
b18e7050
ED
785 );\r
786\r
787/**\r
48a9d5f7 788 Submit data based on the input Setting level (Form, FormSet or System).\r
b18e7050
ED
789\r
790 @param FormSet FormSet data structure.\r
791 @param Form Form data structure.\r
48a9d5f7 792 @param SettingScope Setting Scope for Submit action.\r
7936fb6a 793\r
794 @retval EFI_SUCCESS The function completed successfully.\r
48a9d5f7 795 @retval EFI_UNSUPPORTED Unsupport SettingScope.\r
7936fb6a 796\r
797**/\r
798EFI_STATUS\r
799SubmitForm (\r
800 IN FORM_BROWSER_FORMSET *FormSet,\r
b18e7050 801 IN FORM_BROWSER_FORM *Form,\r
48a9d5f7 802 IN BROWSER_SETTING_SCOPE SettingScope\r
ed66e1bc 803 );\r
7936fb6a 804\r
805/**\r
806 Reset Question to its default value.\r
807\r
808 @param FormSet The form set.\r
809 @param Form The form.\r
810 @param Question The question.\r
811 @param DefaultId The Class of the default.\r
812\r
813 @retval EFI_SUCCESS Question is reset to default value.\r
814\r
815**/\r
816EFI_STATUS\r
817GetQuestionDefault (\r
818 IN FORM_BROWSER_FORMSET *FormSet,\r
819 IN FORM_BROWSER_FORM *Form,\r
820 IN FORM_BROWSER_STATEMENT *Question,\r
821 IN UINT16 DefaultId\r
ed66e1bc 822 );\r
7936fb6a 823\r
824/**\r
825 Get current setting of Questions.\r
826\r
827 @param FormSet FormSet data structure.\r
828\r
7936fb6a 829**/\r
7c6c064c 830VOID\r
7936fb6a 831InitializeCurrentSetting (\r
832 IN OUT FORM_BROWSER_FORMSET *FormSet\r
ed66e1bc 833 );\r
7936fb6a 834\r
835/**\r
836 Initialize the internal data structure of a FormSet.\r
837\r
838 @param Handle PackageList Handle\r
839 @param FormSetGuid GUID of a formset. If not specified (NULL or zero\r
840 GUID), take the first FormSet found in package\r
841 list.\r
842 @param FormSet FormSet data structure.\r
843\r
844 @retval EFI_SUCCESS The function completed successfully.\r
845 @retval EFI_NOT_FOUND The specified FormSet could not be found.\r
846\r
847**/\r
848EFI_STATUS\r
849InitializeFormSet (\r
850 IN EFI_HII_HANDLE Handle,\r
851 IN OUT EFI_GUID *FormSetGuid,\r
7c6c064c 852 OUT FORM_BROWSER_FORMSET *FormSet \r
ed66e1bc 853 );\r
7936fb6a 854\r
855/**\r
9776099f 856 Reset Questions to their initial value or default value in a Form, Formset or System.\r
7936fb6a 857\r
09cdd7d2
ED
858 GetDefaultValueScope parameter decides which questions will reset \r
859 to its default value.\r
860\r
7936fb6a 861 @param FormSet FormSet data structure.\r
48a9d5f7 862 @param Form Form data structure.\r
7936fb6a 863 @param DefaultId The Class of the default.\r
48a9d5f7 864 @param SettingScope Setting Scope for Default action.\r
09cdd7d2 865 @param GetDefaultValueScope Get default value scope.\r
3347d410 866 @param Storage Get default value only for this storage.\r
9776099f
ED
867 @param RetrieveValueFirst Whether call the retrieve call back to\r
868 get the initial value before get default\r
869 value.\r
7936fb6a 870\r
871 @retval EFI_SUCCESS The function completed successfully.\r
48a9d5f7 872 @retval EFI_UNSUPPORTED Unsupport SettingScope.\r
7936fb6a 873\r
874**/\r
875EFI_STATUS\r
48a9d5f7 876ExtractDefault (\r
7936fb6a 877 IN FORM_BROWSER_FORMSET *FormSet,\r
48a9d5f7
LG
878 IN FORM_BROWSER_FORM *Form,\r
879 IN UINT16 DefaultId,\r
3347d410 880 IN BROWSER_SETTING_SCOPE SettingScope,\r
09cdd7d2 881 IN BROWSER_GET_DEFAULT_VALUE GetDefaultValueScope,\r
94f3aae7 882 IN BROWSER_STORAGE *Storage,\r
9776099f 883 IN BOOLEAN RetrieveValueFirst\r
ed66e1bc 884 );\r
7936fb6a 885\r
886/**\r
887 Initialize Question's Edit copy from Storage.\r
888\r
eccfeab1
LG
889 @param Selection Selection contains the information about \r
890 the Selection, form and formset to be displayed.\r
891 Selection action may be updated in retrieve callback.\r
7d1b202d 892 If Selection is NULL, only initialize Question value.\r
7936fb6a 893 @param FormSet FormSet data structure.\r
894 @param Form Form data structure.\r
895\r
896 @retval EFI_SUCCESS The function completed successfully.\r
897\r
898**/\r
899EFI_STATUS\r
900LoadFormConfig (\r
eccfeab1
LG
901 IN OUT UI_MENU_SELECTION *Selection,\r
902 IN FORM_BROWSER_FORMSET *FormSet,\r
903 IN FORM_BROWSER_FORM *Form\r
ed66e1bc 904 );\r
7936fb6a 905\r
d66e6c16 906/**\r
907 Initialize Question's Edit copy from Storage for the whole Formset.\r
908\r
eccfeab1
LG
909 @param Selection Selection contains the information about \r
910 the Selection, form and formset to be displayed.\r
911 Selection action may be updated in retrieve callback.\r
7d1b202d 912 If Selection is NULL, only initialize Question value.\r
d66e6c16 913 @param FormSet FormSet data structure.\r
914\r
915 @retval EFI_SUCCESS The function completed successfully.\r
916\r
917**/\r
918EFI_STATUS\r
919LoadFormSetConfig (\r
eccfeab1
LG
920 IN OUT UI_MENU_SELECTION *Selection,\r
921 IN FORM_BROWSER_FORMSET *FormSet\r
d66e6c16 922 );\r
923\r
7936fb6a 924/**\r
925 Convert setting of Buffer Storage or NameValue Storage to <ConfigResp>.\r
926\r
94f3aae7 927 @param Storage The Storage to be conveted.\r
7936fb6a 928 @param ConfigResp The returned <ConfigResp>.\r
94f3aae7 929 @param ConfigRequest The ConfigRequest string.\r
7c6c064c 930 @param GetEditBuf Get the data from editbuffer or buffer.\r
7936fb6a 931\r
932 @retval EFI_SUCCESS Convert success.\r
933 @retval EFI_INVALID_PARAMETER Incorrect storage type.\r
934\r
935**/\r
936EFI_STATUS\r
937StorageToConfigResp (\r
94f3aae7 938 IN BROWSER_STORAGE *Storage,\r
b18e7050 939 IN CHAR16 **ConfigResp,\r
7c6c064c
ED
940 IN CHAR16 *ConfigRequest,\r
941 IN BOOLEAN GetEditBuf\r
ed66e1bc 942 );\r
7936fb6a 943\r
944/**\r
945 Convert <ConfigResp> to settings in Buffer Storage or NameValue Storage.\r
946\r
947 @param Storage The Storage to receive the settings.\r
948 @param ConfigResp The <ConfigResp> to be converted.\r
949\r
950 @retval EFI_SUCCESS Convert success.\r
951 @retval EFI_INVALID_PARAMETER Incorrect storage type.\r
952\r
953**/\r
954EFI_STATUS\r
955ConfigRespToStorage (\r
94f3aae7 956 IN BROWSER_STORAGE *Storage,\r
7936fb6a 957 IN CHAR16 *ConfigResp\r
ed66e1bc 958 );\r
7936fb6a 959\r
960/**\r
961 Fill storage's edit copy with settings requested from Configuration Driver.\r
962\r
963 @param FormSet FormSet data structure.\r
964 @param Storage Buffer Storage.\r
965\r
7936fb6a 966**/\r
7c6c064c 967VOID\r
7936fb6a 968LoadStorage (\r
969 IN FORM_BROWSER_FORMSET *FormSet,\r
970 IN FORMSET_STORAGE *Storage\r
ed66e1bc 971 );\r
7936fb6a 972\r
973/**\r
974 Fetch the Ifr binary data of a FormSet.\r
975\r
976 @param Handle PackageList Handle\r
977 @param FormSetGuid GUID of a formset. If not specified (NULL or zero\r
978 GUID), take the first FormSet found in package\r
979 list.\r
980 @param BinaryLength The length of the FormSet IFR binary.\r
981 @param BinaryData The buffer designed to receive the FormSet.\r
982\r
983 @retval EFI_SUCCESS Buffer filled with the requested FormSet.\r
984 BufferLength was updated.\r
985 @retval EFI_INVALID_PARAMETER The handle is unknown.\r
986 @retval EFI_NOT_FOUND A form or FormSet on the requested handle cannot\r
987 be found with the requested FormId.\r
988\r
989**/\r
990EFI_STATUS\r
991GetIfrBinaryData (\r
992 IN EFI_HII_HANDLE Handle,\r
993 IN OUT EFI_GUID *FormSetGuid,\r
994 OUT UINTN *BinaryLength,\r
995 OUT UINT8 **BinaryData\r
ed66e1bc 996 );\r
7936fb6a 997\r
ce6d12cc 998/**\r
999 Save globals used by previous call to SendForm(). SendForm() may be called from \r
1000 HiiConfigAccess.Callback(), this will cause SendForm() be reentried.\r
1001 So, save globals of previous call to SendForm() and restore them upon exit.\r
1002\r
1003**/\r
1004VOID\r
1005SaveBrowserContext (\r
1006 VOID\r
1007 );\r
1008\r
1009/**\r
1010 Restore globals used by previous call to SendForm().\r
1011\r
1012**/\r
1013VOID\r
1014RestoreBrowserContext (\r
1015 VOID\r
1016 );\r
1017\r
7936fb6a 1018/**\r
1019 This is the routine which an external caller uses to direct the browser\r
1020 where to obtain it's information.\r
1021\r
1022\r
1023 @param This The Form Browser protocol instanse.\r
1024 @param Handles A pointer to an array of Handles. If HandleCount > 1 we\r
1025 display a list of the formsets for the handles specified.\r
1026 @param HandleCount The number of Handles specified in Handle.\r
1027 @param FormSetGuid This field points to the EFI_GUID which must match the Guid\r
1028 field in the EFI_IFR_FORM_SET op-code for the specified\r
1029 forms-based package. If FormSetGuid is NULL, then this\r
1030 function will display the first found forms package.\r
1031 @param FormId This field specifies which EFI_IFR_FORM to render as the first\r
1032 displayable page. If this field has a value of 0x0000, then\r
1033 the forms browser will render the specified forms in their encoded order.\r
1034 ScreenDimenions - This allows the browser to be called so that it occupies a\r
1035 portion of the physical screen instead of dynamically determining the screen dimensions.\r
1036 ActionRequest - Points to the action recommended by the form.\r
d66e6c16 1037 @param ScreenDimensions Points to recommended form dimensions, including any non-content area, in\r
7936fb6a 1038 characters.\r
1039 @param ActionRequest Points to the action recommended by the form.\r
1040\r
1041 @retval EFI_SUCCESS The function completed successfully.\r
1042 @retval EFI_INVALID_PARAMETER One of the parameters has an invalid value.\r
1043 @retval EFI_NOT_FOUND No valid forms could be found to display.\r
1044\r
1045**/\r
1046EFI_STATUS\r
1047EFIAPI\r
1048SendForm (\r
1049 IN CONST EFI_FORM_BROWSER2_PROTOCOL *This,\r
1050 IN EFI_HII_HANDLE *Handles,\r
1051 IN UINTN HandleCount,\r
1052 IN EFI_GUID *FormSetGuid, OPTIONAL\r
1053 IN UINT16 FormId, OPTIONAL\r
1054 IN CONST EFI_SCREEN_DESCRIPTOR *ScreenDimensions, OPTIONAL\r
1055 OUT EFI_BROWSER_ACTION_REQUEST *ActionRequest OPTIONAL\r
ed66e1bc 1056 );\r
7936fb6a 1057\r
1058/**\r
1059 This function is called by a callback handler to retrieve uncommitted state\r
1060 data from the browser.\r
1061\r
1062 @param This A pointer to the EFI_FORM_BROWSER2_PROTOCOL\r
1063 instance.\r
1064 @param ResultsDataSize A pointer to the size of the buffer associated\r
1065 with ResultsData.\r
1066 @param ResultsData A string returned from an IFR browser or\r
1067 equivalent. The results string will have no\r
1068 routing information in them.\r
1069 @param RetrieveData A BOOLEAN field which allows an agent to retrieve\r
1070 (if RetrieveData = TRUE) data from the uncommitted\r
1071 browser state information or set (if RetrieveData\r
1072 = FALSE) data in the uncommitted browser state\r
1073 information.\r
1074 @param VariableGuid An optional field to indicate the target variable\r
1075 GUID name to use.\r
1076 @param VariableName An optional field to indicate the target\r
1077 human-readable variable name.\r
1078\r
1079 @retval EFI_SUCCESS The results have been distributed or are awaiting\r
1080 distribution.\r
1081 @retval EFI_BUFFER_TOO_SMALL The ResultsDataSize specified was too small to\r
1082 contain the results data.\r
1083\r
1084**/\r
1085EFI_STATUS\r
1086EFIAPI\r
1087BrowserCallback (\r
1088 IN CONST EFI_FORM_BROWSER2_PROTOCOL *This,\r
1089 IN OUT UINTN *ResultsDataSize,\r
1090 IN OUT EFI_STRING ResultsData,\r
1091 IN BOOLEAN RetrieveData,\r
1092 IN CONST EFI_GUID *VariableGuid, OPTIONAL\r
1093 IN CONST CHAR16 *VariableName OPTIONAL\r
ed66e1bc 1094 );\r
7936fb6a 1095\r
b18e7050
ED
1096/**\r
1097 Find menu which will show next time.\r
1098\r
1099 @param Selection On input, Selection tell setup browser the information\r
1100 about the Selection, form and formset to be displayed.\r
1101 On output, Selection return the screen item that is selected\r
1102 by user.\r
7c6c064c
ED
1103 @param SettingLevel Input Settting level, if it is FormLevel, just exit current form. \r
1104 else, we need to exit current formset.\r
b18e7050 1105 \r
7c6c064c
ED
1106 @retval TRUE Exit current form.\r
1107 @retval FALSE User press ESC and keep in current form.\r
b18e7050
ED
1108**/\r
1109BOOLEAN\r
1110FindNextMenu (\r
7c6c064c
ED
1111 IN OUT UI_MENU_SELECTION *Selection,\r
1112 IN BROWSER_SETTING_SCOPE SettingLevel\r
b18e7050
ED
1113 );\r
1114\r
1115/**\r
7c6c064c 1116 check whether the form need to update the NV.\r
b18e7050 1117\r
7c6c064c 1118 @param Form Form data structure.\r
b18e7050 1119\r
7c6c064c
ED
1120 @retval TRUE Need to update the NV.\r
1121 @retval FALSE No need to update the NV.\r
b18e7050 1122**/\r
7c6c064c
ED
1123BOOLEAN\r
1124IsNvUpdateRequiredForForm (\r
1125 IN FORM_BROWSER_FORM *Form\r
b18e7050
ED
1126 );\r
1127\r
1128/**\r
1129 check whether the formset need to update the NV.\r
1130\r
1131 @param FormSet FormSet data structure.\r
1132\r
1133 @retval TRUE Need to update the NV.\r
1134 @retval FALSE No need to update the NV.\r
1135**/\r
7c6c064c
ED
1136BOOLEAN\r
1137IsNvUpdateRequiredForFormSet (\r
25361615 1138 IN FORM_BROWSER_FORMSET *FormSet\r
b9feb4bd
ED
1139 );\r
1140\r
7c6c064c
ED
1141/**\r
1142 Check whether the storage data for current form set is changed.\r
1143\r
1144 @param FormSet FormSet data structure.\r
1145\r
1146 @retval TRUE Data is changed.\r
1147 @retval FALSE Data is not changed.\r
1148**/\r
1149BOOLEAN \r
1150IsStorageDataChangedForFormSet (\r
1151 IN FORM_BROWSER_FORMSET *FormSet\r
1152 );\r
1153\r
b18e7050
ED
1154/**\r
1155 Call the call back function for the question and process the return action.\r
1156\r
1157 @param Selection On input, Selection tell setup browser the information\r
1158 about the Selection, form and formset to be displayed.\r
1159 On output, Selection return the screen item that is selected\r
1160 by user.\r
1161 @param Statement The Question which need to call.\r
1162 @param Action The action request.\r
1163 @param SkipSaveOrDiscard Whether skip save or discard action.\r
1164\r
1165 @retval EFI_SUCCESS The call back function excutes successfully.\r
1166 @return Other value if the call back function failed to excute. \r
1167**/\r
1168EFI_STATUS \r
1169ProcessCallBackFunction (\r
1170 IN OUT UI_MENU_SELECTION *Selection,\r
1171 IN FORM_BROWSER_STATEMENT *Question,\r
1172 IN EFI_BROWSER_ACTION Action,\r
1173 IN BOOLEAN SkipSaveOrDiscard\r
1174 );\r
9776099f
ED
1175 \r
1176/**\r
1177 Call the retrieve type call back function for one question to get the initialize data.\r
1178 \r
1179 This function only used when in the initialize stage, because in this stage, the \r
1180 Selection->Form is not ready. For other case, use the ProcessCallBackFunction instead.\r
1181\r
1182 @param ConfigAccess The config access protocol produced by the hii driver.\r
1183 @param Statement The Question which need to call.\r
1184\r
1185 @retval EFI_SUCCESS The call back function excutes successfully.\r
1186 @return Other value if the call back function failed to excute. \r
1187**/\r
1188EFI_STATUS \r
1189ProcessRetrieveForQuestion (\r
1190 IN EFI_HII_CONFIG_ACCESS_PROTOCOL *ConfigAccess,\r
1191 IN FORM_BROWSER_STATEMENT *Statement\r
1192 );\r
48a9d5f7
LG
1193\r
1194/**\r
1195 Find the matched FormSet context in the backup maintain list based on HiiHandle.\r
1196 \r
1197 @param Handle The Hii Handle.\r
1198 \r
1199 @return the found FormSet context. If no found, NULL will return.\r
1200\r
1201**/\r
1202FORM_BROWSER_FORMSET * \r
1203GetFormSetFromHiiHandle (\r
1204 EFI_HII_HANDLE Handle\r
1205 );\r
1206\r
1207/**\r
1208 Check whether the input HII handle is the FormSet that is being used.\r
1209 \r
1210 @param Handle The Hii Handle.\r
1211 \r
1212 @retval TRUE HII handle is being used.\r
1213 @retval FALSE HII handle is not being used.\r
1214\r
1215**/\r
1216BOOLEAN\r
1217IsHiiHandleInBrowserContext (\r
1218 EFI_HII_HANDLE Handle\r
1219 );\r
1220\r
1221/**\r
1222 Configure what scope the hot key will impact.\r
1223 All hot keys have the same scope. The mixed hot keys with the different level are not supported.\r
1224 If no scope is set, the default scope will be FormSet level.\r
1225 After all registered hot keys are removed, previous Scope can reset to another level.\r
1226 \r
1227 @param[in] Scope Scope level to be set. \r
1228 \r
1229 @retval EFI_SUCCESS Scope is set correctly.\r
1230 @retval EFI_INVALID_PARAMETER Scope is not the valid value specified in BROWSER_SETTING_SCOPE. \r
1231 @retval EFI_UNSPPORTED Scope level is different from current one that the registered hot keys have.\r
1232\r
1233**/\r
1234EFI_STATUS\r
1235EFIAPI\r
1236SetScope (\r
1237 IN BROWSER_SETTING_SCOPE Scope\r
1238 );\r
1239\r
1240/**\r
1241 Register the hot key with its browser action, or unregistered the hot key.\r
1242 Only support hot key that is not printable character (control key, function key, etc.).\r
1243 If the action value is zero, the hot key will be unregistered if it has been registered.\r
1244 If the same hot key has been registered, the new action and help string will override the previous ones.\r
1245 \r
1246 @param[in] KeyData A pointer to a buffer that describes the keystroke\r
1247 information for the hot key. Its type is EFI_INPUT_KEY to \r
1248 be supported by all ConsoleIn devices.\r
1249 @param[in] Action Action value that describes what action will be trigged when the hot key is pressed. \r
1250 @param[in] DefaultId Specifies the type of defaults to retrieve, which is only for DEFAULT action.\r
1251 @param[in] HelpString Help string that describes the hot key information.\r
1252 Its value may be NULL for the unregistered hot key.\r
1253 \r
1254 @retval EFI_SUCCESS Hot key is registered or unregistered.\r
1255 @retval EFI_INVALID_PARAMETER KeyData is NULL.\r
1256 @retval EFI_NOT_FOUND KeyData is not found to be unregistered.\r
1257 @retval EFI_UNSUPPORTED Key represents a printable character. It is conflicted with Browser.\r
1258**/\r
1259EFI_STATUS\r
1260EFIAPI\r
1261RegisterHotKey (\r
1262 IN EFI_INPUT_KEY *KeyData,\r
1263 IN UINT32 Action,\r
1264 IN UINT16 DefaultId,\r
1265 IN EFI_STRING HelpString OPTIONAL\r
1266 );\r
1267\r
1268/**\r
1269 Register Exit handler function. \r
1270 When more than one handler function is registered, the latter one will override the previous one. \r
1271 When NULL handler is specified, the previous Exit handler will be unregistered. \r
1272 \r
1273 @param[in] Handler Pointer to handler function. \r
1274\r
1275**/\r
1276VOID\r
1277EFIAPI\r
1278RegiserExitHandler (\r
1279 IN EXIT_HANDLER Handler\r
1280 );\r
1281\r
7c6c064c
ED
1282/**\r
1283 \r
1284 Check whether the browser data has been modified. \r
1285\r
1286 @retval TRUE Browser data is changed.\r
1287 @retval FALSE No browser data is changed.\r
1288\r
1289**/\r
1290BOOLEAN \r
1291EFIAPI\r
1292IsBrowserDataModified (\r
1293 VOID\r
1294 );\r
1295\r
1296/**\r
1297 \r
1298 Execute the action requested by the Action parameter. \r
1299\r
1300 @param[in] Action Execute the request action.\r
1301 @param[in] DefaultId The default Id info when need to load default value.\r
1302\r
1303 @retval EFI_SUCCESS Execute the request action succss.\r
1304 @retval EFI_INVALID_PARAMETER The input action value is invalid.\r
1305\r
1306**/\r
1307EFI_STATUS \r
1308EFIAPI\r
1309ExecuteAction (\r
1310 IN UINT32 Action,\r
1311 IN UINT16 DefaultId\r
1312 );\r
1313\r
48a9d5f7
LG
1314/**\r
1315 Create reminder to let user to choose save or discard the changed browser data.\r
1316 Caller can use it to actively check the changed browser data.\r
1317\r
1318 @retval BROWSER_NO_CHANGES No browser data is changed.\r
1319 @retval BROWSER_SAVE_CHANGES The changed browser data is saved.\r
1320 @retval BROWSER_DISCARD_CHANGES The changed browser data is discard.\r
1321\r
1322**/\r
1323UINT32\r
1324EFIAPI\r
1325SaveReminder (\r
1326 VOID\r
1327 );\r
1328\r
1329/**\r
1330 Find the registered HotKey based on KeyData.\r
1331 \r
1332 @param[in] KeyData A pointer to a buffer that describes the keystroke\r
1333 information for the hot key.\r
1334\r
1335 @return The registered HotKey context. If no found, NULL will return.\r
1336**/\r
1337BROWSER_HOT_KEY *\r
1338GetHotKeyFromRegisterList (\r
1339 IN EFI_INPUT_KEY *KeyData\r
1340 );\r
1341\r
7c6c064c
ED
1342/**\r
1343\r
1344 Get FORM_BROWSER_STATEMENT from FORM_DISPLAY_ENGINE_STATEMENT based on the OpCode info.\r
1345\r
1346 @param DisplayStatement The input FORM_DISPLAY_ENGINE_STATEMENT.\r
1347\r
1348 @retval FORM_BROWSER_STATEMENT The return FORM_BROWSER_STATEMENT info.\r
1349\r
1350**/\r
1351FORM_BROWSER_STATEMENT *\r
1352GetBrowserStatement (\r
1353 IN FORM_DISPLAY_ENGINE_STATEMENT *DisplayStatement\r
1354 );\r
1355 \r
1356/**\r
1357 Password may be stored as encrypted by Configuration Driver. When change a\r
1358 password, user will be challenged with old password. To validate user input old\r
1359 password, we will send the clear text to Configuration Driver via Callback().\r
1360 Configuration driver is responsible to check the passed in password and return\r
1361 the validation result. If validation pass, state machine in password Callback()\r
1362 will transit from BROWSER_STATE_VALIDATE_PASSWORD to BROWSER_STATE_SET_PASSWORD.\r
1363 After user type in new password twice, Callback() will be invoked to send the\r
1364 new password to Configuration Driver.\r
1365\r
1366 @param Selection Pointer to UI_MENU_SELECTION.\r
1367 @param MenuOption The MenuOption for this password Question.\r
1368 @param String The clear text of password.\r
1369\r
1370 @retval EFI_NOT_AVAILABLE_YET Callback() request to terminate password input.\r
1371 @return In state of BROWSER_STATE_VALIDATE_PASSWORD:\r
1372 @retval EFI_SUCCESS Password correct, Browser will prompt for new\r
1373 password.\r
1374 @retval EFI_NOT_READY Password incorrect, Browser will show error\r
1375 message.\r
1376 @retval Other Browser will do nothing.\r
1377 @return In state of BROWSER_STATE_SET_PASSWORD:\r
1378 @retval EFI_SUCCESS Set password success.\r
1379 @retval Other Set password failed.\r
1380\r
1381**/\r
1382EFI_STATUS\r
1383PasswordCallback (\r
1384 IN UI_MENU_SELECTION *Selection,\r
1385 IN FORM_BROWSER_STATEMENT *Question,\r
1386 IN CHAR16 *String\r
1387 );\r
1388\r
1389/**\r
1390 Display error message for invalid password.\r
1391\r
1392**/\r
1393VOID\r
1394PasswordInvalid (\r
1395 VOID\r
1396 );\r
1397\r
1398/**\r
1399 The worker function that send the displays to the screen. On output,\r
1400 the selection made by user is returned.\r
1401\r
1402 @param Selection On input, Selection tell setup browser the information\r
1403 about the Selection, form and formset to be displayed.\r
1404 On output, Selection return the screen item that is selected\r
1405 by user.\r
1406\r
1407 @retval EFI_SUCCESS The page is displayed successfully.\r
1408 @return Other value if the page failed to be diplayed.\r
1409\r
1410**/\r
1411EFI_STATUS\r
1412SetupBrowser (\r
1413 IN OUT UI_MENU_SELECTION *Selection\r
1414 );\r
1415 \r
1416/**\r
1417 Free up the resource allocated for all strings required\r
1418 by Setup Browser.\r
1419\r
1420**/\r
1421VOID\r
1422FreeBrowserStrings (\r
1423 VOID\r
1424 );\r
1425\r
1426/**\r
1427 Create a menu with specified formset GUID and form ID, and add it as a child\r
1428 of the given parent menu.\r
1429\r
1430 @param HiiHandle Hii handle related to this formset.\r
1431 @param FormSetGuid The Formset Guid of menu to be added.\r
1432 @param FormId The Form ID of menu to be added.\r
1433 @param QuestionId The question id of this menu to be added.\r
1434\r
1435 @return A pointer to the newly added menu or NULL if memory is insufficient.\r
1436\r
1437**/\r
1438FORM_ENTRY_INFO *\r
1439UiAddMenuList (\r
1440 IN EFI_HII_HANDLE HiiHandle,\r
1441 IN EFI_GUID *FormSetGuid,\r
1442 IN UINT16 FormId,\r
1443 IN UINT16 QuestionId\r
1444 );\r
1445\r
1446/**\r
1447 Search Menu with given FormSetGuid and FormId in all cached menu list.\r
1448\r
1449 @param HiiHandle HiiHandle for FormSet.\r
1450 @param FormSetGuid The Formset GUID of the menu to search.\r
1451 @param FormId The Form ID of menu to search.\r
1452\r
1453 @return A pointer to menu found or NULL if not found.\r
1454\r
1455**/\r
1456FORM_ENTRY_INFO *\r
1457UiFindMenuList (\r
1458 IN EFI_HII_HANDLE HiiHandle, \r
1459 IN EFI_GUID *FormSetGuid,\r
1460 IN UINT16 FormId\r
1461 );\r
1462\r
1463/**\r
1464 Free Menu list linked list.\r
1465\r
1466 @param MenuListHead One Menu list point in the menu list.\r
1467\r
1468**/\r
1469VOID\r
1470UiFreeMenuList (\r
1471 LIST_ENTRY *MenuListHead\r
1472 );\r
1473\r
1474/**\r
1475 Find parent menu for current menu.\r
1476\r
1477 @param CurrentMenu Current Menu\r
1478\r
1479 @retval The parent menu for current menu.\r
1480**/\r
1481FORM_ENTRY_INFO *\r
1482UiFindParentMenu (\r
1483 IN FORM_ENTRY_INFO *CurrentMenu\r
1484 );\r
1485\r
1486/**\r
1487 Search an Option of a Question by its value.\r
1488\r
1489 @param Question The Question\r
1490 @param OptionValue Value for Option to be searched.\r
1491\r
1492 @retval Pointer Pointer to the found Option.\r
1493 @retval NULL Option not found.\r
1494\r
1495**/\r
1496QUESTION_OPTION *\r
1497ValueToOption (\r
1498 IN FORM_BROWSER_STATEMENT *Question,\r
1499 IN EFI_HII_VALUE *OptionValue\r
1500 );\r
1501/**\r
1502 Return data element in an Array by its Index.\r
1503\r
1504 @param Array The data array.\r
1505 @param Type Type of the data in this array.\r
1506 @param Index Zero based index for data in this array.\r
1507\r
1508 @retval Value The data to be returned\r
1509\r
1510**/\r
1511UINT64\r
1512GetArrayData (\r
1513 IN VOID *Array,\r
1514 IN UINT8 Type,\r
1515 IN UINTN Index\r
1516 );\r
1517\r
1518/**\r
1519 Set value of a data element in an Array by its Index.\r
1520\r
1521 @param Array The data array.\r
1522 @param Type Type of the data in this array.\r
1523 @param Index Zero based index for data in this array.\r
1524 @param Value The value to be set.\r
1525\r
1526**/\r
1527VOID\r
1528SetArrayData (\r
1529 IN VOID *Array,\r
1530 IN UINT8 Type,\r
1531 IN UINTN Index,\r
1532 IN UINT64 Value\r
1533 );\r
1534\r
1535/**\r
1536 Compare two Hii value.\r
1537 \r
1538 @param Value1 Expression value to compare on left-hand.\r
1539 @param Value2 Expression value to compare on right-hand.\r
1540 @param Result Return value after compare.\r
1541 retval 0 Two operators equal.\r
1542 return Positive value if Value1 is greater than Value2.\r
1543 retval Negative value if Value1 is less than Value2.\r
1544 @param HiiHandle Only required for string compare.\r
1545 \r
1546 @retval other Could not perform compare on two values.\r
1547 @retval EFI_SUCCESS Compare the value success.\r
1548 \r
1549**/\r
1550EFI_STATUS\r
1551CompareHiiValue (\r
1552 IN EFI_HII_VALUE *Value1,\r
1553 IN EFI_HII_VALUE *Value2,\r
1554 OUT INTN *Result,\r
1555 IN EFI_HII_HANDLE HiiHandle OPTIONAL\r
1556 );\r
1557\r
1558/**\r
1559 Perform Password check. \r
1560 Passwork may be encrypted by driver that requires the specific check.\r
1561 \r
1562 @param Form Form where Password Statement is in.\r
1563 @param Statement Password statement\r
1564 @param PasswordString Password string to be checked. It may be NULL.\r
1565 NULL means to restore password.\r
1566 "" string can be used to checked whether old password does exist.\r
1567 \r
1568 @return Status Status of Password check.\r
1569**/\r
1570EFI_STATUS\r
1571EFIAPI\r
1572PasswordCheck (\r
1573 IN FORM_DISPLAY_ENGINE_FORM *Form,\r
1574 IN FORM_DISPLAY_ENGINE_STATEMENT *Statement,\r
1575 IN EFI_STRING PasswordString OPTIONAL\r
1576 );\r
1577\r
1578/**\r
1579\r
1580 Get FORM_BROWSER_STATEMENT from FORM_DISPLAY_ENGINE_STATEMENT based on the OpCode info.\r
1581\r
1582 @param DisplayStatement The input FORM_DISPLAY_ENGINE_STATEMENT.\r
1583\r
1584 @retval FORM_BROWSER_STATEMENT The return FORM_BROWSER_STATEMENT info.\r
1585\r
1586**/\r
1587FORM_BROWSER_STATEMENT *\r
1588GetBrowserStatement (\r
1589 IN FORM_DISPLAY_ENGINE_STATEMENT *DisplayStatement\r
1590 );\r
1591 \r
1592/**\r
1593\r
1594 Initialize the Display form structure data.\r
1595\r
1596**/\r
1597VOID\r
1598InitializeDisplayFormData (\r
1599 VOID\r
1600 );\r
1601\r
1602\r
0a6f8af5
ED
1603/**\r
1604 Base on the current formset info, clean the ConfigRequest string in browser storage.\r
1605\r
1606 @param FormSet Pointer of the FormSet\r
1607\r
1608**/\r
1609VOID\r
1610CleanBrowserStorage (\r
1611 IN OUT FORM_BROWSER_FORMSET *FormSet\r
1612 );\r
7c6c064c 1613 \r
7936fb6a 1614#endif\r