]>
Commit | Line | Data |
---|---|---|
959ccb23 | 1 | /** @file\r |
2 | This file defines the encoding for the VFR (Visual Form Representation) language.\r | |
3 | IFR is primarily consumed by the EFI presentation engine, and produced by EFI\r | |
4 | internal application and drivers as well as all add-in card option-ROM drivers\r | |
5 | \r | |
774b5736 | 6 | Copyright (c) 2006 - 2013, Intel Corporation. All rights reserved.<BR>\r |
af2dc6a7 | 7 | This program and the accompanying materials are licensed and made available under \r |
8 | the terms and conditions of the BSD License that accompanies this distribution. \r | |
9 | The full text of the license may be found at\r | |
10 | http://opensource.org/licenses/bsd-license.php. \r | |
11 | \r | |
12 | THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS, \r | |
13 | WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED. \r | |
959ccb23 | 14 | \r |
959ccb23 | 15 | @par Revision Reference:\r |
f6051525 | 16 | These definitions are from UEFI 2.1 and 2.2.\r |
959ccb23 | 17 | \r |
18 | **/\r | |
19 | \r | |
20 | #ifndef __UEFI_INTERNAL_FORMREPRESENTATION_H__\r | |
21 | #define __UEFI_INTERNAL_FORMREPRESENTATION_H__\r | |
22 | \r | |
0cd118f7 LG |
23 | #include <Guid/HiiFormMapMethodGuid.h>\r |
24 | \r | |
fb5148a0 | 25 | ///\r |
26 | /// The following types are currently defined:\r | |
27 | ///\r | |
7d582d6b | 28 | typedef VOID* EFI_HII_HANDLE;\r |
29 | typedef CHAR16* EFI_STRING;\r | |
d1f95000 | 30 | typedef UINT16 EFI_IMAGE_ID;\r |
31 | typedef UINT16 EFI_QUESTION_ID;\r | |
32 | typedef UINT16 EFI_STRING_ID;\r | |
33 | typedef UINT16 EFI_FORM_ID;\r | |
34 | typedef UINT16 EFI_VARSTORE_ID;\r | |
f6051525 | 35 | typedef UINT16 EFI_ANIMATION_ID;\r |
e0c047a0 | 36 | \r |
7d582d6b | 37 | typedef UINT16 EFI_DEFAULT_ID;\r |
e0c047a0 | 38 | \r |
7d582d6b | 39 | typedef UINT32 EFI_HII_FONT_STYLE;\r |
d1f95000 | 40 | \r |
959ccb23 | 41 | \r |
959ccb23 | 42 | \r |
43 | #pragma pack(1)\r | |
7d582d6b | 44 | \r |
e0c047a0 | 45 | //\r |
46 | // Definitions for Package Lists and Package Headers\r | |
47 | // Section 27.3.1\r | |
48 | //\r | |
7d582d6b | 49 | \r |
8b13229b | 50 | ///\r |
e0c047a0 | 51 | /// The header found at the start of each package list.\r |
8b13229b | 52 | ///\r |
959ccb23 | 53 | typedef struct {\r |
7d582d6b | 54 | EFI_GUID PackageListGuid;\r |
55 | UINT32 PackageLength;\r | |
56 | } EFI_HII_PACKAGE_LIST_HEADER;\r | |
959ccb23 | 57 | \r |
e0c047a0 | 58 | ///\r |
59 | /// The header found at the start of each package.\r | |
60 | ///\r | |
959ccb23 | 61 | typedef struct {\r |
7d582d6b | 62 | UINT32 Length:24;\r |
63 | UINT32 Type:8;\r | |
64 | // UINT8 Data[...];\r | |
65 | } EFI_HII_PACKAGE_HEADER;\r | |
959ccb23 | 66 | \r |
7d582d6b | 67 | //\r |
e0c047a0 | 68 | // Value of HII package type\r |
7d582d6b | 69 | // \r |
70 | #define EFI_HII_PACKAGE_TYPE_ALL 0x00\r | |
71 | #define EFI_HII_PACKAGE_TYPE_GUID 0x01\r | |
9185c388 | 72 | #define EFI_HII_PACKAGE_FORMS 0x02\r |
7d582d6b | 73 | #define EFI_HII_PACKAGE_STRINGS 0x04\r |
74 | #define EFI_HII_PACKAGE_FONTS 0x05\r | |
75 | #define EFI_HII_PACKAGE_IMAGES 0x06\r | |
76 | #define EFI_HII_PACKAGE_SIMPLE_FONTS 0x07\r | |
77 | #define EFI_HII_PACKAGE_DEVICE_PATH 0x08\r | |
9185c388 | 78 | #define EFI_HII_PACKAGE_KEYBOARD_LAYOUT 0x09\r |
66d550f9 | 79 | #define EFI_HII_PACKAGE_ANIMATIONS 0x0A\r |
7d582d6b | 80 | #define EFI_HII_PACKAGE_END 0xDF\r |
81 | #define EFI_HII_PACKAGE_TYPE_SYSTEM_BEGIN 0xE0\r | |
82 | #define EFI_HII_PACKAGE_TYPE_SYSTEM_END 0xFF\r | |
959ccb23 | 83 | \r |
7d582d6b | 84 | //\r |
e0c047a0 | 85 | // Definitions for Simplified Font Package\r |
7d582d6b | 86 | //\r |
87 | \r | |
fbf926ad | 88 | ///\r |
af2dc6a7 | 89 | /// Contents of EFI_NARROW_GLYPH.Attributes.\r |
fbf926ad | 90 | ///@{\r |
7d582d6b | 91 | #define EFI_GLYPH_NON_SPACING 0x01\r |
92 | #define EFI_GLYPH_WIDE 0x02\r | |
e0c047a0 | 93 | #define EFI_GLYPH_HEIGHT 19\r |
94 | #define EFI_GLYPH_WIDTH 8\r | |
fbf926ad | 95 | ///@}\r |
959ccb23 | 96 | \r |
fbf926ad | 97 | ///\r |
98 | /// The EFI_NARROW_GLYPH has a preferred dimension (w x h) of 8 x 19 pixels.\r | |
99 | ///\r | |
959ccb23 | 100 | typedef struct {\r |
fbf926ad | 101 | ///\r |
102 | /// The Unicode representation of the glyph. The term weight is the \r | |
103 | /// technical term for a character code.\r | |
104 | ///\r | |
7d582d6b | 105 | CHAR16 UnicodeWeight;\r |
fbf926ad | 106 | ///\r |
107 | /// The data element containing the glyph definitions.\r | |
108 | ///\r | |
7d582d6b | 109 | UINT8 Attributes;\r |
fbf926ad | 110 | ///\r |
111 | /// The column major glyph representation of the character. Bits \r | |
112 | /// with values of one indicate that the corresponding pixel is to be\r | |
113 | /// on when normally displayed; those with zero are off.\r | |
114 | ///\r | |
7d582d6b | 115 | UINT8 GlyphCol1[EFI_GLYPH_HEIGHT];\r |
116 | } EFI_NARROW_GLYPH;\r | |
959ccb23 | 117 | \r |
fbf926ad | 118 | ///\r |
119 | /// The EFI_WIDE_GLYPH has a preferred dimension (w x h) of 16 x 19 pixels, which is large enough \r | |
120 | /// to accommodate logographic characters.\r | |
121 | ///\r | |
959ccb23 | 122 | typedef struct {\r |
fbf926ad | 123 | ///\r |
124 | /// The Unicode representation of the glyph. The term weight is the \r | |
125 | /// technical term for a character code.\r | |
126 | ///\r | |
7d582d6b | 127 | CHAR16 UnicodeWeight;\r |
fbf926ad | 128 | ///\r |
129 | /// The data element containing the glyph definitions.\r | |
130 | ///\r | |
7d582d6b | 131 | UINT8 Attributes;\r |
fbf926ad | 132 | ///\r |
133 | /// The column major glyph representation of the character. Bits \r | |
134 | /// with values of one indicate that the corresponding pixel is to be \r | |
135 | /// on when normally displayed; those with zero are off.\r | |
136 | ///\r | |
7d582d6b | 137 | UINT8 GlyphCol1[EFI_GLYPH_HEIGHT];\r |
fbf926ad | 138 | ///\r |
139 | /// The column major glyph representation of the character. Bits \r | |
140 | /// with values of one indicate that the corresponding pixel is to be \r | |
141 | /// on when normally displayed; those with zero are off.\r | |
142 | ///\r | |
7d582d6b | 143 | UINT8 GlyphCol2[EFI_GLYPH_HEIGHT];\r |
fbf926ad | 144 | ///\r |
145 | /// Ensures that sizeof (EFI_WIDE_GLYPH) is twice the \r | |
146 | /// sizeof (EFI_NARROW_GLYPH). The contents of Pad must \r | |
147 | /// be zero.\r | |
148 | ///\r | |
7d582d6b | 149 | UINT8 Pad[3];\r |
150 | } EFI_WIDE_GLYPH;\r | |
151 | \r | |
e0c047a0 | 152 | ///\r |
153 | /// A simplified font package consists of a font header\r | |
154 | /// followed by a series of glyph structures.\r | |
155 | ///\r | |
7d582d6b | 156 | typedef struct _EFI_HII_SIMPLE_FONT_PACKAGE_HDR {\r |
157 | EFI_HII_PACKAGE_HEADER Header;\r | |
158 | UINT16 NumberOfNarrowGlyphs;\r | |
159 | UINT16 NumberOfWideGlyphs;\r | |
160 | // EFI_NARROW_GLYPH NarrowGlyphs[];\r | |
161 | // EFI_WIDE_GLYPH WideGlyphs[];\r | |
162 | } EFI_HII_SIMPLE_FONT_PACKAGE_HDR;\r | |
959ccb23 | 163 | \r |
164 | //\r | |
e0c047a0 | 165 | // Definitions for Font Package\r |
166 | // Section 27.3.3\r | |
959ccb23 | 167 | //\r |
959ccb23 | 168 | \r |
e0c047a0 | 169 | //\r |
170 | // Value for font style\r | |
171 | //\r | |
54cf8780 | 172 | #define EFI_HII_FONT_STYLE_NORMAL 0x00000000\r |
7d582d6b | 173 | #define EFI_HII_FONT_STYLE_BOLD 0x00000001\r |
174 | #define EFI_HII_FONT_STYLE_ITALIC 0x00000002\r | |
175 | #define EFI_HII_FONT_STYLE_EMBOSS 0x00010000\r | |
176 | #define EFI_HII_FONT_STYLE_OUTLINE 0x00020000\r | |
177 | #define EFI_HII_FONT_STYLE_SHADOW 0x00040000\r | |
178 | #define EFI_HII_FONT_STYLE_UNDERLINE 0x00080000\r | |
179 | #define EFI_HII_FONT_STYLE_DBL_UNDER 0x00100000\r | |
959ccb23 | 180 | \r |
7d582d6b | 181 | typedef struct _EFI_HII_GLYPH_INFO {\r |
182 | UINT16 Width;\r | |
183 | UINT16 Height;\r | |
184 | INT16 OffsetX;\r | |
185 | INT16 OffsetY;\r | |
186 | INT16 AdvanceX;\r | |
187 | } EFI_HII_GLYPH_INFO;\r | |
188 | \r | |
e0c047a0 | 189 | ///\r |
af2dc6a7 | 190 | /// The fixed header consists of a standard record header,\r |
e0c047a0 | 191 | /// then the character values in this section, the flags\r |
192 | /// (including the encoding method) and the offsets of the glyph\r | |
193 | /// information, the glyph bitmaps and the character map.\r | |
194 | ///\r | |
7d582d6b | 195 | typedef struct _EFI_HII_FONT_PACKAGE_HDR {\r |
196 | EFI_HII_PACKAGE_HEADER Header;\r | |
197 | UINT32 HdrSize;\r | |
198 | UINT32 GlyphBlockOffset;\r | |
199 | EFI_HII_GLYPH_INFO Cell;\r | |
200 | EFI_HII_FONT_STYLE FontStyle;\r | |
201 | CHAR16 FontFamily[1];\r | |
202 | } EFI_HII_FONT_PACKAGE_HDR;\r | |
203 | \r | |
e0c047a0 | 204 | //\r |
205 | // Value of different glyph info block types\r | |
206 | //\r | |
7d582d6b | 207 | #define EFI_HII_GIBT_END 0x00\r |
208 | #define EFI_HII_GIBT_GLYPH 0x10\r | |
209 | #define EFI_HII_GIBT_GLYPHS 0x11\r | |
210 | #define EFI_HII_GIBT_GLYPH_DEFAULT 0x12\r | |
211 | #define EFI_HII_GIBT_GLYPHS_DEFAULT 0x13\r | |
212 | #define EFI_HII_GIBT_DUPLICATE 0x20\r | |
213 | #define EFI_HII_GIBT_SKIP2 0x21\r | |
214 | #define EFI_HII_GIBT_SKIP1 0x22\r | |
215 | #define EFI_HII_GIBT_DEFAULTS 0x23\r | |
216 | #define EFI_HII_GIBT_EXT1 0x30\r | |
217 | #define EFI_HII_GIBT_EXT2 0x31\r | |
218 | #define EFI_HII_GIBT_EXT4 0x32\r | |
219 | \r | |
220 | typedef struct _EFI_HII_GLYPH_BLOCK {\r | |
221 | UINT8 BlockType;\r | |
222 | } EFI_HII_GLYPH_BLOCK;\r | |
223 | \r | |
e0c047a0 | 224 | //\r |
225 | // Definition of different glyph info block types\r | |
226 | //\r | |
227 | \r | |
7d582d6b | 228 | typedef struct _EFI_HII_GIBT_DEFAULTS_BLOCK {\r |
229 | EFI_HII_GLYPH_BLOCK Header;\r | |
230 | EFI_HII_GLYPH_INFO Cell;\r | |
231 | } EFI_HII_GIBT_DEFAULTS_BLOCK;\r | |
232 | \r | |
233 | typedef struct _EFI_HII_GIBT_DUPLICATE_BLOCK {\r | |
234 | EFI_HII_GLYPH_BLOCK Header;\r | |
235 | CHAR16 CharValue;\r | |
236 | } EFI_HII_GIBT_DUPLICATE_BLOCK;\r | |
237 | \r | |
238 | typedef struct _EFI_GLYPH_GIBT_END_BLOCK {\r | |
239 | EFI_HII_GLYPH_BLOCK Header;\r | |
240 | } EFI_GLYPH_GIBT_END_BLOCK;\r | |
241 | \r | |
242 | typedef struct _EFI_HII_GIBT_EXT1_BLOCK {\r | |
243 | EFI_HII_GLYPH_BLOCK Header;\r | |
244 | UINT8 BlockType2;\r | |
245 | UINT8 Length;\r | |
246 | } EFI_HII_GIBT_EXT1_BLOCK;\r | |
247 | \r | |
248 | typedef struct _EFI_HII_GIBT_EXT2_BLOCK {\r | |
249 | EFI_HII_GLYPH_BLOCK Header;\r | |
250 | UINT8 BlockType2;\r | |
251 | UINT16 Length;\r | |
252 | } EFI_HII_GIBT_EXT2_BLOCK;\r | |
253 | \r | |
254 | typedef struct _EFI_HII_GIBT_EXT4_BLOCK {\r | |
255 | EFI_HII_GLYPH_BLOCK Header;\r | |
256 | UINT8 BlockType2;\r | |
257 | UINT32 Length;\r | |
258 | } EFI_HII_GIBT_EXT4_BLOCK;\r | |
259 | \r | |
260 | typedef struct _EFI_HII_GIBT_GLYPH_BLOCK {\r | |
261 | EFI_HII_GLYPH_BLOCK Header;\r | |
262 | EFI_HII_GLYPH_INFO Cell;\r | |
e0c047a0 | 263 | UINT8 BitmapData[1];\r |
7d582d6b | 264 | } EFI_HII_GIBT_GLYPH_BLOCK;\r |
265 | \r | |
266 | typedef struct _EFI_HII_GIBT_GLYPHS_BLOCK {\r | |
267 | EFI_HII_GLYPH_BLOCK Header;\r | |
268 | EFI_HII_GLYPH_INFO Cell;\r | |
269 | UINT16 Count; \r | |
e0c047a0 | 270 | UINT8 BitmapData[1];\r |
7d582d6b | 271 | } EFI_HII_GIBT_GLYPHS_BLOCK;\r |
272 | \r | |
273 | typedef struct _EFI_HII_GIBT_GLYPH_DEFAULT_BLOCK {\r | |
274 | EFI_HII_GLYPH_BLOCK Header;\r | |
e0c047a0 | 275 | UINT8 BitmapData[1];\r |
7d582d6b | 276 | } EFI_HII_GIBT_GLYPH_DEFAULT_BLOCK;\r |
277 | \r | |
278 | typedef struct _EFI_HII_GIBT_GLYPHS_DEFAULT_BLOCK {\r | |
279 | EFI_HII_GLYPH_BLOCK Header;\r | |
280 | UINT16 Count;\r | |
e0c047a0 | 281 | UINT8 BitmapData[1];\r |
7d582d6b | 282 | } EFI_HII_GIBT_GLYPHS_DEFAULT_BLOCK;\r |
283 | \r | |
284 | typedef struct _EFI_HII_GIBT_SKIP1_BLOCK {\r | |
285 | EFI_HII_GLYPH_BLOCK Header;\r | |
286 | UINT8 SkipCount;\r | |
287 | } EFI_HII_GIBT_SKIP1_BLOCK;\r | |
288 | \r | |
289 | typedef struct _EFI_HII_GIBT_SKIP2_BLOCK {\r | |
290 | EFI_HII_GLYPH_BLOCK Header;\r | |
291 | UINT16 SkipCount;\r | |
292 | } EFI_HII_GIBT_SKIP2_BLOCK;\r | |
959ccb23 | 293 | \r |
294 | //\r | |
e0c047a0 | 295 | // Definitions for Device Path Package\r |
296 | // Section 27.3.4\r | |
959ccb23 | 297 | //\r |
e0c047a0 | 298 | \r |
299 | ///\r | |
300 | /// The device path package is used to carry a device path\r | |
301 | /// associated with the package list.\r | |
302 | ///\r | |
f620c889 | 303 | typedef struct _EFI_HII_DEVICE_PATH_PACKAGE_HDR {\r |
7d582d6b | 304 | EFI_HII_PACKAGE_HEADER Header;\r |
305 | // EFI_DEVICE_PATH_PROTOCOL DevicePath[];\r | |
f620c889 | 306 | } EFI_HII_DEVICE_PATH_PACKAGE_HDR;\r |
959ccb23 | 307 | \r |
7d582d6b | 308 | //\r |
e0c047a0 | 309 | // Definitions for GUID Package\r |
310 | // Section 27.3.5\r | |
7d582d6b | 311 | //\r |
e0c047a0 | 312 | \r |
313 | ///\r | |
314 | /// The GUID package is used to carry data where the format is defined by a GUID.\r | |
315 | ///\r | |
7d582d6b | 316 | typedef struct _EFI_HII_GUID_PACKAGE_HDR {\r |
317 | EFI_HII_PACKAGE_HEADER Header;\r | |
318 | EFI_GUID Guid;\r | |
319 | // Data per GUID definition may follow\r | |
320 | } EFI_HII_GUID_PACKAGE_HDR;\r | |
959ccb23 | 321 | \r |
7d582d6b | 322 | //\r |
e0c047a0 | 323 | // Definitions for String Package\r |
324 | // Section 27.3.6\r | |
7d582d6b | 325 | //\r |
959ccb23 | 326 | \r |
234dfbf8 | 327 | #define UEFI_CONFIG_LANG "x-UEFI"\r |
328 | #define UEFI_CONFIG_LANG_2 "x-i-UEFI"\r | |
7d582d6b | 329 | \r |
e0c047a0 | 330 | ///\r |
331 | /// The fixed header consists of a standard record header and then the string identifiers\r | |
332 | /// contained in this section and the offsets of the string and language information.\r | |
333 | ///\r | |
7d582d6b | 334 | typedef struct _EFI_HII_STRING_PACKAGE_HDR {\r |
335 | EFI_HII_PACKAGE_HEADER Header;\r | |
336 | UINT32 HdrSize;\r | |
337 | UINT32 StringInfoOffset;\r | |
338 | CHAR16 LanguageWindow[16];\r | |
339 | EFI_STRING_ID LanguageName;\r | |
340 | CHAR8 Language[1];\r | |
341 | } EFI_HII_STRING_PACKAGE_HDR;\r | |
959ccb23 | 342 | \r |
343 | typedef struct {\r | |
7d582d6b | 344 | UINT8 BlockType;\r |
345 | } EFI_HII_STRING_BLOCK;\r | |
346 | \r | |
e0c047a0 | 347 | //\r |
348 | // Value of different string information block types\r | |
349 | //\r | |
7d582d6b | 350 | #define EFI_HII_SIBT_END 0x00\r |
351 | #define EFI_HII_SIBT_STRING_SCSU 0x10\r | |
352 | #define EFI_HII_SIBT_STRING_SCSU_FONT 0x11\r | |
353 | #define EFI_HII_SIBT_STRINGS_SCSU 0x12\r | |
354 | #define EFI_HII_SIBT_STRINGS_SCSU_FONT 0x13\r | |
355 | #define EFI_HII_SIBT_STRING_UCS2 0x14\r | |
356 | #define EFI_HII_SIBT_STRING_UCS2_FONT 0x15\r | |
357 | #define EFI_HII_SIBT_STRINGS_UCS2 0x16\r | |
358 | #define EFI_HII_SIBT_STRINGS_UCS2_FONT 0x17\r | |
359 | #define EFI_HII_SIBT_DUPLICATE 0x20\r | |
360 | #define EFI_HII_SIBT_SKIP2 0x21\r | |
361 | #define EFI_HII_SIBT_SKIP1 0x22\r | |
362 | #define EFI_HII_SIBT_EXT1 0x30\r | |
363 | #define EFI_HII_SIBT_EXT2 0x31\r | |
364 | #define EFI_HII_SIBT_EXT4 0x32\r | |
365 | #define EFI_HII_SIBT_FONT 0x40\r | |
366 | \r | |
e0c047a0 | 367 | //\r |
368 | // Definition of different string information block types\r | |
369 | //\r | |
370 | \r | |
7d582d6b | 371 | typedef struct _EFI_HII_SIBT_DUPLICATE_BLOCK {\r |
372 | EFI_HII_STRING_BLOCK Header;\r | |
373 | EFI_STRING_ID StringId;\r | |
374 | } EFI_HII_SIBT_DUPLICATE_BLOCK;\r | |
375 | \r | |
376 | typedef struct _EFI_HII_SIBT_END_BLOCK {\r | |
377 | EFI_HII_STRING_BLOCK Header;\r | |
378 | } EFI_HII_SIBT_END_BLOCK;\r | |
379 | \r | |
380 | typedef struct _EFI_HII_SIBT_EXT1_BLOCK {\r | |
381 | EFI_HII_STRING_BLOCK Header;\r | |
382 | UINT8 BlockType2;\r | |
383 | UINT8 Length;\r | |
384 | } EFI_HII_SIBT_EXT1_BLOCK;\r | |
385 | \r | |
386 | typedef struct _EFI_HII_SIBT_EXT2_BLOCK {\r | |
387 | EFI_HII_STRING_BLOCK Header;\r | |
388 | UINT8 BlockType2;\r | |
389 | UINT16 Length;\r | |
390 | } EFI_HII_SIBT_EXT2_BLOCK;\r | |
391 | \r | |
392 | typedef struct _EFI_HII_SIBT_EXT4_BLOCK {\r | |
393 | EFI_HII_STRING_BLOCK Header;\r | |
394 | UINT8 BlockType2;\r | |
395 | UINT32 Length;\r | |
396 | } EFI_HII_SIBT_EXT4_BLOCK;\r | |
397 | \r | |
398 | typedef struct _EFI_HII_SIBT_FONT_BLOCK {\r | |
399 | EFI_HII_SIBT_EXT2_BLOCK Header;\r | |
400 | UINT8 FontId;\r | |
401 | UINT16 FontSize;\r | |
402 | EFI_HII_FONT_STYLE FontStyle;\r | |
403 | CHAR16 FontName[1];\r | |
404 | } EFI_HII_SIBT_FONT_BLOCK;\r | |
405 | \r | |
406 | typedef struct _EFI_HII_SIBT_SKIP1_BLOCK {\r | |
407 | EFI_HII_STRING_BLOCK Header;\r | |
408 | UINT8 SkipCount;\r | |
409 | } EFI_HII_SIBT_SKIP1_BLOCK;\r | |
410 | \r | |
411 | typedef struct _EFI_HII_SIBT_SKIP2_BLOCK {\r | |
412 | EFI_HII_STRING_BLOCK Header;\r | |
413 | UINT16 SkipCount;\r | |
414 | } EFI_HII_SIBT_SKIP2_BLOCK;\r | |
415 | \r | |
416 | typedef struct _EFI_HII_SIBT_STRING_SCSU_BLOCK {\r | |
417 | EFI_HII_STRING_BLOCK Header;\r | |
418 | UINT8 StringText[1];\r | |
419 | } EFI_HII_SIBT_STRING_SCSU_BLOCK;\r | |
420 | \r | |
421 | typedef struct _EFI_HII_SIBT_STRING_SCSU_FONT_BLOCK {\r | |
422 | EFI_HII_STRING_BLOCK Header;\r | |
423 | UINT8 FontIdentifier;\r | |
424 | UINT8 StringText[1];\r | |
425 | } EFI_HII_SIBT_STRING_SCSU_FONT_BLOCK;\r | |
426 | \r | |
427 | typedef struct _EFI_HII_SIBT_STRINGS_SCSU_BLOCK {\r | |
428 | EFI_HII_STRING_BLOCK Header;\r | |
429 | UINT16 StringCount;\r | |
430 | UINT8 StringText[1];\r | |
431 | } EFI_HII_SIBT_STRINGS_SCSU_BLOCK;\r | |
432 | \r | |
433 | typedef struct _EFI_HII_SIBT_STRINGS_SCSU_FONT_BLOCK {\r | |
434 | EFI_HII_STRING_BLOCK Header;\r | |
435 | UINT8 FontIdentifier;\r | |
436 | UINT16 StringCount;\r | |
437 | UINT8 StringText[1];\r | |
438 | } EFI_HII_SIBT_STRINGS_SCSU_FONT_BLOCK;\r | |
439 | \r | |
440 | typedef struct _EFI_HII_SIBT_STRING_UCS2_BLOCK {\r | |
441 | EFI_HII_STRING_BLOCK Header;\r | |
442 | CHAR16 StringText[1];\r | |
443 | } EFI_HII_SIBT_STRING_UCS2_BLOCK;\r | |
444 | \r | |
445 | typedef struct _EFI_HII_SIBT_STRING_UCS2_FONT_BLOCK {\r | |
446 | EFI_HII_STRING_BLOCK Header;\r | |
447 | UINT8 FontIdentifier;\r | |
448 | CHAR16 StringText[1];\r | |
449 | } EFI_HII_SIBT_STRING_UCS2_FONT_BLOCK;\r | |
450 | \r | |
451 | typedef struct _EFI_HII_SIBT_STRINGS_UCS2_BLOCK {\r | |
452 | EFI_HII_STRING_BLOCK Header;\r | |
453 | UINT16 StringCount;\r | |
454 | CHAR16 StringText[1];\r | |
455 | } EFI_HII_SIBT_STRINGS_UCS2_BLOCK;\r | |
456 | \r | |
457 | typedef struct _EFI_HII_SIBT_STRINGS_UCS2_FONT_BLOCK {\r | |
458 | EFI_HII_STRING_BLOCK Header;\r | |
459 | UINT8 FontIdentifier;\r | |
460 | UINT16 StringCount;\r | |
461 | CHAR16 StringText[1];\r | |
462 | } EFI_HII_SIBT_STRINGS_UCS2_FONT_BLOCK;\r | |
959ccb23 | 463 | \r |
464 | //\r | |
e0c047a0 | 465 | // Definitions for Image Package\r |
466 | // Section 27.3.7\r | |
7d582d6b | 467 | //\r |
468 | \r | |
469 | typedef struct _EFI_HII_IMAGE_PACKAGE_HDR {\r | |
470 | EFI_HII_PACKAGE_HEADER Header;\r | |
471 | UINT32 ImageInfoOffset;\r | |
472 | UINT32 PaletteInfoOffset;\r | |
473 | } EFI_HII_IMAGE_PACKAGE_HDR;\r | |
474 | \r | |
475 | typedef struct _EFI_HII_IMAGE_BLOCK {\r | |
476 | UINT8 BlockType;\r | |
477 | } EFI_HII_IMAGE_BLOCK;\r | |
478 | \r | |
e0c047a0 | 479 | //\r |
480 | // Value of different image information block types\r | |
481 | //\r | |
7d582d6b | 482 | #define EFI_HII_IIBT_END 0x00\r |
483 | #define EFI_HII_IIBT_IMAGE_1BIT 0x10\r | |
484 | #define EFI_HII_IIBT_IMAGE_1BIT_TRANS 0x11\r | |
485 | #define EFI_HII_IIBT_IMAGE_4BIT 0x12\r | |
486 | #define EFI_HII_IIBT_IMAGE_4BIT_TRANS 0x13\r | |
487 | #define EFI_HII_IIBT_IMAGE_8BIT 0x14\r | |
488 | #define EFI_HII_IIBT_IMAGE_8BIT_TRANS 0x15\r | |
489 | #define EFI_HII_IIBT_IMAGE_24BIT 0x16\r | |
490 | #define EFI_HII_IIBT_IMAGE_24BIT_TRANS 0x17\r | |
491 | #define EFI_HII_IIBT_IMAGE_JPEG 0x18\r | |
492 | #define EFI_HII_IIBT_DUPLICATE 0x20\r | |
493 | #define EFI_HII_IIBT_SKIP2 0x21\r | |
494 | #define EFI_HII_IIBT_SKIP1 0x22\r | |
495 | #define EFI_HII_IIBT_EXT1 0x30\r | |
496 | #define EFI_HII_IIBT_EXT2 0x31\r | |
497 | #define EFI_HII_IIBT_EXT4 0x32\r | |
498 | \r | |
e0c047a0 | 499 | //\r |
500 | // Definition of different image information block types\r | |
501 | //\r | |
502 | \r | |
7d582d6b | 503 | typedef struct _EFI_HII_IIBT_END_BLOCK {\r |
504 | EFI_HII_IMAGE_BLOCK Header;\r | |
505 | } EFI_HII_IIBT_END_BLOCK;\r | |
506 | \r | |
507 | typedef struct _EFI_HII_IIBT_EXT1_BLOCK {\r | |
508 | EFI_HII_IMAGE_BLOCK Header;\r | |
509 | UINT8 BlockType2;\r | |
510 | UINT8 Length;\r | |
511 | } EFI_HII_IIBT_EXT1_BLOCK;\r | |
512 | \r | |
513 | typedef struct _EFI_HII_IIBT_EXT2_BLOCK {\r | |
514 | EFI_HII_IMAGE_BLOCK Header;\r | |
515 | UINT8 BlockType2;\r | |
516 | UINT16 Length;\r | |
517 | } EFI_HII_IIBT_EXT2_BLOCK;\r | |
518 | \r | |
519 | typedef struct _EFI_HII_IIBT_EXT4_BLOCK {\r | |
520 | EFI_HII_IMAGE_BLOCK Header;\r | |
521 | UINT8 BlockType2;\r | |
522 | UINT32 Length;\r | |
523 | } EFI_HII_IIBT_EXT4_BLOCK;\r | |
524 | \r | |
525 | typedef struct _EFI_HII_IIBT_IMAGE_1BIT_BASE {\r | |
526 | UINT16 Width;\r | |
527 | UINT16 Height;\r | |
528 | UINT8 Data[1];\r | |
529 | } EFI_HII_IIBT_IMAGE_1BIT_BASE;\r | |
530 | \r | |
531 | typedef struct _EFI_HII_IIBT_IMAGE_1BIT_BLOCK {\r | |
532 | EFI_HII_IMAGE_BLOCK Header;\r | |
533 | UINT8 PaletteIndex;\r | |
534 | EFI_HII_IIBT_IMAGE_1BIT_BASE Bitmap;\r | |
535 | } EFI_HII_IIBT_IMAGE_1BIT_BLOCK;\r | |
536 | \r | |
537 | typedef struct _EFI_HII_IIBT_IMAGE_1BIT_TRANS_BLOCK {\r | |
538 | EFI_HII_IMAGE_BLOCK Header;\r | |
539 | UINT8 PaletteIndex;\r | |
540 | EFI_HII_IIBT_IMAGE_1BIT_BASE Bitmap;\r | |
541 | } EFI_HII_IIBT_IMAGE_1BIT_TRANS_BLOCK;\r | |
542 | \r | |
543 | typedef struct _EFI_HII_RGB_PIXEL {\r | |
544 | UINT8 b;\r | |
545 | UINT8 g;\r | |
546 | UINT8 r;\r | |
547 | } EFI_HII_RGB_PIXEL;\r | |
548 | \r | |
549 | typedef struct _EFI_HII_IIBT_IMAGE_24BIT_BASE {\r | |
550 | UINT16 Width;\r | |
551 | UINT16 Height;\r | |
552 | EFI_HII_RGB_PIXEL Bitmap[1];\r | |
553 | } EFI_HII_IIBT_IMAGE_24BIT_BASE;\r | |
554 | \r | |
555 | typedef struct _EFI_HII_IIBT_IMAGE_24BIT_BLOCK {\r | |
556 | EFI_HII_IMAGE_BLOCK Header;\r | |
557 | EFI_HII_IIBT_IMAGE_24BIT_BASE Bitmap;\r | |
558 | } EFI_HII_IIBT_IMAGE_24BIT_BLOCK;\r | |
559 | \r | |
560 | typedef struct _EFI_HII_IIBT_IMAGE_24BIT_TRANS_BLOCK {\r | |
561 | EFI_HII_IMAGE_BLOCK Header;\r | |
562 | EFI_HII_IIBT_IMAGE_24BIT_BASE Bitmap;\r | |
563 | } EFI_HII_IIBT_IMAGE_24BIT_TRANS_BLOCK;\r | |
564 | \r | |
565 | typedef struct _EFI_HII_IIBT_IMAGE_4BIT_BASE {\r | |
566 | UINT16 Width;\r | |
567 | UINT16 Height;\r | |
568 | UINT8 Data[1];\r | |
569 | } EFI_HII_IIBT_IMAGE_4BIT_BASE;\r | |
570 | \r | |
571 | typedef struct _EFI_HII_IIBT_IMAGE_4BIT_BLOCK {\r | |
572 | EFI_HII_IMAGE_BLOCK Header;\r | |
573 | UINT8 PaletteIndex;\r | |
574 | EFI_HII_IIBT_IMAGE_4BIT_BASE Bitmap;\r | |
575 | } EFI_HII_IIBT_IMAGE_4BIT_BLOCK;\r | |
576 | \r | |
577 | typedef struct _EFI_HII_IIBT_IMAGE_4BIT_TRANS_BLOCK {\r | |
578 | EFI_HII_IMAGE_BLOCK Header;\r | |
579 | UINT8 PaletteIndex;\r | |
580 | EFI_HII_IIBT_IMAGE_4BIT_BASE Bitmap;\r | |
581 | } EFI_HII_IIBT_IMAGE_4BIT_TRANS_BLOCK;\r | |
582 | \r | |
583 | typedef struct _EFI_HII_IIBT_IMAGE_8BIT_BASE {\r | |
584 | UINT16 Width;\r | |
585 | UINT16 Height;\r | |
586 | UINT8 Data[1];\r | |
587 | } EFI_HII_IIBT_IMAGE_8BIT_BASE;\r | |
588 | \r | |
589 | typedef struct _EFI_HII_IIBT_IMAGE_8BIT_PALETTE_BLOCK {\r | |
590 | EFI_HII_IMAGE_BLOCK Header;\r | |
591 | UINT8 PaletteIndex;\r | |
592 | EFI_HII_IIBT_IMAGE_8BIT_BASE Bitmap;\r | |
593 | } EFI_HII_IIBT_IMAGE_8BIT_BLOCK;\r | |
594 | \r | |
595 | typedef struct _EFI_HII_IIBT_IMAGE_8BIT_TRANS_BLOCK {\r | |
596 | EFI_HII_IMAGE_BLOCK Header;\r | |
597 | UINT8 PaletteIndex;\r | |
598 | EFI_HII_IIBT_IMAGE_8BIT_BASE Bitmap;\r | |
599 | } EFI_HII_IIBT_IMAGE_8BIT_TRAN_BLOCK;\r | |
600 | \r | |
601 | typedef struct _EFI_HII_IIBT_DUPLICATE_BLOCK {\r | |
602 | EFI_HII_IMAGE_BLOCK Header;\r | |
603 | EFI_IMAGE_ID ImageId;\r | |
604 | } EFI_HII_IIBT_DUPLICATE_BLOCK;\r | |
605 | \r | |
606 | typedef struct _EFI_HII_IIBT_JPEG_BLOCK {\r | |
607 | EFI_HII_IMAGE_BLOCK Header;\r | |
608 | UINT32 Size;\r | |
609 | UINT8 Data[1];\r | |
610 | } EFI_HII_IIBT_JPEG_BLOCK;\r | |
611 | \r | |
612 | typedef struct _EFI_HII_IIBT_SKIP1_BLOCK {\r | |
613 | EFI_HII_IMAGE_BLOCK Header;\r | |
614 | UINT8 SkipCount;\r | |
615 | } EFI_HII_IIBT_SKIP1_BLOCK;\r | |
616 | \r | |
617 | typedef struct _EFI_HII_IIBT_SKIP2_BLOCK {\r | |
618 | EFI_HII_IMAGE_BLOCK Header;\r | |
619 | UINT16 SkipCount;\r | |
620 | } EFI_HII_IIBT_SKIP2_BLOCK;\r | |
621 | \r | |
e0c047a0 | 622 | //\r |
623 | // Definitions for Palette Information\r | |
624 | //\r | |
625 | \r | |
7d582d6b | 626 | typedef struct _EFI_HII_IMAGE_PALETTE_INFO_HEADER {\r |
627 | UINT16 PaletteCount;\r | |
628 | } EFI_HII_IMAGE_PALETTE_INFO_HEADER;\r | |
629 | \r | |
630 | typedef struct _EFI_HII_IMAGE_PALETTE_INFO {\r | |
631 | UINT16 PaletteSize;\r | |
632 | EFI_HII_RGB_PIXEL PaletteValue[1];\r | |
633 | } EFI_HII_IMAGE_PALETTE_INFO;\r | |
634 | \r | |
959ccb23 | 635 | //\r |
e0c047a0 | 636 | // Definitions for Forms Package\r |
637 | // Section 27.3.8\r | |
7d582d6b | 638 | //\r |
639 | \r | |
e0c047a0 | 640 | ///\r |
f620c889 | 641 | /// The Form package is used to carry form-based encoding data.\r |
e0c047a0 | 642 | ///\r |
f620c889 | 643 | typedef struct _EFI_HII_FORM_PACKAGE_HDR {\r |
7d582d6b | 644 | EFI_HII_PACKAGE_HEADER Header;\r |
645 | // EFI_IFR_OP_HEADER OpCodeHeader;\r | |
646 | // More op-codes follow\r | |
f620c889 | 647 | } EFI_HII_FORM_PACKAGE_HDR;\r |
7d582d6b | 648 | \r |
959ccb23 | 649 | typedef struct {\r |
7d582d6b | 650 | UINT8 Hour;\r |
651 | UINT8 Minute;\r | |
652 | UINT8 Second;\r | |
653 | } EFI_HII_TIME;\r | |
959ccb23 | 654 | \r |
655 | typedef struct {\r | |
7d582d6b | 656 | UINT16 Year;\r |
657 | UINT8 Month;\r | |
658 | UINT8 Day;\r | |
659 | } EFI_HII_DATE;\r | |
660 | \r | |
2ed77d0d ED |
661 | typedef struct {\r |
662 | EFI_QUESTION_ID QuestionId;\r | |
663 | EFI_FORM_ID FormId;\r | |
664 | EFI_GUID FormSetGuid;\r | |
665 | EFI_STRING_ID DevicePath;\r | |
666 | } EFI_HII_REF;\r | |
667 | \r | |
7d582d6b | 668 | typedef union {\r |
669 | UINT8 u8;\r | |
670 | UINT16 u16;\r | |
671 | UINT32 u32;\r | |
672 | UINT64 u64;\r | |
673 | BOOLEAN b;\r | |
674 | EFI_HII_TIME time;\r | |
675 | EFI_HII_DATE date;\r | |
0cd118f7 | 676 | EFI_STRING_ID string; ///< EFI_IFR_TYPE_STRING, EFI_IFR_TYPE_ACTION\r |
2ed77d0d | 677 | EFI_HII_REF ref; ///< EFI_IFR_TYPE_REF\r |
4e7d855f | 678 | // UINT8 buffer[]; ///< EFI_IFR_TYPE_BUFFER\r |
7d582d6b | 679 | } EFI_IFR_TYPE_VALUE;\r |
680 | \r | |
d7132512 LG |
681 | //\r |
682 | // IFR Opcodes\r | |
683 | //\r | |
7d582d6b | 684 | #define EFI_IFR_FORM_OP 0x01\r |
685 | #define EFI_IFR_SUBTITLE_OP 0x02\r | |
686 | #define EFI_IFR_TEXT_OP 0x03\r | |
687 | #define EFI_IFR_IMAGE_OP 0x04\r | |
688 | #define EFI_IFR_ONE_OF_OP 0x05\r | |
689 | #define EFI_IFR_CHECKBOX_OP 0x06\r | |
690 | #define EFI_IFR_NUMERIC_OP 0x07\r | |
691 | #define EFI_IFR_PASSWORD_OP 0x08\r | |
692 | #define EFI_IFR_ONE_OF_OPTION_OP 0x09\r | |
693 | #define EFI_IFR_SUPPRESS_IF_OP 0x0A\r | |
694 | #define EFI_IFR_LOCKED_OP 0x0B\r | |
695 | #define EFI_IFR_ACTION_OP 0x0C\r | |
696 | #define EFI_IFR_RESET_BUTTON_OP 0x0D\r | |
697 | #define EFI_IFR_FORM_SET_OP 0x0E\r | |
698 | #define EFI_IFR_REF_OP 0x0F\r | |
699 | #define EFI_IFR_NO_SUBMIT_IF_OP 0x10\r | |
700 | #define EFI_IFR_INCONSISTENT_IF_OP 0x11\r | |
701 | #define EFI_IFR_EQ_ID_VAL_OP 0x12\r | |
702 | #define EFI_IFR_EQ_ID_ID_OP 0x13\r | |
e8ef4283 | 703 | #define EFI_IFR_EQ_ID_VAL_LIST_OP 0x14\r |
7d582d6b | 704 | #define EFI_IFR_AND_OP 0x15\r |
705 | #define EFI_IFR_OR_OP 0x16\r | |
706 | #define EFI_IFR_NOT_OP 0x17\r | |
707 | #define EFI_IFR_RULE_OP 0x18\r | |
708 | #define EFI_IFR_GRAY_OUT_IF_OP 0x19\r | |
709 | #define EFI_IFR_DATE_OP 0x1A\r | |
710 | #define EFI_IFR_TIME_OP 0x1B\r | |
711 | #define EFI_IFR_STRING_OP 0x1C\r | |
712 | #define EFI_IFR_REFRESH_OP 0x1D\r | |
713 | #define EFI_IFR_DISABLE_IF_OP 0x1E\r | |
f6051525 | 714 | #define EFI_IFR_ANIMATION_OP 0x1F\r |
7d582d6b | 715 | #define EFI_IFR_TO_LOWER_OP 0x20\r |
716 | #define EFI_IFR_TO_UPPER_OP 0x21\r | |
0cd118f7 | 717 | #define EFI_IFR_MAP_OP 0x22\r |
7d582d6b | 718 | #define EFI_IFR_ORDERED_LIST_OP 0x23\r |
719 | #define EFI_IFR_VARSTORE_OP 0x24\r | |
720 | #define EFI_IFR_VARSTORE_NAME_VALUE_OP 0x25\r | |
721 | #define EFI_IFR_VARSTORE_EFI_OP 0x26\r | |
722 | #define EFI_IFR_VARSTORE_DEVICE_OP 0x27\r | |
723 | #define EFI_IFR_VERSION_OP 0x28\r | |
724 | #define EFI_IFR_END_OP 0x29\r | |
725 | #define EFI_IFR_MATCH_OP 0x2A\r | |
0cd118f7 | 726 | #define EFI_IFR_GET_OP 0x2B\r |
2573712e | 727 | #define EFI_IFR_SET_OP 0x2C\r |
0cd118f7 LG |
728 | #define EFI_IFR_READ_OP 0x2D\r |
729 | #define EFI_IFR_WRITE_OP 0x2E\r | |
7d582d6b | 730 | #define EFI_IFR_EQUAL_OP 0x2F\r |
731 | #define EFI_IFR_NOT_EQUAL_OP 0x30\r | |
732 | #define EFI_IFR_GREATER_THAN_OP 0x31\r | |
733 | #define EFI_IFR_GREATER_EQUAL_OP 0x32\r | |
734 | #define EFI_IFR_LESS_THAN_OP 0x33\r | |
735 | #define EFI_IFR_LESS_EQUAL_OP 0x34\r | |
736 | #define EFI_IFR_BITWISE_AND_OP 0x35\r | |
737 | #define EFI_IFR_BITWISE_OR_OP 0x36\r | |
738 | #define EFI_IFR_BITWISE_NOT_OP 0x37\r | |
739 | #define EFI_IFR_SHIFT_LEFT_OP 0x38\r | |
740 | #define EFI_IFR_SHIFT_RIGHT_OP 0x39\r | |
741 | #define EFI_IFR_ADD_OP 0x3A\r | |
742 | #define EFI_IFR_SUBTRACT_OP 0x3B\r | |
743 | #define EFI_IFR_MULTIPLY_OP 0x3C\r | |
744 | #define EFI_IFR_DIVIDE_OP 0x3D\r | |
745 | #define EFI_IFR_MODULO_OP 0x3E\r | |
746 | #define EFI_IFR_RULE_REF_OP 0x3F\r | |
747 | #define EFI_IFR_QUESTION_REF1_OP 0x40\r | |
748 | #define EFI_IFR_QUESTION_REF2_OP 0x41\r | |
749 | #define EFI_IFR_UINT8_OP 0x42\r | |
750 | #define EFI_IFR_UINT16_OP 0x43\r | |
751 | #define EFI_IFR_UINT32_OP 0x44\r | |
752 | #define EFI_IFR_UINT64_OP 0x45\r | |
753 | #define EFI_IFR_TRUE_OP 0x46\r | |
754 | #define EFI_IFR_FALSE_OP 0x47\r | |
755 | #define EFI_IFR_TO_UINT_OP 0x48\r | |
756 | #define EFI_IFR_TO_STRING_OP 0x49\r | |
757 | #define EFI_IFR_TO_BOOLEAN_OP 0x4A\r | |
758 | #define EFI_IFR_MID_OP 0x4B\r | |
759 | #define EFI_IFR_FIND_OP 0x4C\r | |
760 | #define EFI_IFR_TOKEN_OP 0x4D\r | |
761 | #define EFI_IFR_STRING_REF1_OP 0x4E\r | |
762 | #define EFI_IFR_STRING_REF2_OP 0x4F\r | |
763 | #define EFI_IFR_CONDITIONAL_OP 0x50\r | |
764 | #define EFI_IFR_QUESTION_REF3_OP 0x51\r | |
765 | #define EFI_IFR_ZERO_OP 0x52\r | |
766 | #define EFI_IFR_ONE_OP 0x53\r | |
767 | #define EFI_IFR_ONES_OP 0x54\r | |
768 | #define EFI_IFR_UNDEFINED_OP 0x55\r | |
769 | #define EFI_IFR_LENGTH_OP 0x56\r | |
770 | #define EFI_IFR_DUP_OP 0x57\r | |
771 | #define EFI_IFR_THIS_OP 0x58\r | |
772 | #define EFI_IFR_SPAN_OP 0x59\r | |
773 | #define EFI_IFR_VALUE_OP 0x5A\r | |
774 | #define EFI_IFR_DEFAULT_OP 0x5B\r | |
775 | #define EFI_IFR_DEFAULTSTORE_OP 0x5C\r | |
0cd118f7 | 776 | #define EFI_IFR_FORM_MAP_OP 0x5D\r |
7d582d6b | 777 | #define EFI_IFR_CATENATE_OP 0x5E\r |
778 | #define EFI_IFR_GUID_OP 0x5F\r | |
0cd118f7 | 779 | #define EFI_IFR_SECURITY_OP 0x60\r |
26a65e5c | 780 | #define EFI_IFR_MODAL_TAG_OP 0x61\r |
dfc66bb9 | 781 | #define EFI_IFR_REFRESH_ID_OP 0x62\r |
774b5736 | 782 | #define EFI_IFR_WARNING_IF_OP 0x63\r |
7d582d6b | 783 | \r |
e0c047a0 | 784 | //\r |
785 | // Definitions of IFR Standard Headers\r | |
786 | // Section 27.3.8.2\r | |
787 | //\r | |
7d582d6b | 788 | \r |
789 | typedef struct _EFI_IFR_OP_HEADER {\r | |
790 | UINT8 OpCode;\r | |
791 | UINT8 Length:7;\r | |
792 | UINT8 Scope:1;\r | |
793 | } EFI_IFR_OP_HEADER;\r | |
794 | \r | |
795 | typedef struct _EFI_IFR_STATEMENT_HEADER {\r | |
796 | EFI_STRING_ID Prompt;\r | |
797 | EFI_STRING_ID Help;\r | |
798 | } EFI_IFR_STATEMENT_HEADER;\r | |
799 | \r | |
800 | typedef struct _EFI_IFR_QUESTION_HEADER {\r | |
801 | EFI_IFR_STATEMENT_HEADER Header;\r | |
802 | EFI_QUESTION_ID QuestionId;\r | |
803 | EFI_VARSTORE_ID VarStoreId;\r | |
804 | union {\r | |
805 | EFI_STRING_ID VarName;\r | |
806 | UINT16 VarOffset;\r | |
807 | } VarStoreInfo;\r | |
808 | UINT8 Flags;\r | |
809 | } EFI_IFR_QUESTION_HEADER;\r | |
810 | \r | |
e0c047a0 | 811 | //\r |
812 | // Flag values of EFI_IFR_QUESTION_HEADER\r | |
813 | //\r | |
7d582d6b | 814 | #define EFI_IFR_FLAG_READ_ONLY 0x01\r |
815 | #define EFI_IFR_FLAG_CALLBACK 0x04\r | |
816 | #define EFI_IFR_FLAG_RESET_REQUIRED 0x10\r | |
817 | #define EFI_IFR_FLAG_OPTIONS_ONLY 0x80\r | |
818 | \r | |
e0c047a0 | 819 | //\r |
820 | // Definition for Opcode Reference\r | |
821 | // Section 27.3.8.3\r | |
822 | //\r | |
7d582d6b | 823 | typedef struct _EFI_IFR_DEFAULTSTORE {\r |
824 | EFI_IFR_OP_HEADER Header;\r | |
825 | EFI_STRING_ID DefaultName;\r | |
826 | UINT16 DefaultId;\r | |
827 | } EFI_IFR_DEFAULTSTORE;\r | |
828 | \r | |
e0c047a0 | 829 | //\r |
830 | // Default Identifier of default store \r | |
831 | //\r | |
7d582d6b | 832 | #define EFI_HII_DEFAULT_CLASS_STANDARD 0x0000\r |
833 | #define EFI_HII_DEFAULT_CLASS_MANUFACTURING 0x0001\r | |
834 | #define EFI_HII_DEFAULT_CLASS_SAFE 0x0002\r | |
835 | #define EFI_HII_DEFAULT_CLASS_PLATFORM_BEGIN 0x4000\r | |
836 | #define EFI_HII_DEFAULT_CLASS_PLATFORM_END 0x7fff\r | |
837 | #define EFI_HII_DEFAULT_CLASS_HARDWARE_BEGIN 0x8000\r | |
838 | #define EFI_HII_DEFAULT_CLASS_HARDWARE_END 0xbfff\r | |
839 | #define EFI_HII_DEFAULT_CLASS_FIRMWARE_BEGIN 0xc000\r | |
840 | #define EFI_HII_DEFAULT_CLASS_FIRMWARE_END 0xffff\r | |
841 | \r | |
842 | typedef struct _EFI_IFR_VARSTORE {\r | |
843 | EFI_IFR_OP_HEADER Header;\r | |
844 | EFI_GUID Guid;\r | |
845 | EFI_VARSTORE_ID VarStoreId;\r | |
846 | UINT16 Size;\r | |
847 | UINT8 Name[1];\r | |
848 | } EFI_IFR_VARSTORE;\r | |
849 | \r | |
850 | typedef struct _EFI_IFR_VARSTORE_EFI {\r | |
851 | EFI_IFR_OP_HEADER Header;\r | |
54cf8780 | 852 | EFI_VARSTORE_ID VarStoreId;\r |
7d582d6b | 853 | EFI_GUID Guid;\r |
854 | UINT32 Attributes;\r | |
d23610eb ED |
855 | UINT16 Size;\r |
856 | UINT8 Name[1];\r | |
7d582d6b | 857 | } EFI_IFR_VARSTORE_EFI;\r |
858 | \r | |
859 | typedef struct _EFI_IFR_VARSTORE_NAME_VALUE {\r | |
860 | EFI_IFR_OP_HEADER Header;\r | |
54cf8780 | 861 | EFI_VARSTORE_ID VarStoreId;\r |
7d582d6b | 862 | EFI_GUID Guid;\r |
863 | } EFI_IFR_VARSTORE_NAME_VALUE;\r | |
864 | \r | |
865 | typedef struct _EFI_IFR_FORM_SET {\r | |
866 | EFI_IFR_OP_HEADER Header;\r | |
867 | EFI_GUID Guid;\r | |
868 | EFI_STRING_ID FormSetTitle;\r | |
869 | EFI_STRING_ID Help;\r | |
c2ace45e LG |
870 | UINT8 Flags;\r |
871 | // EFI_GUID ClassGuid[];\r | |
7d582d6b | 872 | } EFI_IFR_FORM_SET;\r |
873 | \r | |
874 | typedef struct _EFI_IFR_END {\r | |
875 | EFI_IFR_OP_HEADER Header;\r | |
876 | } EFI_IFR_END;\r | |
877 | \r | |
878 | typedef struct _EFI_IFR_FORM {\r | |
879 | EFI_IFR_OP_HEADER Header;\r | |
880 | UINT16 FormId;\r | |
881 | EFI_STRING_ID FormTitle;\r | |
882 | } EFI_IFR_FORM;\r | |
883 | \r | |
884 | typedef struct _EFI_IFR_IMAGE {\r | |
885 | EFI_IFR_OP_HEADER Header;\r | |
886 | EFI_IMAGE_ID Id;\r | |
887 | } EFI_IFR_IMAGE;\r | |
888 | \r | |
cadf8790 | 889 | typedef struct _EFI_IFR_MODAL_TAG {\r |
26a65e5c | 890 | EFI_IFR_OP_HEADER Header;\r |
cadf8790 | 891 | } EFI_IFR_MODAL_TAG;\r |
26a65e5c | 892 | \r |
7d582d6b | 893 | typedef struct _EFI_IFR_LOCKED {\r |
894 | EFI_IFR_OP_HEADER Header;\r | |
895 | } EFI_IFR_LOCKED;\r | |
896 | \r | |
897 | typedef struct _EFI_IFR_RULE {\r | |
898 | EFI_IFR_OP_HEADER Header;\r | |
899 | UINT8 RuleId;\r | |
900 | } EFI_IFR_RULE;\r | |
901 | \r | |
902 | typedef struct _EFI_IFR_DEFAULT {\r | |
903 | EFI_IFR_OP_HEADER Header;\r | |
904 | UINT16 DefaultId;\r | |
905 | UINT8 Type;\r | |
906 | EFI_IFR_TYPE_VALUE Value;\r | |
907 | } EFI_IFR_DEFAULT;\r | |
908 | \r | |
4706ff4f ED |
909 | typedef struct _EFI_IFR_DEFAULT_2 {\r |
910 | EFI_IFR_OP_HEADER Header;\r | |
911 | UINT16 DefaultId;\r | |
912 | UINT8 Type;\r | |
913 | } EFI_IFR_DEFAULT_2;\r | |
914 | \r | |
7d582d6b | 915 | typedef struct _EFI_IFR_VALUE {\r |
916 | EFI_IFR_OP_HEADER Header;\r | |
917 | } EFI_IFR_VALUE;\r | |
918 | \r | |
919 | typedef struct _EFI_IFR_SUBTITLE {\r | |
920 | EFI_IFR_OP_HEADER Header;\r | |
921 | EFI_IFR_STATEMENT_HEADER Statement;\r | |
922 | UINT8 Flags;\r | |
923 | } EFI_IFR_SUBTITLE;\r | |
924 | \r | |
925 | #define EFI_IFR_FLAGS_HORIZONTAL 0x01\r | |
926 | \r | |
927 | typedef struct _EFI_IFR_CHECKBOX {\r | |
928 | EFI_IFR_OP_HEADER Header;\r | |
929 | EFI_IFR_QUESTION_HEADER Question;\r | |
930 | UINT8 Flags;\r | |
931 | } EFI_IFR_CHECKBOX;\r | |
932 | \r | |
933 | #define EFI_IFR_CHECKBOX_DEFAULT 0x01\r | |
934 | #define EFI_IFR_CHECKBOX_DEFAULT_MFG 0x02\r | |
935 | \r | |
936 | typedef struct _EFI_IFR_TEXT {\r | |
937 | EFI_IFR_OP_HEADER Header;\r | |
938 | EFI_IFR_STATEMENT_HEADER Statement;\r | |
939 | EFI_STRING_ID TextTwo;\r | |
940 | } EFI_IFR_TEXT;\r | |
941 | \r | |
942 | typedef struct _EFI_IFR_REF {\r | |
943 | EFI_IFR_OP_HEADER Header;\r | |
944 | EFI_IFR_QUESTION_HEADER Question;\r | |
945 | EFI_FORM_ID FormId;\r | |
946 | } EFI_IFR_REF;\r | |
947 | \r | |
948 | typedef struct _EFI_IFR_REF2 {\r | |
949 | EFI_IFR_OP_HEADER Header;\r | |
950 | EFI_IFR_QUESTION_HEADER Question;\r | |
951 | EFI_FORM_ID FormId;\r | |
952 | EFI_QUESTION_ID QuestionId;\r | |
953 | } EFI_IFR_REF2;\r | |
954 | \r | |
955 | typedef struct _EFI_IFR_REF3 {\r | |
956 | EFI_IFR_OP_HEADER Header;\r | |
957 | EFI_IFR_QUESTION_HEADER Question;\r | |
958 | EFI_FORM_ID FormId;\r | |
959 | EFI_QUESTION_ID QuestionId;\r | |
960 | EFI_GUID FormSetId;\r | |
961 | } EFI_IFR_REF3;\r | |
962 | \r | |
963 | typedef struct _EFI_IFR_REF4 {\r | |
964 | EFI_IFR_OP_HEADER Header;\r | |
965 | EFI_IFR_QUESTION_HEADER Question;\r | |
966 | EFI_FORM_ID FormId;\r | |
967 | EFI_QUESTION_ID QuestionId;\r | |
968 | EFI_GUID FormSetId;\r | |
969 | EFI_STRING_ID DevicePath;\r | |
970 | } EFI_IFR_REF4;\r | |
971 | \r | |
2ed77d0d ED |
972 | typedef struct _EFI_IFR_REF5 {\r |
973 | EFI_IFR_OP_HEADER Header;\r | |
974 | EFI_IFR_QUESTION_HEADER Question;\r | |
975 | } EFI_IFR_REF5;\r | |
976 | \r | |
7d582d6b | 977 | typedef struct _EFI_IFR_RESET_BUTTON {\r |
978 | EFI_IFR_OP_HEADER Header;\r | |
16cb6eca | 979 | EFI_IFR_STATEMENT_HEADER Statement;\r |
7d582d6b | 980 | EFI_DEFAULT_ID DefaultId;\r |
981 | } EFI_IFR_RESET_BUTTON;\r | |
982 | \r | |
983 | typedef struct _EFI_IFR_ACTION {\r | |
984 | EFI_IFR_OP_HEADER Header;\r | |
985 | EFI_IFR_QUESTION_HEADER Question;\r | |
986 | EFI_STRING_ID QuestionConfig;\r | |
987 | } EFI_IFR_ACTION;\r | |
988 | \r | |
989 | typedef struct _EFI_IFR_ACTION_1 {\r | |
990 | EFI_IFR_OP_HEADER Header;\r | |
991 | EFI_IFR_QUESTION_HEADER Question;\r | |
992 | } EFI_IFR_ACTION_1;\r | |
993 | \r | |
994 | typedef struct _EFI_IFR_DATE {\r | |
995 | EFI_IFR_OP_HEADER Header;\r | |
996 | EFI_IFR_QUESTION_HEADER Question;\r | |
997 | UINT8 Flags;\r | |
959ccb23 | 998 | } EFI_IFR_DATE;\r |
999 | \r | |
e0c047a0 | 1000 | //\r |
1001 | // Flags that describe the behavior of the question.\r | |
1002 | //\r | |
7d582d6b | 1003 | #define EFI_QF_DATE_YEAR_SUPPRESS 0x01\r |
1004 | #define EFI_QF_DATE_MONTH_SUPPRESS 0x02\r | |
1005 | #define EFI_QF_DATE_DAY_SUPPRESS 0x04\r | |
959ccb23 | 1006 | \r |
7d582d6b | 1007 | #define EFI_QF_DATE_STORAGE 0x30\r |
1008 | #define QF_DATE_STORAGE_NORMAL 0x00\r | |
1009 | #define QF_DATE_STORAGE_TIME 0x10\r | |
1010 | #define QF_DATE_STORAGE_WAKEUP 0x20\r | |
1011 | \r | |
1012 | typedef union {\r | |
1013 | struct {\r | |
1014 | UINT8 MinValue;\r | |
1015 | UINT8 MaxValue;\r | |
1016 | UINT8 Step;\r | |
1017 | } u8;\r | |
1018 | struct {\r | |
1019 | UINT16 MinValue;\r | |
1020 | UINT16 MaxValue;\r | |
1021 | UINT16 Step;\r | |
1022 | } u16;\r | |
1023 | struct {\r | |
1024 | UINT32 MinValue;\r | |
1025 | UINT32 MaxValue;\r | |
1026 | UINT32 Step;\r | |
1027 | } u32;\r | |
1028 | struct {\r | |
1029 | UINT64 MinValue;\r | |
1030 | UINT64 MaxValue;\r | |
1031 | UINT64 Step;\r | |
1032 | } u64;\r | |
1033 | } MINMAXSTEP_DATA;\r | |
1034 | \r | |
1035 | typedef struct _EFI_IFR_NUMERIC {\r | |
1036 | EFI_IFR_OP_HEADER Header;\r | |
1037 | EFI_IFR_QUESTION_HEADER Question;\r | |
1038 | UINT8 Flags;\r | |
1039 | MINMAXSTEP_DATA data;\r | |
1040 | } EFI_IFR_NUMERIC;\r | |
1041 | \r | |
e0c047a0 | 1042 | //\r |
1043 | // Flags related to the numeric question\r | |
1044 | //\r | |
7d582d6b | 1045 | #define EFI_IFR_NUMERIC_SIZE 0x03\r |
e0c047a0 | 1046 | #define EFI_IFR_NUMERIC_SIZE_1 0x00\r |
1047 | #define EFI_IFR_NUMERIC_SIZE_2 0x01\r | |
1048 | #define EFI_IFR_NUMERIC_SIZE_4 0x02\r | |
1049 | #define EFI_IFR_NUMERIC_SIZE_8 0x03\r | |
7d582d6b | 1050 | \r |
1051 | #define EFI_IFR_DISPLAY 0x30\r | |
e0c047a0 | 1052 | #define EFI_IFR_DISPLAY_INT_DEC 0x00\r |
1053 | #define EFI_IFR_DISPLAY_UINT_DEC 0x10\r | |
1054 | #define EFI_IFR_DISPLAY_UINT_HEX 0x20\r | |
7d582d6b | 1055 | \r |
1056 | typedef struct _EFI_IFR_ONE_OF {\r | |
1057 | EFI_IFR_OP_HEADER Header;\r | |
1058 | EFI_IFR_QUESTION_HEADER Question;\r | |
1059 | UINT8 Flags;\r | |
1060 | MINMAXSTEP_DATA data;\r | |
1061 | } EFI_IFR_ONE_OF;\r | |
1062 | \r | |
1063 | typedef struct _EFI_IFR_STRING {\r | |
1064 | EFI_IFR_OP_HEADER Header;\r | |
1065 | EFI_IFR_QUESTION_HEADER Question;\r | |
1066 | UINT8 MinSize;\r | |
1067 | UINT8 MaxSize;\r | |
1068 | UINT8 Flags;\r | |
959ccb23 | 1069 | } EFI_IFR_STRING;\r |
1070 | \r | |
7d582d6b | 1071 | #define EFI_IFR_STRING_MULTI_LINE 0x01\r |
959ccb23 | 1072 | \r |
7d582d6b | 1073 | typedef struct _EFI_IFR_PASSWORD {\r |
1074 | EFI_IFR_OP_HEADER Header;\r | |
1075 | EFI_IFR_QUESTION_HEADER Question;\r | |
1076 | UINT16 MinSize;\r | |
1077 | UINT16 MaxSize;\r | |
1078 | } EFI_IFR_PASSWORD;\r | |
959ccb23 | 1079 | \r |
7d582d6b | 1080 | typedef struct _EFI_IFR_ORDERED_LIST {\r |
1081 | EFI_IFR_OP_HEADER Header;\r | |
1082 | EFI_IFR_QUESTION_HEADER Question;\r | |
1083 | UINT8 MaxContainers;\r | |
1084 | UINT8 Flags;\r | |
1085 | } EFI_IFR_ORDERED_LIST;\r | |
959ccb23 | 1086 | \r |
7d582d6b | 1087 | #define EFI_IFR_UNIQUE_SET 0x01\r |
1088 | #define EFI_IFR_NO_EMPTY_SET 0x02\r | |
959ccb23 | 1089 | \r |
7d582d6b | 1090 | typedef struct _EFI_IFR_TIME {\r |
1091 | EFI_IFR_OP_HEADER Header;\r | |
1092 | EFI_IFR_QUESTION_HEADER Question;\r | |
1093 | UINT8 Flags;\r | |
1094 | } EFI_IFR_TIME;\r | |
959ccb23 | 1095 | \r |
e0c047a0 | 1096 | //\r |
1097 | // A bit-mask that determines which unique settings are active for this opcode.\r | |
1098 | //\r | |
7d582d6b | 1099 | #define QF_TIME_HOUR_SUPPRESS 0x01\r |
1100 | #define QF_TIME_MINUTE_SUPPRESS 0x02\r | |
1101 | #define QF_TIME_SECOND_SUPPRESS 0x04\r | |
1102 | \r | |
1103 | #define QF_TIME_STORAGE 0x30\r | |
e0c047a0 | 1104 | #define QF_TIME_STORAGE_NORMAL 0x00\r |
1105 | #define QF_TIME_STORAGE_TIME 0x10\r | |
1106 | #define QF_TIME_STORAGE_WAKEUP 0x20\r | |
7d582d6b | 1107 | \r |
1108 | typedef struct _EFI_IFR_DISABLE_IF {\r | |
1109 | EFI_IFR_OP_HEADER Header;\r | |
1110 | } EFI_IFR_DISABLE_IF;\r | |
1111 | \r | |
1112 | typedef struct _EFI_IFR_SUPPRESS_IF {\r | |
1113 | EFI_IFR_OP_HEADER Header;\r | |
1114 | } EFI_IFR_SUPPRESS_IF;\r | |
1115 | \r | |
1116 | typedef struct _EFI_IFR_GRAY_OUT_IF {\r | |
1117 | EFI_IFR_OP_HEADER Header;\r | |
1118 | } EFI_IFR_GRAY_OUT_IF;\r | |
1119 | \r | |
1120 | typedef struct _EFI_IFR_INCONSISTENT_IF {\r | |
1121 | EFI_IFR_OP_HEADER Header;\r | |
1122 | EFI_STRING_ID Error;\r | |
1123 | } EFI_IFR_INCONSISTENT_IF;\r | |
1124 | \r | |
1125 | typedef struct _EFI_IFR_NO_SUBMIT_IF {\r | |
1126 | EFI_IFR_OP_HEADER Header;\r | |
1127 | EFI_STRING_ID Error;\r | |
1128 | } EFI_IFR_NO_SUBMIT_IF;\r | |
1129 | \r | |
774b5736 ED |
1130 | typedef struct _EFI_IFR_WARNING_IF {\r |
1131 | EFI_IFR_OP_HEADER Header;\r | |
1132 | EFI_STRING_ID Warning;\r | |
1133 | UINT8 TimeOut;\r | |
1134 | } EFI_IFR_WARNING_IF;\r | |
1135 | \r | |
7d582d6b | 1136 | typedef struct _EFI_IFR_REFRESH {\r |
1137 | EFI_IFR_OP_HEADER Header;\r | |
1138 | UINT8 RefreshInterval;\r | |
1139 | } EFI_IFR_REFRESH;\r | |
1140 | \r | |
1141 | typedef struct _EFI_IFR_VARSTORE_DEVICE {\r | |
1142 | EFI_IFR_OP_HEADER Header;\r | |
1143 | EFI_STRING_ID DevicePath;\r | |
1144 | } EFI_IFR_VARSTORE_DEVICE;\r | |
1145 | \r | |
1146 | typedef struct _EFI_IFR_ONE_OF_OPTION {\r | |
1147 | EFI_IFR_OP_HEADER Header;\r | |
1148 | EFI_STRING_ID Option;\r | |
1149 | UINT8 Flags;\r | |
1150 | UINT8 Type;\r | |
1151 | EFI_IFR_TYPE_VALUE Value;\r | |
1152 | } EFI_IFR_ONE_OF_OPTION;\r | |
1153 | \r | |
e0c047a0 | 1154 | //\r |
1155 | // Types of the option's value.\r | |
1156 | //\r | |
7d582d6b | 1157 | #define EFI_IFR_TYPE_NUM_SIZE_8 0x00\r |
1158 | #define EFI_IFR_TYPE_NUM_SIZE_16 0x01\r | |
1159 | #define EFI_IFR_TYPE_NUM_SIZE_32 0x02\r | |
1160 | #define EFI_IFR_TYPE_NUM_SIZE_64 0x03\r | |
1161 | #define EFI_IFR_TYPE_BOOLEAN 0x04\r | |
1162 | #define EFI_IFR_TYPE_TIME 0x05\r | |
1163 | #define EFI_IFR_TYPE_DATE 0x06\r | |
1164 | #define EFI_IFR_TYPE_STRING 0x07\r | |
1165 | #define EFI_IFR_TYPE_OTHER 0x08\r | |
0cd118f7 LG |
1166 | #define EFI_IFR_TYPE_UNDEFINED 0x09\r |
1167 | #define EFI_IFR_TYPE_ACTION 0x0A\r | |
1168 | #define EFI_IFR_TYPE_BUFFER 0x0B\r | |
2ed77d0d | 1169 | #define EFI_IFR_TYPE_REF 0x0C\r |
7d582d6b | 1170 | \r |
1171 | #define EFI_IFR_OPTION_DEFAULT 0x10\r | |
1172 | #define EFI_IFR_OPTION_DEFAULT_MFG 0x20\r | |
1173 | \r | |
1174 | typedef struct _EFI_IFR_GUID {\r | |
1175 | EFI_IFR_OP_HEADER Header;\r | |
1176 | EFI_GUID Guid;\r | |
1177 | //Optional Data Follows\r | |
1178 | } EFI_IFR_GUID;\r | |
1179 | \r | |
dfc66bb9 ED |
1180 | typedef struct _EFI_IFR_REFRESH_ID {\r |
1181 | EFI_IFR_OP_HEADER Header;\r | |
1182 | EFI_GUID RefreshEventGroupId;\r | |
1183 | } EFI_IFR_REFRESH_ID;\r | |
1184 | \r | |
7d582d6b | 1185 | typedef struct _EFI_IFR_DUP {\r |
1186 | EFI_IFR_OP_HEADER Header;\r | |
1187 | } EFI_IFR_DUP;\r | |
1188 | \r | |
1189 | typedef struct _EFI_IFR_EQ_ID_ID {\r | |
1190 | EFI_IFR_OP_HEADER Header;\r | |
1191 | EFI_QUESTION_ID QuestionId1;\r | |
1192 | EFI_QUESTION_ID QuestionId2;\r | |
1193 | } EFI_IFR_EQ_ID_ID;\r | |
1194 | \r | |
1195 | typedef struct _EFI_IFR_EQ_ID_VAL {\r | |
1196 | EFI_IFR_OP_HEADER Header;\r | |
1197 | EFI_QUESTION_ID QuestionId;\r | |
1198 | UINT16 Value;\r | |
959ccb23 | 1199 | } EFI_IFR_EQ_ID_VAL;\r |
1200 | \r | |
66d550f9 | 1201 | typedef struct _EFI_IFR_EQ_ID_VAL_LIST {\r |
7d582d6b | 1202 | EFI_IFR_OP_HEADER Header;\r |
1203 | EFI_QUESTION_ID QuestionId;\r | |
1204 | UINT16 ListLength;\r | |
1205 | UINT16 ValueList[1];\r | |
66d550f9 | 1206 | } EFI_IFR_EQ_ID_VAL_LIST;\r |
959ccb23 | 1207 | \r |
7d582d6b | 1208 | typedef struct _EFI_IFR_UINT8 {\r |
1209 | EFI_IFR_OP_HEADER Header;\r | |
1210 | UINT8 Value;\r | |
1211 | } EFI_IFR_UINT8;\r | |
959ccb23 | 1212 | \r |
7d582d6b | 1213 | typedef struct _EFI_IFR_UINT16 {\r |
1214 | EFI_IFR_OP_HEADER Header;\r | |
1215 | UINT16 Value;\r | |
1216 | } EFI_IFR_UINT16;\r | |
1217 | \r | |
7d582d6b | 1218 | typedef struct _EFI_IFR_UINT32 {\r |
1219 | EFI_IFR_OP_HEADER Header;\r | |
1220 | UINT32 Value;\r | |
1221 | } EFI_IFR_UINT32;\r | |
1222 | \r | |
1223 | typedef struct _EFI_IFR_UINT64 {\r | |
1224 | EFI_IFR_OP_HEADER Header;\r | |
1225 | UINT64 Value;\r | |
1226 | } EFI_IFR_UINT64;\r | |
1227 | \r | |
e0c047a0 | 1228 | typedef struct _EFI_IFR_QUESTION_REF1 {\r |
1229 | EFI_IFR_OP_HEADER Header;\r | |
1230 | EFI_QUESTION_ID QuestionId;\r | |
1231 | } EFI_IFR_QUESTION_REF1;\r | |
1232 | \r | |
1233 | typedef struct _EFI_IFR_QUESTION_REF2 {\r | |
1234 | EFI_IFR_OP_HEADER Header;\r | |
1235 | } EFI_IFR_QUESTION_REF2;\r | |
1236 | \r | |
7d582d6b | 1237 | typedef struct _EFI_IFR_QUESTION_REF3 {\r |
1238 | EFI_IFR_OP_HEADER Header;\r | |
1239 | } EFI_IFR_QUESTION_REF3;\r | |
1240 | \r | |
1241 | typedef struct _EFI_IFR_QUESTION_REF3_2 {\r | |
1242 | EFI_IFR_OP_HEADER Header;\r | |
1243 | EFI_STRING_ID DevicePath;\r | |
1244 | } EFI_IFR_QUESTION_REF3_2;\r | |
1245 | \r | |
1246 | typedef struct _EFI_IFR_QUESTION_REF3_3 {\r | |
1247 | EFI_IFR_OP_HEADER Header;\r | |
1248 | EFI_STRING_ID DevicePath;\r | |
1249 | EFI_GUID Guid;\r | |
1250 | } EFI_IFR_QUESTION_REF3_3;\r | |
1251 | \r | |
1252 | typedef struct _EFI_IFR_RULE_REF {\r | |
1253 | EFI_IFR_OP_HEADER Header;\r | |
1254 | UINT8 RuleId;\r | |
1255 | } EFI_IFR_RULE_REF;\r | |
1256 | \r | |
1257 | typedef struct _EFI_IFR_STRING_REF1 {\r | |
1258 | EFI_IFR_OP_HEADER Header;\r | |
1259 | EFI_STRING_ID StringId;\r | |
1260 | } EFI_IFR_STRING_REF1;\r | |
1261 | \r | |
1262 | typedef struct _EFI_IFR_STRING_REF2 {\r | |
1263 | EFI_IFR_OP_HEADER Header;\r | |
1264 | } EFI_IFR_STRING_REF2;\r | |
1265 | \r | |
1266 | typedef struct _EFI_IFR_THIS {\r | |
1267 | EFI_IFR_OP_HEADER Header;\r | |
1268 | } EFI_IFR_THIS;\r | |
1269 | \r | |
1270 | typedef struct _EFI_IFR_TRUE {\r | |
1271 | EFI_IFR_OP_HEADER Header;\r | |
1272 | } EFI_IFR_TRUE;\r | |
1273 | \r | |
1274 | typedef struct _EFI_IFR_FALSE {\r | |
1275 | EFI_IFR_OP_HEADER Header;\r | |
1276 | } EFI_IFR_FALSE;\r | |
1277 | \r | |
1278 | typedef struct _EFI_IFR_ONE {\r | |
1279 | EFI_IFR_OP_HEADER Header;\r | |
1280 | } EFI_IFR_ONE;\r | |
1281 | \r | |
1282 | typedef struct _EFI_IFR_ONES {\r | |
1283 | EFI_IFR_OP_HEADER Header;\r | |
1284 | } EFI_IFR_ONES;\r | |
1285 | \r | |
1286 | typedef struct _EFI_IFR_ZERO {\r | |
1287 | EFI_IFR_OP_HEADER Header;\r | |
1288 | } EFI_IFR_ZERO;\r | |
1289 | \r | |
1290 | typedef struct _EFI_IFR_UNDEFINED {\r | |
1291 | EFI_IFR_OP_HEADER Header;\r | |
1292 | } EFI_IFR_UNDEFINED;\r | |
1293 | \r | |
1294 | typedef struct _EFI_IFR_VERSION {\r | |
1295 | EFI_IFR_OP_HEADER Header;\r | |
1296 | } EFI_IFR_VERSION;\r | |
1297 | \r | |
1298 | typedef struct _EFI_IFR_LENGTH {\r | |
1299 | EFI_IFR_OP_HEADER Header;\r | |
1300 | } EFI_IFR_LENGTH;\r | |
1301 | \r | |
1302 | typedef struct _EFI_IFR_NOT {\r | |
1303 | EFI_IFR_OP_HEADER Header;\r | |
1304 | } EFI_IFR_NOT;\r | |
1305 | \r | |
1306 | typedef struct _EFI_IFR_BITWISE_NOT {\r | |
1307 | EFI_IFR_OP_HEADER Header;\r | |
1308 | } EFI_IFR_BITWISE_NOT;\r | |
1309 | \r | |
1310 | typedef struct _EFI_IFR_TO_BOOLEAN {\r | |
1311 | EFI_IFR_OP_HEADER Header;\r | |
1312 | } EFI_IFR_TO_BOOLEAN;\r | |
1313 | \r | |
fbf926ad | 1314 | ///\r |
1315 | /// For EFI_IFR_TO_STRING, when converting from\r | |
1316 | /// unsigned integers, these flags control the format:\r | |
af2dc6a7 | 1317 | /// 0 = unsigned decimal.\r |
1318 | /// 1 = signed decimal.\r | |
1319 | /// 2 = hexadecimal (lower-case alpha).\r | |
1320 | /// 3 = hexadecimal (upper-case alpha).\r | |
fbf926ad | 1321 | ///@{\r |
7d582d6b | 1322 | #define EFI_IFR_STRING_UNSIGNED_DEC 0\r |
1323 | #define EFI_IFR_STRING_SIGNED_DEC 1\r | |
1324 | #define EFI_IFR_STRING_LOWERCASE_HEX 2\r | |
1325 | #define EFI_IFR_STRING_UPPERCASE_HEX 3\r | |
fbf926ad | 1326 | ///@}\r |
1327 | \r | |
1328 | ///\r | |
1329 | /// When converting from a buffer, these flags control the format:\r | |
af2dc6a7 | 1330 | /// 0 = ASCII.\r |
1331 | /// 8 = Unicode.\r | |
fbf926ad | 1332 | ///@{\r |
7d582d6b | 1333 | #define EFI_IFR_STRING_ASCII 0\r |
1334 | #define EFI_IFR_STRING_UNICODE 8\r | |
fbf926ad | 1335 | ///@}\r |
7d582d6b | 1336 | \r |
1337 | typedef struct _EFI_IFR_TO_STRING {\r | |
1338 | EFI_IFR_OP_HEADER Header;\r | |
1339 | UINT8 Format;\r | |
1340 | } EFI_IFR_TO_STRING;\r | |
1341 | \r | |
1342 | typedef struct _EFI_IFR_TO_UINT {\r | |
1343 | EFI_IFR_OP_HEADER Header;\r | |
1344 | } EFI_IFR_TO_UINT;\r | |
1345 | \r | |
1346 | typedef struct _EFI_IFR_TO_UPPER {\r | |
1347 | EFI_IFR_OP_HEADER Header;\r | |
1348 | } EFI_IFR_TO_UPPER;\r | |
1349 | \r | |
1350 | typedef struct _EFI_IFR_TO_LOWER {\r | |
1351 | EFI_IFR_OP_HEADER Header;\r | |
1352 | } EFI_IFR_TO_LOWER;\r | |
1353 | \r | |
1354 | typedef struct _EFI_IFR_ADD {\r | |
1355 | EFI_IFR_OP_HEADER Header;\r | |
1356 | } EFI_IFR_ADD;\r | |
1357 | \r | |
1358 | typedef struct _EFI_IFR_AND {\r | |
1359 | EFI_IFR_OP_HEADER Header;\r | |
959ccb23 | 1360 | } EFI_IFR_AND;\r |
1361 | \r | |
7d582d6b | 1362 | typedef struct _EFI_IFR_BITWISE_AND {\r |
1363 | EFI_IFR_OP_HEADER Header;\r | |
1364 | } EFI_IFR_BITWISE_AND;\r | |
1365 | \r | |
1366 | typedef struct _EFI_IFR_BITWISE_OR {\r | |
1367 | EFI_IFR_OP_HEADER Header;\r | |
1368 | } EFI_IFR_BITWISE_OR;\r | |
1369 | \r | |
1370 | typedef struct _EFI_IFR_CATENATE {\r | |
1371 | EFI_IFR_OP_HEADER Header;\r | |
1372 | } EFI_IFR_CATENATE;\r | |
1373 | \r | |
1374 | typedef struct _EFI_IFR_DIVIDE {\r | |
1375 | EFI_IFR_OP_HEADER Header;\r | |
1376 | } EFI_IFR_DIVIDE;\r | |
1377 | \r | |
1378 | typedef struct _EFI_IFR_EQUAL {\r | |
1379 | EFI_IFR_OP_HEADER Header;\r | |
1380 | } EFI_IFR_EQUAL;\r | |
1381 | \r | |
1382 | typedef struct _EFI_IFR_GREATER_EQUAL {\r | |
1383 | EFI_IFR_OP_HEADER Header;\r | |
1384 | } EFI_IFR_GREATER_EQUAL;\r | |
1385 | \r | |
1386 | typedef struct _EFI_IFR_GREATER_THAN {\r | |
1387 | EFI_IFR_OP_HEADER Header;\r | |
1388 | } EFI_IFR_GREATER_THAN;\r | |
1389 | \r | |
1390 | typedef struct _EFI_IFR_LESS_EQUAL {\r | |
1391 | EFI_IFR_OP_HEADER Header;\r | |
1392 | } EFI_IFR_LESS_EQUAL;\r | |
1393 | \r | |
1394 | typedef struct _EFI_IFR_LESS_THAN {\r | |
1395 | EFI_IFR_OP_HEADER Header;\r | |
1396 | } EFI_IFR_LESS_THAN;\r | |
1397 | \r | |
1398 | typedef struct _EFI_IFR_MATCH {\r | |
1399 | EFI_IFR_OP_HEADER Header;\r | |
1400 | } EFI_IFR_MATCH;\r | |
1401 | \r | |
1402 | typedef struct _EFI_IFR_MULTIPLY {\r | |
1403 | EFI_IFR_OP_HEADER Header;\r | |
1404 | } EFI_IFR_MULTIPLY;\r | |
1405 | \r | |
1406 | typedef struct _EFI_IFR_MODULO {\r | |
1407 | EFI_IFR_OP_HEADER Header;\r | |
1408 | } EFI_IFR_MODULO;\r | |
1409 | \r | |
1410 | typedef struct _EFI_IFR_NOT_EQUAL {\r | |
1411 | EFI_IFR_OP_HEADER Header;\r | |
1412 | } EFI_IFR_NOT_EQUAL;\r | |
1413 | \r | |
1414 | typedef struct _EFI_IFR_OR {\r | |
1415 | EFI_IFR_OP_HEADER Header;\r | |
959ccb23 | 1416 | } EFI_IFR_OR;\r |
1417 | \r | |
7d582d6b | 1418 | typedef struct _EFI_IFR_SHIFT_LEFT {\r |
1419 | EFI_IFR_OP_HEADER Header;\r | |
1420 | } EFI_IFR_SHIFT_LEFT;\r | |
959ccb23 | 1421 | \r |
7d582d6b | 1422 | typedef struct _EFI_IFR_SHIFT_RIGHT {\r |
1423 | EFI_IFR_OP_HEADER Header;\r | |
1424 | } EFI_IFR_SHIFT_RIGHT;\r | |
959ccb23 | 1425 | \r |
7d582d6b | 1426 | typedef struct _EFI_IFR_SUBTRACT {\r |
1427 | EFI_IFR_OP_HEADER Header;\r | |
1428 | } EFI_IFR_SUBTRACT;\r | |
959ccb23 | 1429 | \r |
7d582d6b | 1430 | typedef struct _EFI_IFR_CONDITIONAL {\r |
1431 | EFI_IFR_OP_HEADER Header;\r | |
1432 | } EFI_IFR_CONDITIONAL;\r | |
959ccb23 | 1433 | \r |
e0c047a0 | 1434 | //\r |
1435 | // Flags governing the matching criteria of EFI_IFR_FIND\r | |
1436 | //\r | |
7d582d6b | 1437 | #define EFI_IFR_FF_CASE_SENSITIVE 0x00\r |
1438 | #define EFI_IFR_FF_CASE_INSENSITIVE 0x01\r | |
959ccb23 | 1439 | \r |
7d582d6b | 1440 | typedef struct _EFI_IFR_FIND {\r |
1441 | EFI_IFR_OP_HEADER Header;\r | |
1442 | UINT8 Format;\r | |
1443 | } EFI_IFR_FIND;\r | |
1444 | \r | |
1445 | typedef struct _EFI_IFR_MID {\r | |
1446 | EFI_IFR_OP_HEADER Header;\r | |
1447 | } EFI_IFR_MID;\r | |
1448 | \r | |
1449 | typedef struct _EFI_IFR_TOKEN {\r | |
1450 | EFI_IFR_OP_HEADER Header;\r | |
1451 | } EFI_IFR_TOKEN;\r | |
1452 | \r | |
e0c047a0 | 1453 | //\r |
1454 | // Flags specifying whether to find the first matching string\r | |
1455 | // or the first non-matching string.\r | |
1456 | //\r | |
7d582d6b | 1457 | #define EFI_IFR_FLAGS_FIRST_MATCHING 0x00\r |
1458 | #define EFI_IFR_FLAGS_FIRST_NON_MATCHING 0x01\r | |
1459 | \r | |
1460 | typedef struct _EFI_IFR_SPAN {\r | |
1461 | EFI_IFR_OP_HEADER Header;\r | |
1462 | UINT8 Flags;\r | |
1463 | } EFI_IFR_SPAN;\r | |
959ccb23 | 1464 | \r |
0cd118f7 LG |
1465 | typedef struct _EFI_IFR_SECURITY {\r |
1466 | ///\r | |
1467 | /// Standard opcode header, where Header.Op = EFI_IFR_SECURITY_OP.\r | |
1468 | ///\r | |
1469 | EFI_IFR_OP_HEADER Header;\r | |
1470 | ///\r | |
1471 | /// Security permission level.\r | |
1472 | ///\r | |
1473 | EFI_GUID Permissions;\r | |
1474 | } EFI_IFR_SECURITY;\r | |
1475 | \r | |
1476 | typedef struct _EFI_IFR_FORM_MAP_METHOD {\r | |
1477 | ///\r | |
1478 | /// The string identifier which provides the human-readable name of \r | |
1479 | /// the configuration method for this standards map form.\r | |
1480 | ///\r | |
1481 | EFI_STRING_ID MethodTitle;\r | |
1482 | ///\r | |
1483 | /// Identifier which uniquely specifies the configuration methods \r | |
1484 | /// associated with this standards map form.\r | |
1485 | ///\r | |
1486 | EFI_GUID MethodIdentifier;\r | |
1487 | } EFI_IFR_FORM_MAP_METHOD;\r | |
1488 | \r | |
1489 | typedef struct _EFI_IFR_FORM_MAP {\r | |
1490 | ///\r | |
1491 | /// The sequence that defines the type of opcode as well as the length \r | |
1492 | /// of the opcode being defined. Header.OpCode = EFI_IFR_FORM_MAP_OP. \r | |
1493 | ///\r | |
1494 | EFI_IFR_OP_HEADER Header;\r | |
1495 | ///\r | |
1496 | /// The unique identifier for this particular form.\r | |
1497 | ///\r | |
1498 | EFI_FORM_ID FormId;\r | |
1499 | ///\r | |
1500 | /// One or more configuration method's name and unique identifier.\r | |
1501 | ///\r | |
2573712e | 1502 | // EFI_IFR_FORM_MAP_METHOD Methods[];\r |
0cd118f7 LG |
1503 | } EFI_IFR_FORM_MAP;\r |
1504 | \r | |
1505 | typedef struct _EFI_IFR_SET {\r | |
1506 | ///\r | |
1507 | /// The sequence that defines the type of opcode as well as the length \r | |
1508 | /// of the opcode being defined. Header.OpCode = EFI_IFR_SET_OP. \r | |
1509 | ///\r | |
1510 | EFI_IFR_OP_HEADER Header;\r | |
1511 | ///\r | |
1512 | /// Specifies the identifier of a previously declared variable store to \r | |
1513 | /// use when storing the question's value. \r | |
1514 | ///\r | |
1515 | EFI_VARSTORE_ID VarStoreId;\r | |
1516 | union {\r | |
1517 | ///\r | |
1518 | /// A 16-bit Buffer Storage offset.\r | |
1519 | ///\r | |
1520 | EFI_STRING_ID VarName;\r | |
1521 | ///\r | |
1522 | /// A Name Value or EFI Variable name (VarName).\r | |
1523 | ///\r | |
1524 | UINT16 VarOffset;\r | |
1525 | } VarStoreInfo;\r | |
2573712e LG |
1526 | ///\r |
1527 | /// Specifies the type used for storage. \r | |
1528 | ///\r | |
1529 | UINT8 VarStoreType;\r | |
0cd118f7 LG |
1530 | } EFI_IFR_SET;\r |
1531 | \r | |
1532 | typedef struct _EFI_IFR_GET {\r | |
1533 | ///\r | |
1534 | /// The sequence that defines the type of opcode as well as the length \r | |
1535 | /// of the opcode being defined. Header.OpCode = EFI_IFR_GET_OP. \r | |
1536 | ///\r | |
1537 | EFI_IFR_OP_HEADER Header;\r | |
1538 | ///\r | |
1539 | /// Specifies the identifier of a previously declared variable store to \r | |
1540 | /// use when retrieving the value. \r | |
1541 | ///\r | |
1542 | EFI_VARSTORE_ID VarStoreId;\r | |
1543 | union {\r | |
1544 | ///\r | |
1545 | /// A 16-bit Buffer Storage offset.\r | |
1546 | ///\r | |
1547 | EFI_STRING_ID VarName;\r | |
1548 | ///\r | |
1549 | /// A Name Value or EFI Variable name (VarName).\r | |
1550 | ///\r | |
1551 | UINT16 VarOffset;\r | |
1552 | } VarStoreInfo;\r | |
1553 | ///\r | |
1554 | /// Specifies the type used for storage. \r | |
1555 | ///\r | |
1556 | UINT8 VarStoreType;\r | |
1557 | } EFI_IFR_GET;\r | |
1558 | \r | |
1559 | typedef struct _EFI_IFR_READ {\r | |
1560 | EFI_IFR_OP_HEADER Header;\r | |
1561 | } EFI_IFR_READ;\r | |
1562 | \r | |
1563 | typedef struct _EFI_IFR_WRITE {\r | |
1564 | EFI_IFR_OP_HEADER Header;\r | |
1565 | } EFI_IFR_WRITE;\r | |
1566 | \r | |
1567 | typedef struct _EFI_IFR_MAP {\r | |
1568 | EFI_IFR_OP_HEADER Header;\r | |
1569 | } EFI_IFR_MAP;\r | |
959ccb23 | 1570 | //\r |
e0c047a0 | 1571 | // Definitions for Keyboard Package\r |
e0c047a0 | 1572 | // Releated definitions are in Section of EFI_HII_DATABASE_PROTOCOL\r |
959ccb23 | 1573 | //\r |
7d582d6b | 1574 | \r |
9319d2c2 LG |
1575 | ///\r |
1576 | /// Each enumeration values maps a physical key on a keyboard.\r | |
1577 | ///\r | |
7d582d6b | 1578 | typedef enum { \r |
1579 | EfiKeyLCtrl,\r | |
1580 | EfiKeyA0, \r | |
1581 | EfiKeyLAlt,\r | |
1582 | EfiKeySpaceBar,\r | |
1583 | EfiKeyA2,\r | |
1584 | EfiKeyA3,\r | |
1585 | EfiKeyA4,\r | |
1586 | EfiKeyRCtrl,\r | |
1587 | EfiKeyLeftArrow,\r | |
1588 | EfiKeyDownArrow,\r | |
1589 | EfiKeyRightArrow,\r | |
1590 | EfiKeyZero,\r | |
1591 | EfiKeyPeriod,\r | |
1592 | EfiKeyEnter,\r | |
1593 | EfiKeyLShift,\r | |
1594 | EfiKeyB0,\r | |
1595 | EfiKeyB1,\r | |
1596 | EfiKeyB2,\r | |
1597 | EfiKeyB3,\r | |
1598 | EfiKeyB4,\r | |
1599 | EfiKeyB5,\r | |
1600 | EfiKeyB6,\r | |
1601 | EfiKeyB7,\r | |
1602 | EfiKeyB8,\r | |
1603 | EfiKeyB9,\r | |
1604 | EfiKeyB10,\r | |
54cf8780 | 1605 | EfiKeyRShift,\r |
7d582d6b | 1606 | EfiKeyUpArrow,\r |
1607 | EfiKeyOne,\r | |
1608 | EfiKeyTwo,\r | |
1609 | EfiKeyThree,\r | |
1610 | EfiKeyCapsLock,\r | |
1611 | EfiKeyC1,\r | |
1612 | EfiKeyC2,\r | |
1613 | EfiKeyC3,\r | |
1614 | EfiKeyC4,\r | |
1615 | EfiKeyC5,\r | |
1616 | EfiKeyC6,\r | |
1617 | EfiKeyC7,\r | |
1618 | EfiKeyC8,\r | |
1619 | EfiKeyC9,\r | |
1620 | EfiKeyC10,\r | |
1621 | EfiKeyC11,\r | |
1622 | EfiKeyC12,\r | |
1623 | EfiKeyFour,\r | |
1624 | EfiKeyFive,\r | |
1625 | EfiKeySix,\r | |
1626 | EfiKeyPlus,\r | |
1627 | EfiKeyTab,\r | |
1628 | EfiKeyD1,\r | |
1629 | EfiKeyD2,\r | |
1630 | EfiKeyD3,\r | |
1631 | EfiKeyD4,\r | |
1632 | EfiKeyD5,\r | |
1633 | EfiKeyD6,\r | |
1634 | EfiKeyD7,\r | |
1635 | EfiKeyD8,\r | |
1636 | EfiKeyD9,\r | |
1637 | EfiKeyD10,\r | |
1638 | EfiKeyD11,\r | |
1639 | EfiKeyD12,\r | |
1640 | EfiKeyD13,\r | |
1641 | EfiKeyDel,\r | |
1642 | EfiKeyEnd,\r | |
1643 | EfiKeyPgDn,\r | |
1644 | EfiKeySeven,\r | |
1645 | EfiKeyEight,\r | |
1646 | EfiKeyNine,\r | |
1647 | EfiKeyE0,\r | |
1648 | EfiKeyE1,\r | |
1649 | EfiKeyE2,\r | |
1650 | EfiKeyE3,\r | |
1651 | EfiKeyE4,\r | |
1652 | EfiKeyE5,\r | |
1653 | EfiKeyE6,\r | |
1654 | EfiKeyE7,\r | |
1655 | EfiKeyE8,\r | |
1656 | EfiKeyE9,\r | |
1657 | EfiKeyE10,\r | |
1658 | EfiKeyE11,\r | |
1659 | EfiKeyE12,\r | |
1660 | EfiKeyBackSpace,\r | |
1661 | EfiKeyIns,\r | |
1662 | EfiKeyHome,\r | |
1663 | EfiKeyPgUp,\r | |
1664 | EfiKeyNLck,\r | |
1665 | EfiKeySlash,\r | |
1666 | EfiKeyAsterisk,\r | |
1667 | EfiKeyMinus,\r | |
1668 | EfiKeyEsc,\r | |
1669 | EfiKeyF1,\r | |
1670 | EfiKeyF2,\r | |
1671 | EfiKeyF3,\r | |
1672 | EfiKeyF4,\r | |
1673 | EfiKeyF5,\r | |
1674 | EfiKeyF6,\r | |
1675 | EfiKeyF7,\r | |
1676 | EfiKeyF8,\r | |
1677 | EfiKeyF9,\r | |
1678 | EfiKeyF10,\r | |
1679 | EfiKeyF11,\r | |
1680 | EfiKeyF12,\r | |
1681 | EfiKeyPrint,\r | |
1682 | EfiKeySLck,\r | |
1683 | EfiKeyPause\r | |
1684 | } EFI_KEY;\r | |
1685 | \r | |
959ccb23 | 1686 | typedef struct {\r |
fbf926ad | 1687 | ///\r |
1688 | /// Used to describe a physical key on a keyboard.\r | |
1689 | ///\r | |
7d582d6b | 1690 | EFI_KEY Key;\r |
fbf926ad | 1691 | ///\r |
1692 | /// Unicode character code for the Key.\r | |
1693 | ///\r | |
7d582d6b | 1694 | CHAR16 Unicode;\r |
fbf926ad | 1695 | ///\r |
1696 | /// Unicode character code for the key with the shift key being held down.\r | |
1697 | ///\r | |
7d582d6b | 1698 | CHAR16 ShiftedUnicode;\r |
fbf926ad | 1699 | ///\r |
1700 | /// Unicode character code for the key with the Alt-GR being held down.\r | |
1701 | ///\r | |
7d582d6b | 1702 | CHAR16 AltGrUnicode;\r |
fbf926ad | 1703 | ///\r |
1704 | /// Unicode character code for the key with the Alt-GR and shift keys being held down.\r | |
1705 | ///\r | |
7d582d6b | 1706 | CHAR16 ShiftedAltGrUnicode;\r |
fbf926ad | 1707 | ///\r |
1708 | /// Modifier keys are defined to allow for special functionality that is not necessarily \r | |
1709 | /// accomplished by a printable character. Many of these modifier keys are flags to toggle \r | |
1710 | /// certain state bits on and off inside of a keyboard driver.\r | |
1711 | ///\r | |
7d582d6b | 1712 | UINT16 Modifier;\r |
1713 | UINT16 AffectedAttribute;\r | |
1714 | } EFI_KEY_DESCRIPTOR;\r | |
1715 | \r | |
8b13229b | 1716 | ///\r |
1717 | /// A key which is affected by all the standard shift modifiers. \r | |
1718 | /// Most keys would be expected to have this bit active.\r | |
1719 | ///\r | |
7d582d6b | 1720 | #define EFI_AFFECTED_BY_STANDARD_SHIFT 0x0001\r |
8b13229b | 1721 | \r |
1722 | ///\r | |
1723 | /// This key is affected by the caps lock so that if a keyboard driver\r | |
1724 | /// would need to disambiguate between a key which had a "1" defined\r | |
1a2f870c | 1725 | /// versus an "a" character. Having this bit turned on would tell\r |
8b13229b | 1726 | /// the keyboard driver to use the appropriate shifted state or not.\r |
1727 | ///\r | |
7d582d6b | 1728 | #define EFI_AFFECTED_BY_CAPS_LOCK 0x0002\r |
8b13229b | 1729 | \r |
1730 | ///\r | |
1731 | /// Similar to the case of CAPS lock, if this bit is active, the key\r | |
1732 | /// is affected by the num lock being turned on.\r | |
1733 | ///\r | |
7d582d6b | 1734 | #define EFI_AFFECTED_BY_NUM_LOCK 0x0004\r |
959ccb23 | 1735 | \r |
1736 | typedef struct {\r | |
7d582d6b | 1737 | UINT16 LayoutLength;\r |
1738 | EFI_GUID Guid;\r | |
1739 | UINT32 LayoutDescriptorStringOffset;\r | |
1740 | UINT8 DescriptorCount;\r | |
1741 | // EFI_KEY_DESCRIPTOR Descriptors[];\r | |
1742 | } EFI_HII_KEYBOARD_LAYOUT;\r | |
959ccb23 | 1743 | \r |
1744 | typedef struct {\r | |
7d582d6b | 1745 | EFI_HII_PACKAGE_HEADER Header;\r |
1746 | UINT16 LayoutCount;\r | |
1747 | // EFI_HII_KEYBOARD_LAYOUT Layout[];\r | |
1748 | } EFI_HII_KEYBOARD_PACKAGE_HDR;\r | |
959ccb23 | 1749 | \r |
959ccb23 | 1750 | //\r |
7d582d6b | 1751 | // Modifier values\r |
959ccb23 | 1752 | //\r |
7d582d6b | 1753 | #define EFI_NULL_MODIFIER 0x0000\r |
1754 | #define EFI_LEFT_CONTROL_MODIFIER 0x0001\r | |
1755 | #define EFI_RIGHT_CONTROL_MODIFIER 0x0002\r | |
1756 | #define EFI_LEFT_ALT_MODIFIER 0x0003\r | |
1757 | #define EFI_RIGHT_ALT_MODIFIER 0x0004\r | |
1758 | #define EFI_ALT_GR_MODIFIER 0x0005\r | |
1759 | #define EFI_INSERT_MODIFIER 0x0006\r | |
1760 | #define EFI_DELETE_MODIFIER 0x0007\r | |
1761 | #define EFI_PAGE_DOWN_MODIFIER 0x0008\r | |
1762 | #define EFI_PAGE_UP_MODIFIER 0x0009\r | |
1763 | #define EFI_HOME_MODIFIER 0x000A\r | |
1764 | #define EFI_END_MODIFIER 0x000B\r | |
1765 | #define EFI_LEFT_SHIFT_MODIFIER 0x000C\r | |
1766 | #define EFI_RIGHT_SHIFT_MODIFIER 0x000D\r | |
1767 | #define EFI_CAPS_LOCK_MODIFIER 0x000E\r | |
54cf8780 | 1768 | #define EFI_NUM_LOCK_MODIFIER 0x000F\r |
7d582d6b | 1769 | #define EFI_LEFT_ARROW_MODIFIER 0x0010\r |
1770 | #define EFI_RIGHT_ARROW_MODIFIER 0x0011\r | |
1771 | #define EFI_DOWN_ARROW_MODIFIER 0x0012\r | |
1772 | #define EFI_UP_ARROW_MODIFIER 0x0013\r | |
1773 | #define EFI_NS_KEY_MODIFIER 0x0014\r | |
1774 | #define EFI_NS_KEY_DEPENDENCY_MODIFIER 0x0015\r | |
1775 | #define EFI_FUNCTION_KEY_ONE_MODIFIER 0x0016\r | |
1776 | #define EFI_FUNCTION_KEY_TWO_MODIFIER 0x0017\r | |
1777 | #define EFI_FUNCTION_KEY_THREE_MODIFIER 0x0018\r | |
1778 | #define EFI_FUNCTION_KEY_FOUR_MODIFIER 0x0019\r | |
1779 | #define EFI_FUNCTION_KEY_FIVE_MODIFIER 0x001A\r | |
1780 | #define EFI_FUNCTION_KEY_SIX_MODIFIER 0x001B\r | |
1781 | #define EFI_FUNCTION_KEY_SEVEN_MODIFIER 0x001C\r | |
1782 | #define EFI_FUNCTION_KEY_EIGHT_MODIFIER 0x001D\r | |
1783 | #define EFI_FUNCTION_KEY_NINE_MODIFIER 0x001E\r | |
1784 | #define EFI_FUNCTION_KEY_TEN_MODIFIER 0x001F\r | |
1785 | #define EFI_FUNCTION_KEY_ELEVEN_MODIFIER 0x0020\r | |
1786 | #define EFI_FUNCTION_KEY_TWELVE_MODIFIER 0x0021\r | |
959ccb23 | 1787 | \r |
7d582d6b | 1788 | //\r |
1789 | // Keys that have multiple control functions based on modifier\r | |
1790 | // settings are handled in the keyboard driver implementation.\r | |
1a2f870c | 1791 | // For instance, PRINT_KEY might have a modifier held down and\r |
7d582d6b | 1792 | // is still a nonprinting character, but might have an alternate\r |
1793 | // control function like SYSREQUEST\r | |
1794 | //\r | |
1795 | #define EFI_PRINT_MODIFIER 0x0022\r | |
1796 | #define EFI_SYS_REQUEST_MODIFIER 0x0023\r | |
1797 | #define EFI_SCROLL_LOCK_MODIFIER 0x0024\r | |
1798 | #define EFI_PAUSE_MODIFIER 0x0025\r | |
1799 | #define EFI_BREAK_MODIFIER 0x0026\r | |
959ccb23 | 1800 | \r |
54cf8780 | 1801 | #define EFI_LEFT_LOGO_MODIFIER 0x0027\r |
1802 | #define EFI_RIGHT_LOGO_MODIFIER 0x0028\r | |
1803 | #define EFI_MENU_MODIFIER 0x0029\r | |
1804 | \r | |
f6051525 | 1805 | ///\r |
1806 | /// Animation IFR opcode\r | |
1807 | ///\r | |
1808 | typedef struct _EFI_IFR_ANIMATION {\r | |
1809 | ///\r | |
1810 | /// Standard opcode header, where Header.OpCode is \r | |
1811 | /// EFI_IFR_ANIMATION_OP.\r | |
1812 | ///\r | |
1813 | EFI_IFR_OP_HEADER Header;\r | |
1814 | ///\r | |
1815 | /// Animation identifier in the HII database.\r | |
1816 | ///\r | |
1817 | EFI_ANIMATION_ID Id;\r | |
1818 | } EFI_IFR_ANIMATION;\r | |
1819 | \r | |
1820 | ///\r | |
af2dc6a7 | 1821 | /// HII animation package header.\r |
f6051525 | 1822 | ///\r |
1823 | typedef struct _EFI_HII_ANIMATION_PACKAGE_HDR {\r | |
1824 | ///\r | |
1825 | /// Standard package header, where Header.Type = EFI_HII_PACKAGE_ANIMATIONS.\r | |
1826 | ///\r | |
1827 | EFI_HII_PACKAGE_HEADER Header;\r | |
1828 | ///\r | |
1829 | /// Offset, relative to this header, of the animation information. If \r | |
1830 | /// this is zero, then there are no animation sequences in the package.\r | |
1831 | ///\r | |
1832 | UINT32 AnimationInfoOffset;\r | |
1833 | } EFI_HII_ANIMATION_PACKAGE_HDR;\r | |
1834 | \r | |
1835 | ///\r | |
1836 | /// Animation information is encoded as a series of blocks,\r | |
af2dc6a7 | 1837 | /// with each block prefixed by a single byte header EFI_HII_ANIMATION_BLOCK.\r |
f6051525 | 1838 | ///\r |
1839 | typedef struct _EFI_HII_ANIMATION_BLOCK {\r | |
1840 | UINT8 BlockType;\r | |
1841 | //UINT8 BlockBody[];\r | |
1842 | } EFI_HII_ANIMATION_BLOCK;\r | |
1843 | \r | |
1844 | ///\r | |
af2dc6a7 | 1845 | /// Animation block types.\r |
f6051525 | 1846 | ///\r |
1847 | #define EFI_HII_AIBT_END 0x00\r | |
1848 | #define EFI_HII_AIBT_OVERLAY_IMAGES 0x10\r | |
1849 | #define EFI_HII_AIBT_CLEAR_IMAGES 0x11\r | |
1850 | #define EFI_HII_AIBT_RESTORE_SCRN 0x12\r | |
1851 | #define EFI_HII_AIBT_OVERLAY_IMAGES_LOOP 0x18\r | |
1852 | #define EFI_HII_AIBT_CLEAR_IMAGES_LOOP 0x19\r | |
1853 | #define EFI_HII_AIBT_RESTORE_SCRN_LOOP 0x1A\r | |
1854 | #define EFI_HII_AIBT_DUPLICATE 0x20\r | |
1855 | #define EFI_HII_AIBT_SKIP2 0x21\r | |
1856 | #define EFI_HII_AIBT_SKIP1 0x22\r | |
1857 | #define EFI_HII_AIBT_EXT1 0x30\r | |
1858 | #define EFI_HII_AIBT_EXT2 0x31\r | |
1859 | #define EFI_HII_AIBT_EXT4 0x32\r | |
1860 | \r | |
1861 | ///\r | |
1862 | /// Extended block headers used for variable sized animation records\r | |
1863 | /// which need an explicit length.\r | |
1864 | ///\r | |
1865 | \r | |
1866 | typedef struct _EFI_HII_AIBT_EXT1_BLOCK {\r | |
1867 | ///\r | |
af2dc6a7 | 1868 | /// Standard animation header, where Header.BlockType = EFI_HII_AIBT_EXT1.\r |
f6051525 | 1869 | ///\r |
1870 | EFI_HII_ANIMATION_BLOCK Header;\r | |
1871 | ///\r | |
af2dc6a7 | 1872 | /// The block type.\r |
f6051525 | 1873 | ///\r |
1874 | UINT8 BlockType2;\r | |
1875 | ///\r | |
1876 | /// Size of the animation block, in bytes, including the animation block header.\r | |
1877 | ///\r | |
1878 | UINT8 Length;\r | |
1879 | } EFI_HII_AIBT_EXT1_BLOCK;\r | |
1880 | \r | |
1881 | typedef struct _EFI_HII_AIBT_EXT2_BLOCK {\r | |
1882 | ///\r | |
af2dc6a7 | 1883 | /// Standard animation header, where Header.BlockType = EFI_HII_AIBT_EXT2.\r |
f6051525 | 1884 | ///\r |
1885 | EFI_HII_ANIMATION_BLOCK Header;\r | |
1886 | ///\r | |
1887 | /// The block type\r | |
1888 | ///\r | |
1889 | UINT8 BlockType2;\r | |
1890 | ///\r | |
1891 | /// Size of the animation block, in bytes, including the animation block header.\r | |
1892 | ///\r | |
1893 | UINT16 Length;\r | |
1894 | } EFI_HII_AIBT_EXT2_BLOCK;\r | |
1895 | \r | |
1896 | typedef struct _EFI_HII_AIBT_EXT4_BLOCK {\r | |
1897 | ///\r | |
af2dc6a7 | 1898 | /// Standard animation header, where Header.BlockType = EFI_HII_AIBT_EXT4.\r |
f6051525 | 1899 | ///\r |
1900 | EFI_HII_ANIMATION_BLOCK Header;\r | |
1901 | ///\r | |
1902 | /// The block type\r | |
1903 | ///\r | |
1904 | UINT8 BlockType2;\r | |
1905 | ///\r | |
1906 | /// Size of the animation block, in bytes, including the animation block header.\r | |
1907 | ///\r | |
1908 | UINT32 Length;\r | |
1909 | } EFI_HII_AIBT_EXT4_BLOCK;\r | |
1910 | \r | |
1911 | typedef struct _EFI_HII_ANIMATION_CELL {\r | |
1912 | ///\r | |
1913 | /// The X offset from the upper left hand corner of the logical \r | |
1914 | /// window to position the indexed image.\r | |
1915 | ///\r | |
1916 | UINT16 OffsetX;\r | |
1917 | ///\r | |
1918 | /// The Y offset from the upper left hand corner of the logical \r | |
1919 | /// window to position the indexed image.\r | |
1920 | ///\r | |
1921 | UINT16 OffsetY;\r | |
1922 | ///\r | |
1923 | /// The image to display at the specified offset from the upper left \r | |
1924 | /// hand corner of the logical window.\r | |
1925 | ///\r | |
1926 | EFI_IMAGE_ID ImageId;\r | |
1927 | ///\r | |
1928 | /// The number of milliseconds to delay after displaying the indexed \r | |
1929 | /// image and before continuing on to the next linked image. If value \r | |
1930 | /// is zero, no delay.\r | |
1931 | ///\r | |
1932 | UINT16 Delay;\r | |
1933 | } EFI_HII_ANIMATION_CELL;\r | |
1934 | \r | |
1935 | ///\r | |
1936 | /// An animation block to describe an animation sequence that does not cycle, and\r | |
1937 | /// where one image is simply displayed over the previous image.\r | |
1938 | ///\r | |
8c6d73fb | 1939 | typedef struct _EFI_HII_AIBT_OVERLAY_IMAGES_BLOCK {\r |
f6051525 | 1940 | ///\r |
1941 | /// This is image that is to be reference by the image protocols, if the \r | |
1942 | /// animation function is not supported or disabled. This image can \r | |
1943 | /// be one particular image from the animation sequence (if any one \r | |
1944 | /// of the animation frames has a complete image) or an alternate \r | |
1945 | /// image that can be displayed alone. If the value is zero, no image \r | |
1946 | /// is displayed.\r | |
1947 | ///\r | |
1948 | EFI_IMAGE_ID DftImageId;\r | |
1949 | ///\r | |
1950 | /// The overall width of the set of images (logical window width).\r | |
1951 | ///\r | |
1952 | UINT16 Width;\r | |
1953 | ///\r | |
1954 | /// The overall height of the set of images (logical window height).\r | |
1955 | ///\r | |
1956 | UINT16 Height;\r | |
1957 | ///\r | |
1958 | /// The number of EFI_HII_ANIMATION_CELL contained in the \r | |
1959 | /// animation sequence.\r | |
1960 | ///\r | |
1961 | UINT16 CellCount;\r | |
1962 | ///\r | |
1963 | /// An array of CellCount animation cells.\r | |
1964 | ///\r | |
1965 | EFI_HII_ANIMATION_CELL AnimationCell[1];\r | |
1966 | } EFI_HII_AIBT_OVERLAY_IMAGES_BLOCK;\r | |
1967 | \r | |
1968 | ///\r | |
1969 | /// An animation block to describe an animation sequence that does not cycle,\r | |
1970 | /// and where the logical window is cleared to the specified color before \r | |
1971 | /// the next image is displayed.\r | |
1972 | ///\r | |
1973 | typedef struct _EFI_HII_AIBT_CLEAR_IMAGES_BLOCK {\r | |
1974 | ///\r | |
1975 | /// This is image that is to be reference by the image protocols, if the \r | |
1976 | /// animation function is not supported or disabled. This image can \r | |
1977 | /// be one particular image from the animation sequence (if any one \r | |
1978 | /// of the animation frames has a complete image) or an alternate \r | |
1979 | /// image that can be displayed alone. If the value is zero, no image \r | |
1980 | /// is displayed.\r | |
1981 | ///\r | |
1982 | EFI_IMAGE_ID DftImageId;\r | |
1983 | ///\r | |
1984 | /// The overall width of the set of images (logical window width).\r | |
1985 | ///\r | |
1986 | UINT16 Width;\r | |
1987 | ///\r | |
1988 | /// The overall height of the set of images (logical window height).\r | |
1989 | ///\r | |
1990 | UINT16 Height;\r | |
1991 | ///\r | |
1992 | /// The number of EFI_HII_ANIMATION_CELL contained in the \r | |
1993 | /// animation sequence.\r | |
1994 | ///\r | |
1995 | UINT16 CellCount;\r | |
1996 | ///\r | |
1997 | /// The color to clear the logical window to before displaying the \r | |
1998 | /// indexed image.\r | |
1999 | ///\r | |
2000 | EFI_HII_RGB_PIXEL BackgndColor;\r | |
2001 | ///\r | |
2002 | /// An array of CellCount animation cells.\r | |
2003 | ///\r | |
2004 | EFI_HII_ANIMATION_CELL AnimationCell[1];\r | |
2005 | } EFI_HII_AIBT_CLEAR_IMAGES_BLOCK;\r | |
2006 | \r | |
2007 | ///\r | |
2008 | /// An animation block to describe an animation sequence that does not cycle,\r | |
2009 | /// and where the screen is restored to the original state before the next \r | |
2010 | /// image is displayed.\r | |
2011 | ///\r | |
2012 | typedef struct _EFI_HII_AIBT_RESTORE_SCRN_BLOCK {\r | |
2013 | ///\r | |
2014 | /// This is image that is to be reference by the image protocols, if the \r | |
2015 | /// animation function is not supported or disabled. This image can \r | |
2016 | /// be one particular image from the animation sequence (if any one \r | |
2017 | /// of the animation frames has a complete image) or an alternate \r | |
2018 | /// image that can be displayed alone. If the value is zero, no image \r | |
2019 | /// is displayed.\r | |
2020 | ///\r | |
2021 | EFI_IMAGE_ID DftImageId;\r | |
2022 | ///\r | |
2023 | /// The overall width of the set of images (logical window width).\r | |
2024 | ///\r | |
2025 | UINT16 Width;\r | |
2026 | ///\r | |
2027 | /// The overall height of the set of images (logical window height).\r | |
2028 | ///\r | |
2029 | UINT16 Height;\r | |
2030 | ///\r | |
2031 | /// The number of EFI_HII_ANIMATION_CELL contained in the \r | |
2032 | /// animation sequence.\r | |
2033 | ///\r | |
2034 | UINT16 CellCount;\r | |
2035 | ///\r | |
2036 | /// An array of CellCount animation cells.\r | |
2037 | ///\r | |
2038 | EFI_HII_ANIMATION_CELL AnimationCell[1];\r | |
2039 | } EFI_HII_AIBT_RESTORE_SCRN_BLOCK;\r | |
2040 | \r | |
2041 | ///\r | |
2042 | /// An animation block to describe an animation sequence that continuously cycles,\r | |
2043 | /// and where one image is simply displayed over the previous image.\r | |
2044 | ///\r | |
2045 | typedef EFI_HII_AIBT_OVERLAY_IMAGES_BLOCK EFI_HII_AIBT_OVERLAY_IMAGES_LOOP_BLOCK;\r | |
2046 | \r | |
2047 | ///\r | |
2048 | /// An animation block to describe an animation sequence that continuously cycles,\r | |
2049 | /// and where the logical window is cleared to the specified color before \r | |
2050 | /// the next image is displayed.\r | |
2051 | ///\r | |
2052 | typedef EFI_HII_AIBT_CLEAR_IMAGES_BLOCK EFI_HII_AIBT_CLEAR_IMAGES_LOOP_BLOCK;\r | |
2053 | \r | |
2054 | ///\r | |
2055 | /// An animation block to describe an animation sequence that continuously cycles,\r | |
2056 | /// and where the screen is restored to the original state before \r | |
2057 | /// the next image is displayed.\r | |
2058 | ///\r | |
2059 | typedef EFI_HII_AIBT_RESTORE_SCRN_BLOCK EFI_HII_AIBT_RESTORE_SCRN_LOOP_BLOCK;\r | |
2060 | \r | |
2061 | ///\r | |
2062 | /// Assigns a new character value to a previously defined animation sequence.\r | |
2063 | ///\r | |
2064 | typedef struct _EFI_HII_AIBT_DUPLICATE_BLOCK {\r | |
2065 | ///\r | |
2066 | /// The previously defined animation ID with the exact same \r | |
2067 | /// animation information.\r | |
2068 | ///\r | |
2069 | EFI_ANIMATION_ID AnimationId;\r | |
2070 | } EFI_HII_AIBT_DUPLICATE_BLOCK;\r | |
2071 | \r | |
2072 | ///\r | |
2073 | /// Skips animation IDs.\r | |
2074 | ///\r | |
2075 | typedef struct _EFI_HII_AIBT_SKIP1_BLOCK {\r | |
2076 | ///\r | |
2077 | /// The unsigned 8-bit value to add to AnimationIdCurrent.\r | |
2078 | ///\r | |
2079 | UINT8 SkipCount;\r | |
2080 | } EFI_HII_AIBT_SKIP1_BLOCK;\r | |
2081 | \r | |
2082 | ///\r | |
2083 | /// Skips animation IDs.\r | |
2084 | ///\r | |
2085 | typedef struct _EFI_HII_AIBT_SKIP2_BLOCK {\r | |
2086 | ///\r | |
2087 | /// The unsigned 16-bit value to add to AnimationIdCurrent.\r | |
2088 | ///\r | |
2089 | UINT16 SkipCount;\r | |
2090 | } EFI_HII_AIBT_SKIP2_BLOCK;\r | |
2091 | \r | |
959ccb23 | 2092 | #pragma pack()\r |
2093 | \r | |
2094 | \r | |
2095 | \r | |
8b13229b | 2096 | ///\r |
2097 | /// References to string tokens must use this macro to enable scanning for\r | |
2098 | /// token usages.\r | |
2099 | ///\r | |
2100 | ///\r | |
2101 | /// STRING_TOKEN is not defined in UEFI specification. But it is placed \r | |
2102 | /// here for the easy access by C files and VFR source files.\r | |
2103 | ///\r | |
e52c5a9f | 2104 | #define STRING_TOKEN(t) t\r |
2105 | \r | |
959ccb23 | 2106 | #endif\r |