]> git.proxmox.com Git - mirror_edk2.git/blame - MdePkg/Include/Library/S3BootScriptLib.h
MdePkg: fix comment typo in DebugLib.h
[mirror_edk2.git] / MdePkg / Include / Library / S3BootScriptLib.h
CommitLineData
fe69ac84 1/** @file \r
2 Defines library APIs used by modules to save EFI Boot Script Opcodes. \r
3 These OpCode will be restored by S3 related modules. \r
4 Note that some of the API defined in the Library class may not \r
5 be provided in the Framework version library instance, which means some of these \r
6 APIs cannot be used if the underlying firmware is Framework and not PI.\r
7\r
300f2c6a 8 Copyright (c) 2006 - 2014, Intel Corporation. All rights reserved.<BR>\r
fe69ac84 9\r
10 This program and the accompanying materials\r
11 are licensed and made available under the terms and conditions\r
12 of the BSD License which accompanies this distribution. The\r
13 full text of the license may be found at\r
14 http://opensource.org/licenses/bsd-license.php\r
15\r
16 THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,\r
17 WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.\r
18\r
19**/\r
20\r
21#ifndef _S3_BOOT_SCRIPT_LIB_H_\r
22#define _S3_BOOT_SCRIPT_LIB_H_\r
23\r
24#include <Library/BaseLib.h>\r
25#include <IndustryStandard/SmBus.h>\r
26\r
27/**\r
28 Macro that converts PCI Bus, PCI Device, PCI Function and PCI Register to an\r
29 address that can be passed to the S3 Boot Script Library PCI functions.\r
30\r
31 @param Bus PCI Bus number. Range 0..255.\r
32 @param Device PCI Device number. Range 0..31.\r
33 @param Function PCI Function number. Range 0..7.\r
34 @param Register PCI Register number. Range 0..255 for PCI. Range 0..4095\r
35 for PCI Express.\r
36\r
37 @return The encoded PCI address.\r
38\r
39**/\r
40#define S3_BOOT_SCRIPT_LIB_PCI_ADDRESS(Bus,Device,Function,Register) \\r
41 (UINT64) ( \\r
42 (((UINTN) Bus) << 24) | \\r
43 (((UINTN) Device) << 16) | \\r
44 (((UINTN) Function) << 8) | \\r
45 (((UINTN) (Register)) < 256 ? ((UINTN) (Register)) : (UINT64) (LShiftU64 ((UINT64) (Register), 32))))\r
46 \r
47///\r
48/// S3 Boot Script Width.\r
49///\r
50typedef enum {\r
51 S3BootScriptWidthUint8, ///< 8-bit operation.\r
52 S3BootScriptWidthUint16, ///< 16-bit operation.\r
53 S3BootScriptWidthUint32, ///< 32-bit operation. \r
54 S3BootScriptWidthUint64, ///< 64-bit operation.\r
55 S3BootScriptWidthFifoUint8, ///< 8-bit FIFO operation.\r
56 S3BootScriptWidthFifoUint16, ///< 16-bit FIFO operation.\r
57 S3BootScriptWidthFifoUint32, ///< 32-bit FIFO operation.\r
58 S3BootScriptWidthFifoUint64, ///< 64-bit FIFO operation.\r
59 S3BootScriptWidthFillUint8, ///< 8-bit Fill operation.\r
60 S3BootScriptWidthFillUint16, ///< 16-bit Fill operation.\r
61 S3BootScriptWidthFillUint32, ///< 32-bit Fill operation.\r
62 S3BootScriptWidthFillUint64, ///< 64-bit Fill operation.\r
63 S3BootScriptWidthMaximum\r
64} S3_BOOT_SCRIPT_LIB_WIDTH;\r
65\r
66/**\r
67 Save I/O write to boot script.\r
68\r
69 @param[in] Width The width of the I/O operations.\r
70 @param[in] Address The base address of the I/O operations.\r
71 @param[in] Count The number of I/O operations to perform.\r
72 @param[in] Buffer The source buffer from which to write data.\r
73\r
74 @retval RETURN_OUT_OF_RESOURCES Not enough memory for the table to perform \r
75 the operation.\r
76 @retval RETURN_SUCCESS The opcode was added.\r
77\r
78**/\r
79RETURN_STATUS\r
80EFIAPI\r
81S3BootScriptSaveIoWrite (\r
82 IN S3_BOOT_SCRIPT_LIB_WIDTH Width,\r
83 IN UINT64 Address,\r
84 IN UINTN Count,\r
85 IN VOID *Buffer\r
86 );\r
87\r
88/**\r
89 Adds a record for an I/O modify operation into a S3 boot script table.\r
90\r
91 @param[in] Width The width of the I/O operations.\r
92 @param[in] Address The base address of the I/O operations.\r
93 @param[in] Data A pointer to the data to be OR-ed.\r
94 @param[in] DataMask A pointer to the data mask to be AND-ed with the data\r
95 read from the register.\r
96\r
97 @retval RETURN_OUT_OF_RESOURCES Not enough memory for the table to perform \r
98 the operation.\r
99 @retval RETURN_SUCCESS The opcode was added.\r
100\r
101**/\r
102RETURN_STATUS\r
103EFIAPI\r
104S3BootScriptSaveIoReadWrite (\r
105 IN S3_BOOT_SCRIPT_LIB_WIDTH Width,\r
106 IN UINT64 Address,\r
107 IN VOID *Data,\r
108 IN VOID *DataMask\r
109 );\r
110\r
111/**\r
112 Adds a record for a memory write operation into a specified boot script table.\r
113\r
114 @param[in] Width The width of the I/O operations.\r
115 @param[in] Address The base address of the memory operations\r
116 @param[in] Count The number of memory operations to perform.\r
117 @param[in] Buffer The source buffer from which to write the data.\r
118\r
119 @retval RETURN_OUT_OF_RESOURCES Not enough memory for the table to perform \r
120 the operation.\r
121 @retval RETURN_SUCCESS The opcode was added.\r
122**/\r
123RETURN_STATUS\r
124EFIAPI\r
125S3BootScriptSaveMemWrite (\r
126 IN S3_BOOT_SCRIPT_LIB_WIDTH Width,\r
127 IN UINT64 Address,\r
128 IN UINTN Count,\r
129 IN VOID *Buffer\r
130 );\r
131\r
132/**\r
133 Adds a record for a memory modify operation into a specified boot script table.\r
134\r
135 @param[in] Width The width of the I/O operations.\r
136 @param[in] Address The base address of the memory operations. Address needs \r
137 alignment, if required\r
138 @param[in] Data A pointer to the data to be OR-ed.\r
139 @param[in] DataMask A pointer to the data mask to be AND-ed with the data \r
140 read from the register.\r
141\r
142 @retval RETURN_OUT_OF_RESOURCES Not enough memory for the table to perform \r
143 the operation.\r
144 @retval RETURN_SUCCESS The opcode was added.\r
145**/\r
146RETURN_STATUS\r
147EFIAPI\r
148S3BootScriptSaveMemReadWrite (\r
149 IN S3_BOOT_SCRIPT_LIB_WIDTH Width,\r
150 IN UINT64 Address,\r
151 IN VOID *Data,\r
152 IN VOID *DataMask\r
153 );\r
154\r
155/**\r
156 Adds a record for a PCI configuration space write operation into a specified boot script table.\r
157\r
158 @param[in] Width The width of the I/O operations.\r
159 @param[in] Address The address within the PCI configuration space.\r
160 @param[in] Count The number of PCI operations to perform.\r
161 @param[in] Buffer The source buffer from which to write the data.\r
162\r
163 @retval RETURN_OUT_OF_RESOURCES Not enough memory for the table to perform \r
164 the operation.\r
165 @retval RETURN_SUCCESS The opcode was added.\r
166**/\r
167RETURN_STATUS\r
168EFIAPI\r
169S3BootScriptSavePciCfgWrite (\r
170 IN S3_BOOT_SCRIPT_LIB_WIDTH Width,\r
171 IN UINT64 Address,\r
172 IN UINTN Count,\r
173 IN VOID *Buffer\r
174 );\r
175\r
176/**\r
177 Adds a record for a PCI configuration space modify operation into a specified boot script table.\r
178\r
179 @param[in] Width The width of the I/O operations.\r
180 @param[in] Address The address within the PCI configuration space.\r
181 @param[in] Data A pointer to the data to be OR-ed.The size depends on Width.\r
182 @param[in] DataMask A pointer to the data mask to be AND-ed.\r
183\r
184 @retval RETURN_OUT_OF_RESOURCES Not enough memory for the table to perform \r
185 the operation.\r
186 @retval RETURN__SUCCESS The opcode was added.\r
187**/\r
188RETURN_STATUS\r
189EFIAPI\r
190S3BootScriptSavePciCfgReadWrite (\r
191 IN S3_BOOT_SCRIPT_LIB_WIDTH Width,\r
192 IN UINT64 Address,\r
193 IN VOID *Data,\r
194 IN VOID *DataMask\r
195 );\r
196\r
197/**\r
198 Adds a record for a PCI configuration space modify operation into a specified boot script table.\r
199\r
200 @param[in] Width The width of the I/O operations.\r
201 @param[in] Segment The PCI segment number for Address.\r
202 @param[in] Address The address within the PCI configuration space.\r
203 @param[in] Count The number of PCI operations to perform.\r
204 @param[in] Buffer The source buffer from which to write the data.\r
205\r
206 @retval RETURN_OUT_OF_RESOURCES Not enough memory for the table to perform \r
207 the operation.\r
208 @retval RETURN_SUCCESS The opcode was added.\r
209**/\r
210RETURN_STATUS\r
211EFIAPI\r
212S3BootScriptSavePciCfg2Write (\r
213 IN S3_BOOT_SCRIPT_LIB_WIDTH Width,\r
214 IN UINT16 Segment,\r
215 IN UINT64 Address,\r
216 IN UINTN Count,\r
217 IN VOID *Buffer\r
218 );\r
219\r
220/**\r
221 Adds a record for a PCI configuration space modify operation into a specified boot script table.\r
222\r
223 @param[in] Width The width of the I/O operations.\r
224 @param[in] Segment The PCI segment number for Address.\r
225 @param[in] Address The address within the PCI configuration space.\r
226 @param[in] Data A pointer to the data to be OR-ed. The size depends on Width.\r
227 @param[in] DataMask A pointer to the data mask to be AND-ed.\r
228\r
229 @retval RETURN_OUT_OF_RESOURCES Not enough memory for the table to perform \r
230 the operation.\r
231 @retval RETURN_SUCCESS The opcode was added.\r
232**/\r
233RETURN_STATUS\r
234EFIAPI\r
235S3BootScriptSavePciCfg2ReadWrite (\r
236 IN S3_BOOT_SCRIPT_LIB_WIDTH Width,\r
237 IN UINT16 Segment,\r
238 IN UINT64 Address,\r
239 IN VOID *Data,\r
240 IN VOID *DataMask\r
241 );\r
242\r
243/**\r
244 Adds a record for an SMBus command execution into a specified boot script table.\r
245\r
246 @param[in] SmBusAddress Address that encodes the SMBUS Slave Address, SMBUS \r
247 Command, SMBUS Data Length, and PEC.\r
248 @param[in] Operation Indicates which particular SMBus protocol it will use \r
249 to execute the SMBus transactions.\r
250 @param[in] Length A pointer to signify the number of bytes that this \r
251 operation will do.\r
252 @param[in] Buffer Contains the value of data to execute to the SMBUS \r
253 slave device.\r
254 \r
255 @retval RETURN_OUT_OF_RESOURCES Not enough memory for the table to perform \r
256 the operation.\r
257 @retval RETURN_SUCCESS The opcode was added.\r
258**/\r
259RETURN_STATUS\r
260EFIAPI\r
261S3BootScriptSaveSmbusExecute (\r
262 IN UINTN SmBusAddress, \r
263 IN EFI_SMBUS_OPERATION Operation,\r
264 IN UINTN *Length,\r
265 IN VOID *Buffer\r
266 );\r
267\r
268/**\r
269 Adds a record for an execution stall on the processor into a specified boot script table.\r
270\r
271 @param[in] Duration The duration in microseconds of the stall.\r
272 \r
273 @retval RETURN_OUT_OF_RESOURCES Not enough memory for the table to perform \r
274 the operation.\r
275 @retval RETURN_SUCCESS The opcode was added.\r
276**/\r
277RETURN_STATUS\r
278EFIAPI\r
279S3BootScriptSaveStall (\r
280 IN UINTN Duration\r
281 );\r
282\r
283/**\r
300f2c6a 284 Adds a record for dispatching specified arbitrary code into a specified boot script table.\r
fe69ac84 285\r
286 @param[in] EntryPoint The entry point of the code to be dispatched.\r
287 @param[in] Context The argument to be passed into the EntryPoint of the code \r
288 to be dispatched.\r
289 \r
290 @retval RETURN_OUT_OF_RESOURCES Not enough memory for the table to perform \r
291 the operation.\r
292 @retval RETURN_SUCCESS The opcode was added.\r
293**/\r
294RETURN_STATUS\r
295EFIAPI\r
296S3BootScriptSaveDispatch2 (\r
297 IN VOID *EntryPoint,\r
298 IN VOID *Context\r
299 );\r
300\r
301/**\r
302 Adds a record for dispatching specified arbitrary code into a specified boot script table.\r
303\r
304 @param[in] EntryPoint The entry point of the code to be dispatched.\r
305 \r
306 @retval RETURN_OUT_OF_RESOURCES Not enough memory for the table to perform \r
307 the operation.\r
308 @retval RETURN_SUCCESS The opcode was added.\r
309**/\r
310RETURN_STATUS\r
311EFIAPI\r
312S3BootScriptSaveDispatch (\r
313 IN VOID *EntryPoint\r
314 );\r
315\r
316/**\r
317 Adds a record for memory reads of the memory location and continues when the exit \r
318 criteria is satisfied, or after a defined duration.\r
57a1b9c4
JY
319\r
320 Please aware, below interface is different with PI specification, Vol 5:\r
321 EFI_S3_SAVE_STATE_PROTOCOL.Write() for EFI_BOOT_SCRIPT_MEM_POLL_OPCODE.\r
322 "Duration" below is microseconds, while "Delay" in PI specification means\r
323 the number of 100ns units to poll.\r
324\r
fe69ac84 325 @param[in] Width The width of the memory operations.\r
326 @param[in] Address The base address of the memory operations.\r
327 @param[in] BitMask A pointer to the bit mask to be AND-ed with the data read \r
328 from the register.\r
329 @param[in] BitValue A pointer to the data value after to be Masked.\r
330 @param[in] Duration The duration in microseconds of the stall.\r
331 @param[in] LoopTimes The times of the register polling.\r
332\r
333 @retval RETURN_OUT_OF_RESOURCES Not enough memory for the table to perform \r
334 the operation.\r
335 @retval RETURN_SUCCESS The opcode was added.\r
336\r
337**/\r
338RETURN_STATUS\r
339EFIAPI\r
340S3BootScriptSaveMemPoll (\r
341 IN S3_BOOT_SCRIPT_LIB_WIDTH Width,\r
342 IN UINT64 Address,\r
343 IN VOID *BitMask,\r
344 IN VOID *BitValue,\r
345 IN UINTN Duration,\r
346 IN UINTN LoopTimes\r
347 );\r
348\r
349/**\r
350 Store arbitrary information in the boot script table. This opcode is a no-op on \r
351 dispatch and is only used for debugging script issues.\r
352 \r
353 @param[in] InformationLength Length of the data in bytes\r
354 @param[in] Information Information to be logged in the boot scrpit\r
355 \r
fe69ac84 356 @retval RETURN_OUT_OF_RESOURCES Not enough memory for the table to perform \r
357 the operation.\r
358 @retval RETURN_SUCCESS The opcode was added.\r
359\r
360**/\r
361RETURN_STATUS\r
362EFIAPI\r
363S3BootScriptSaveInformation (\r
364 IN UINT32 InformationLength, \r
365 IN VOID *Information\r
366 );\r
367/**\r
368 Adds a record for I/O reads the I/O location and continues when the exit criteria\r
369 is satisfied, or after a defined duration.\r
370 \r
371 @param Width The width of the I/O operations. \r
372 @param Address The base address of the I/O operations.\r
373 @param Data The comparison value used for the polling exit criteria.\r
374 @param DataMask The mask used for the polling criteria. The bits in \r
375 the bytes below Width which are zero in Data are \r
376 ignored when polling the memory address.\r
377 @param Delay The number of 100ns units to poll. Note that timer \r
378 available may be of insufficient granularity, so the \r
379 delay may be longer.\r
380\r
381 @retval RETURN_OUT_OF_RESOURCES Not enough memory for the table to perform the \r
382 operation.\r
383 @retval RETURN_SUCCESS The opcode was added.\r
384 @note The FRAMEWORK version implementation does not support this API \r
385**/\r
386RETURN_STATUS\r
387EFIAPI\r
388S3BootScriptSaveIoPoll (\r
389 IN S3_BOOT_SCRIPT_LIB_WIDTH Width,\r
390 IN UINT64 Address,\r
391 IN VOID *Data,\r
392 IN VOID *DataMask, \r
393 IN UINT64 Delay \r
394 );\r
395\r
396/**\r
397 Adds a record for PCI configuration space reads and continues when the exit \r
398 criteria is satisfied ,or after a defined duration.\r
399\r
400 @param Width The width of the I/O operations. \r
401 @param Address The address within the PCI configuration space.\r
402 @param Data The comparison value used for the polling exit \r
403 criteria.\r
404 @param DataMask Mask used for the polling criteria. The bits in \r
405 the bytes below Width which are zero in Data are\r
406 ignored when polling the memory address.\r
407 @param Delay The number of 100ns units to poll. Note that timer \r
408 available may be of insufficient granularity, so the \r
409 delay may be longer.\r
410\r
411 @retval RETURN_OUT_OF_RESOURCES Not enough memory for the table to perform the \r
412 operation.\r
413 @retval RETURN_SUCCESS The opcode was added.\r
414 @note The FRAMEWORK version implementation does not support this API \r
415**/\r
416RETURN_STATUS\r
417EFIAPI\r
418S3BootScriptSavePciPoll (\r
419 IN S3_BOOT_SCRIPT_LIB_WIDTH Width,\r
420 IN UINT64 Address,\r
421 IN VOID *Data,\r
422 IN VOID *DataMask,\r
423 IN UINT64 Delay\r
424 );\r
425/**\r
426 Adds a record for PCI configuration space reads and continues when the exit criteria \r
427 is satisfied, or after a defined duration.\r
428\r
429 @param Width The width of the I/O operations. \r
430 @param Segment The PCI segment number for Address.\r
431 @param Address The address within the PCI configuration space.\r
432 @param Data The comparison value used for the polling exit \r
433 criteria.\r
434 @param DataMask Mask used for the polling criteria. The bits in \r
435 the bytes below Width which are zero\r
436 in Data are ignored when polling the memory address\r
437 @param Delay The number of 100ns units to poll. Note that timer \r
438 available may be of insufficient granularity so the delay \r
439 may be longer.\r
440\r
441 @retval RETURN_OUT_OF_RESOURCES Not enough memory for the table to perform the \r
442 operation.\r
443 @retval RETURN_SUCCESS The opcode was added.\r
444 @note A known Limitations in the implementation: When interpreting the opcode \r
445 EFI_BOOT_SCRIPT_PCI_CONFIG2_WRITE_OPCODE, EFI_BOOT_SCRIPT_PCI_CONFIG2_READ_WRITE_OPCODE\r
446 and EFI_BOOT_SCRIPT_PCI_CONFIG2_POLL_OPCODE, the 'Segment' parameter is assumed as \r
447 Zero, or else, assert.\r
448 The FRAMEWORK version implementation does not support this API.\r
449\r
450**/\r
451RETURN_STATUS\r
452EFIAPI\r
453S3BootScriptSavePci2Poll (\r
454 IN S3_BOOT_SCRIPT_LIB_WIDTH Width,\r
455 IN UINT16 Segment,\r
456 IN UINT64 Address,\r
457 IN VOID *Data,\r
458 IN VOID *DataMask,\r
459 IN UINT64 Delay\r
460 );\r
461/**\r
462 Save ASCII string information specified by Buffer to boot script with opcode \r
463 EFI_BOOT_SCRIPT_INFORMATION_OPCODE.\r
464\r
465 @param[in] String The Null-terminated ASCII string to store into the S3 boot \r
466 script table.\r
467\r
fe69ac84 468 @retval RETURN_OUT_OF_RESOURCES Not enough memory for the table to perform \r
469 the operation.\r
470 @retval RETURN_SUCCESS The opcode was added.\r
471\r
472**/\r
473RETURN_STATUS\r
474EFIAPI\r
475S3BootScriptSaveInformationAsciiString (\r
476 IN CONST CHAR8 *String\r
477 );\r
478\r
479/**\r
480 This is an function to close the S3 boot script table. The function could only \r
481 be called in BOOT time phase. To comply with the Framework spec definition on \r
482 EFI_BOOT_SCRIPT_SAVE_PROTOCOL.CloseTable(), this function will fulfill following things:\r
483 1. Closes the specified boot script table\r
484 2. It allocates a new memory pool to duplicate all the boot scripts in the specified table. \r
485 Once this function is called, the table maintained by the library will be destroyed \r
486 after it is copied into the allocated pool.\r
487 3. Any attempts to add a script record after calling this function will cause a \r
488 new table to be created by the library.\r
489 4. The base address of the allocated pool will be returned in Address. Note that \r
490 after using the boot script table, the CALLER is responsible for freeing the \r
491 pool that is allocated by this function. \r
492\r
493 In Spec PI1.1, this EFI_BOOT_SCRIPT_SAVE_PROTOCOL.CloseTable() is retired. This \r
494 API is supplied here to meet the requirements of the Framework Spec.\r
495 \r
496 If anyone does call CloseTable() on a real platform, then the caller is responsible\r
497 for figuring out how to get the script to run on an S3 resume because the boot script \r
498 maintained by the lib will be destroyed.\r
499 \r
e8480a18 500 @return the base address of the new copy of the boot script table. \r
fe69ac84 501\r
502**/\r
503UINT8*\r
504EFIAPI\r
505S3BootScriptCloseTable (\r
506 VOID\r
507 );\r
508\r
509/**\r
510 Executes the S3 boot script table.\r
511\r
512 @retval RETURN_SUCCESS The boot script table was executed successfully.\r
513 @retval RETURN_UNSUPPORTED Invalid script table or opcode. \r
514\r
515**/\r
516RETURN_STATUS\r
517EFIAPI\r
518S3BootScriptExecute (\r
519 VOID\r
520 );\r
521/**\r
522 Move the last boot script entry to the position \r
523\r
524 @param BeforeOrAfter Specifies whether the opcode is stored before \r
525 (TRUE) or after (FALSE) the positionin the boot \r
526 script table specified by Position. If Position \r
527 is NULL or points to NULL then the new opcode is \r
528 inserted at the beginning of the table (if TRUE) \r
529 or end of the table (if FALSE).\r
530 @param Position On entry, specifies the position in the boot script \r
531 table where the opcode will be inserted, either \r
532 before or after, depending on BeforeOrAfter. On \r
533 exit, specifies the position of the inserted opcode \r
534 in the boot script table.\r
535\r
536 @retval RETURN_OUT_OF_RESOURCES The table is not available.\r
537 @retval RETURN_INVALID_PARAMETER The Position is not a valid position in the \r
538 boot script table.\r
539 @retval RETURN_SUCCESS The opcode was inserted.\r
540 @note The FRAMEWORK version implementation does not support this API. \r
541**/\r
542RETURN_STATUS\r
543EFIAPI\r
544S3BootScriptMoveLastOpcode (\r
545 IN BOOLEAN BeforeOrAfter,\r
546 IN OUT VOID **Position OPTIONAL\r
547 );\r
548/**\r
549 Find a label within the boot script table and, if not present, optionally create it.\r
550\r
551 @param BeforeOrAfter Specifies whether the opcode is stored before (TRUE)\r
552 or after (FALSE) the position in the boot script table \r
553 specified by Position.\r
554 @param CreateIfNotFound Specifies whether the label will be created if the \r
555 label does not exists (TRUE) or not (FALSE).\r
556 @param Position On entry, specifies the position in the boot script \r
557 table where the opcode will be inserted, either \r
558 before or after, depending on BeforeOrAfter. On exit, \r
559 specifies the positionof the inserted opcode in \r
560 the boot script table.\r
561 @param Label Points to the label which will be inserted in the \r
562 boot script table.\r
563 @retval EFI_SUCCESS The operation succeeded. A record was added into \r
564 the specified script table.\r
565 @retval EFI_INVALID_PARAMETER The parameter is illegal or the given boot script \r
566 is not supported. If the opcode is unknow or not \r
567 supported because of the PCD Feature Flags.\r
568 @retval EFI_OUT_OF_RESOURCES There is insufficient memory to store the boot script.\r
569 @note The FRAMEWORK version implementation does not support this API \r
570\r
571**/\r
572RETURN_STATUS\r
573EFIAPI \r
574S3BootScriptLabel (\r
575 IN BOOLEAN BeforeOrAfter,\r
576 IN BOOLEAN CreateIfNotFound,\r
577 IN OUT VOID **Position OPTIONAL,\r
578 IN CONST CHAR8 *Label\r
579 );\r
580/**\r
581 Compare two positions in the boot script table and return their relative position.\r
582 @param Position1 The positions in the boot script table to compare\r
583 @param Position2 The positions in the boot script table to compare\r
584 @param RelativePosition On return, points to the result of the comparison\r
585\r
586 @retval EFI_SUCCESS The operation succeeded. A record was added into the\r
587 specified script table.\r
588 @retval EFI_INVALID_PARAMETER The parameter is illegal or the given boot script \r
589 is not supported. If the opcode is unknow or not s\r
590 upported because of the PCD Feature Flags.\r
591 @retval EFI_OUT_OF_RESOURCES There is insufficient memory to store the boot script.\r
592 @note The FRAMEWORK version implementation does not support this API \r
593**/\r
594RETURN_STATUS\r
595EFIAPI \r
596S3BootScriptCompare (\r
597 IN UINT8 *Position1,\r
598 IN UINT8 *Position2,\r
599 OUT UINTN *RelativePosition\r
600 );\r
601\r
602#endif\r