Add in function description and comments.
[mirror_edk2.git] / MdePkg / Include / Ppi / Pcd.h
1 /** @file
2 Platform Configuration Database (PCD) Protocol
3
4 Copyright (c) 2006, Intel Corporation
5 All rights reserved. This program and the accompanying materials
6 are licensed and made available under the terms and conditions of the BSD License
7 which accompanies this distribution. The full text of the license may be found at
8 http://opensource.org/licenses/bsd-license.php
9
10 THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
11 WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
12
13 Module Name: Pcd.h
14
15 **/
16
17 #ifndef __PCD_H__
18 #define __PCD_H__
19
20 extern EFI_GUID gPcdPpiGuid;
21
22 #define PCD_PPI_GUID \
23 { 0x6e81c58, 0x4ad7, 0x44bc, { 0x83, 0x90, 0xf1, 0x2, 0x65, 0xf7, 0x24, 0x80 } }
24
25 #define PCD_INVALID_TOKEN_NUMBER ((UINTN) 0)
26
27
28
29 /**
30 Sets the SKU value for subsequent calls to set or get PCD token values.
31
32 SetSku() sets the SKU Id to be used for subsequent calls to set or get PCD values.
33 SetSku() is normally called only once by the system.
34
35 For each item (token), the database can hold a single value that applies to all SKUs,
36 or multiple values, where each value is associated with a specific SKU Id. Items with multiple,
37 SKU-specific values are called SKU enabled.
38
39 The SKU Id of zero is reserved as a default. The valid SkuId range is 1 to 255.
40 For tokens that are not SKU enabled, the system ignores any set SKU Id and works with the
41 single value for that token. For SKU-enabled tokens, the system will use the SKU Id set by the
42 last call to SetSku(). If no SKU Id is set or the currently set SKU Id isn't valid for the specified token,
43 the system uses the default SKU Id. If the system attempts to use the default SKU Id and no value has been
44 set for that Id, the results are unpredictable.
45
46 @param SkuId The SKU value that will be used when the PCD service will retrieve and
47 set values associated with a PCD token.
48
49 @retval VOID
50
51 **/
52 typedef
53 VOID
54 (EFIAPI *PCD_PPI_SET_SKU) (
55 IN UINTN SkuId
56 );
57
58
59
60 /**
61 Retrieves an 8-bit value for a given PCD token.
62
63 Retrieves the current byte-sized value for a PCD token number.
64 If the TokenNumber is invalid, the results are unpredictable.
65
66 @param TokenNumber The PCD token number.
67
68 @return The UINT8 value.
69
70 **/
71 typedef
72 UINT8
73 (EFIAPI *PCD_PPI_GET8) (
74 IN UINTN TokenNumber
75 );
76
77
78
79 /**
80 Retrieves an 16-bit value for a given PCD token.
81
82 Retrieves the current 16-bits value for a PCD token number.
83 If the TokenNumber is invalid, the results are unpredictable.
84
85 @param TokenNumber The PCD token number.
86
87 @return The UINT16 value.
88
89 **/
90 typedef
91 UINT16
92 (EFIAPI *PCD_PPI_GET16) (
93 IN UINTN TokenNumber
94 );
95
96
97
98 /**
99 Retrieves an 32-bit value for a given PCD token.
100
101 Retrieves the current 32-bits value for a PCD token number.
102 If the TokenNumber is invalid, the results are unpredictable.
103
104 @param TokenNumber The PCD token number.
105
106 @return The UINT32 value.
107
108 **/
109 typedef
110 UINT32
111 (EFIAPI *PCD_PPI_GET32) (
112 IN UINTN TokenNumber
113 );
114
115
116
117 /**
118 Retrieves an 64-bit value for a given PCD token.
119
120 Retrieves the current 64-bits value for a PCD token number.
121 If the TokenNumber is invalid, the results are unpredictable.
122
123 @param TokenNumber The PCD token number.
124
125 @return The UINT64 value.
126
127 **/
128 typedef
129 UINT64
130 (EFIAPI *PCD_PPI_GET64) (
131 IN UINTN TokenNumber
132 );
133
134
135
136 /**
137 Retrieves a pointer to a value for a given PCD token.
138
139 Retrieves the current pointer to the buffer for a PCD token number.
140 Do not make any assumptions about the alignment of the pointer that
141 is returned by this function call. If the TokenNumber is invalid,
142 the results are unpredictable.
143
144 @param TokenNumber The PCD token number.
145
146 @return The pointer to the buffer to be retrived.
147
148 **/
149 typedef
150 VOID *
151 (EFIAPI *PCD_PPI_GET_POINTER) (
152 IN UINTN TokenNumber
153 );
154
155
156
157 /**
158 Retrieves a Boolean value for a given PCD token.
159
160 Retrieves the current boolean value for a PCD token number.
161 Do not make any assumptions about the alignment of the pointer that
162 is returned by this function call. If the TokenNumber is invalid,
163 the results are unpredictable.
164
165 @param TokenNumber The PCD token number.
166
167 @return The Boolean value.
168
169 **/
170 typedef
171 BOOLEAN
172 (EFIAPI *PCD_PPI_GET_BOOLEAN) (
173 IN UINTN TokenNumber
174 );
175
176
177
178 /**
179 Retrieves the size of the value for a given PCD token.
180
181 Retrieves the current size of a particular PCD token.
182 If the TokenNumber is invalid, the results are unpredictable.
183
184 @param TokenNumber The PCD token number.
185
186 @return The size of the value for the PCD token.
187
188 **/
189 typedef
190 UINTN
191 (EFIAPI *PCD_PPI_GET_SIZE) (
192 IN UINTN TokenNumber
193 );
194
195
196
197 /**
198 Retrieves an 8-bit value for a given PCD token.
199
200 Retrieves the 8-bit value of a particular PCD token.
201 If the TokenNumber is invalid or the token space
202 specified by Guid does not exist, the results are
203 unpredictable.
204
205 @param Guid The token space for the token number.
206 @param TokenNumber The PCD token number.
207
208 @return The size 8-bit value for the PCD token.
209
210 **/
211 typedef
212 UINT8
213 (EFIAPI *PCD_PPI_GET_EX_8) (
214 IN CONST EFI_GUID *Guid,
215 IN UINTN TokenNumber
216 );
217
218
219
220 /**
221 Retrieves an 16-bit value for a given PCD token.
222
223 Retrieves the 16-bit value of a particular PCD token.
224 If the TokenNumber is invalid or the token space
225 specified by Guid does not exist, the results are
226 unpredictable.
227
228 @param Guid The token space for the token number.
229 @param TokenNumber The PCD token number.
230
231 @return The size 16-bit value for the PCD token.
232
233 **/
234 typedef
235 UINT16
236 (EFIAPI *PCD_PPI_GET_EX_16) (
237 IN CONST EFI_GUID *Guid,
238 IN UINTN TokenNumber
239 );
240
241
242
243 /**
244 Retrieves an 32-bit value for a given PCD token.
245
246 Retrieves the 32-bit value of a particular PCD token.
247 If the TokenNumber is invalid or the token space
248 specified by Guid does not exist, the results are
249 unpredictable.
250
251 @param Guid The token space for the token number.
252 @param TokenNumber The PCD token number.
253
254 @return The size 32-bit value for the PCD token.
255
256 **/
257 typedef
258 UINT32
259 (EFIAPI *PCD_PPI_GET_EX_32) (
260 IN CONST EFI_GUID *Guid,
261 IN UINTN TokenNumber
262 );
263
264
265
266 /**
267 Retrieves an 64-bit value for a given PCD token.
268
269 Retrieves the 64-bit value of a particular PCD token.
270 If the TokenNumber is invalid or the token space
271 specified by Guid does not exist, the results are
272 unpredictable.
273
274 @param Guid The token space for the token number.
275 @param TokenNumber The PCD token number.
276
277 @return The size 64-bit value for the PCD token.
278
279 **/
280 typedef
281 UINT64
282 (EFIAPI *PCD_PPI_GET_EX_64) (
283 IN CONST EFI_GUID *Guid,
284 IN UINTN TokenNumber
285 );
286
287
288
289 /**
290 Retrieves a pointer to a value for a given PCD token.
291
292 Retrieves the current pointer to the buffer for a PCD token number.
293 Do not make any assumptions about the alignment of the pointer that
294 is returned by this function call. If the TokenNumber is invalid,
295 the results are unpredictable.
296
297 @param Guid The token space for the token number.
298 @param TokenNumber The PCD token number.
299
300 @return The pointer to the buffer to be retrived.
301
302 **/
303 typedef
304 VOID *
305 (EFIAPI *PCD_PPI_GET_EX_POINTER) (
306 IN CONST EFI_GUID *Guid,
307 IN UINTN TokenNumber
308 );
309
310
311
312 /**
313 Retrieves an Boolean value for a given PCD token.
314
315 Retrieves the Boolean value of a particular PCD token.
316 If the TokenNumber is invalid or the token space
317 specified by Guid does not exist, the results are
318 unpredictable.
319
320 @param Guid The token space for the token number.
321 @param TokenNumber The PCD token number.
322
323 @return The size Boolean value for the PCD token.
324
325 **/
326 typedef
327 BOOLEAN
328 (EFIAPI *PCD_PPI_GET_EX_BOOLEAN) (
329 IN CONST EFI_GUID *Guid,
330 IN UINTN TokenNumber
331 );
332
333
334
335 /**
336 Retrieves the size of the value for a given PCD token.
337
338 Retrieves the current size of a particular PCD token.
339 If the TokenNumber is invalid, the results are unpredictable.
340
341 @param Guid The token space for the token number.
342 @param TokenNumber The PCD token number.
343
344 @return The size of the value for the PCD token.
345
346 **/
347 typedef
348 UINTN
349 (EFIAPI *PCD_PPI_GET_EX_SIZE) (
350 IN CONST EFI_GUID *Guid,
351 IN UINTN TokenNumber
352 );
353
354
355
356 /**
357 Sets an 8-bit value for a given PCD token.
358
359 When the PCD service sets a value, it will check to ensure that the
360 size of the value being set is compatible with the Token's existing definition.
361 If it is not, an error will be returned.
362
363 @param TokenNumber The PCD token number.
364 @param Value The value to set for the PCD token.
365
366 @retval EFI_SUCCESS Procedure returned successfully.
367 @retval EFI_INVALID_PARAMETER The PCD service determined that the size of the data
368 being set was incompatible with a call to this function.
369 Use GetSize() to retrieve the size of the target data.
370 @retval EFI_NOT_FOUND The PCD service could not find the requested token number.
371
372 **/
373 typedef
374 EFI_STATUS
375 (EFIAPI *PCD_PPI_SET8) (
376 IN UINTN TokenNumber,
377 IN UINT8 Value
378 );
379
380
381
382 /**
383 Sets an 16-bit value for a given PCD token.
384
385 When the PCD service sets a value, it will check to ensure that the
386 size of the value being set is compatible with the Token's existing definition.
387 If it is not, an error will be returned.
388
389 @param TokenNumber The PCD token number.
390 @param Value The value to set for the PCD token.
391
392 @retval EFI_SUCCESS Procedure returned successfully.
393 @retval EFI_INVALID_PARAMETER The PCD service determined that the size of the data
394 being set was incompatible with a call to this function.
395 Use GetSize() to retrieve the size of the target data.
396 @retval EFI_NOT_FOUND The PCD service could not find the requested token number.
397
398 **/
399 typedef
400 EFI_STATUS
401 (EFIAPI *PCD_PPI_SET16) (
402 IN UINTN TokenNumber,
403 IN UINT16 Value
404 );
405
406
407
408 /**
409 Sets an 32-bit value for a given PCD token.
410
411 When the PCD service sets a value, it will check to ensure that the
412 size of the value being set is compatible with the Token's existing definition.
413 If it is not, an error will be returned.
414
415 @param TokenNumber The PCD token number.
416 @param Value The value to set for the PCD token.
417
418 @retval EFI_SUCCESS Procedure returned successfully.
419 @retval EFI_INVALID_PARAMETER The PCD service determined that the size of the data
420 being set was incompatible with a call to this function.
421 Use GetSize() to retrieve the size of the target data.
422 @retval EFI_NOT_FOUND The PCD service could not find the requested token number.
423
424 **/
425 typedef
426 EFI_STATUS
427 (EFIAPI *PCD_PPI_SET32) (
428 IN UINTN TokenNumber,
429 IN UINT32 Value
430 );
431
432
433
434 /**
435 Sets an 64-bit value for a given PCD token.
436
437 When the PCD service sets a value, it will check to ensure that the
438 size of the value being set is compatible with the Token's existing definition.
439 If it is not, an error will be returned.
440
441 @param TokenNumber The PCD token number.
442 @param Value The value to set for the PCD token.
443
444 @retval EFI_SUCCESS Procedure returned successfully.
445 @retval EFI_INVALID_PARAMETER The PCD service determined that the size of the data
446 being set was incompatible with a call to this function.
447 Use GetSize() to retrieve the size of the target data.
448 @retval EFI_NOT_FOUND The PCD service could not find the requested token number.
449
450 **/
451 typedef
452 EFI_STATUS
453 (EFIAPI *PCD_PPI_SET64) (
454 IN UINTN TokenNumber,
455 IN UINT64 Value
456 );
457
458
459
460
461 /**
462 Sets a value of a specified size for a given PCD token.
463
464 When the PCD service sets a value, it will check to ensure that the
465 size of the value being set is compatible with the Token's existing definition.
466 If it is not, an error will be returned.
467
468 @param TokenNumber The PCD token number.
469 @param SizeOfBuffer A pointer to the length of the value being set for the PCD token.
470 On input, if the SizeOfValue is greater than the maximum size supported
471 for this TokenNumber then the output value of SizeOfValue will reflect
472 the maximum size supported for this TokenNumber.
473 @param Buffer The buffer to set for the PCD token.
474
475 @retval EFI_SUCCESS Procedure returned successfully.
476 @retval EFI_INVALID_PARAMETER The PCD service determined that the size of the data
477 being set was incompatible with a call to this function.
478 Use GetSize() to retrieve the size of the target data.
479 @retval EFI_NOT_FOUND The PCD service could not find the requested token number.
480
481 **/
482 typedef
483 EFI_STATUS
484 (EFIAPI *PCD_PPI_SET_POINTER) (
485 IN UINTN TokenNumber,
486 IN OUT UINTN *SizeOfBuffer,
487 IN VOID *Buffer
488 );
489
490
491
492 /**
493 Sets an Boolean value for a given PCD token.
494
495 When the PCD service sets a value, it will check to ensure that the
496 size of the value being set is compatible with the Token's existing definition.
497 If it is not, an error will be returned.
498
499 @param TokenNumber The PCD token number.
500 @param Value The value to set for the PCD token.
501
502 @retval EFI_SUCCESS Procedure returned successfully.
503 @retval EFI_INVALID_PARAMETER The PCD service determined that the size of the data
504 being set was incompatible with a call to this function.
505 Use GetSize() to retrieve the size of the target data.
506 @retval EFI_NOT_FOUND The PCD service could not find the requested token number.
507
508 **/
509 typedef
510 EFI_STATUS
511 (EFIAPI *PCD_PPI_SET_BOOLEAN) (
512 IN UINTN TokenNumber,
513 IN BOOLEAN Value
514 );
515
516
517
518 /**
519 Sets an 8-bit value for a given PCD token.
520
521 When the PCD service sets a value, it will check to ensure that the
522 size of the value being set is compatible with the Token's existing definition.
523 If it is not, an error will be returned.
524
525 @param Guid The 128-bit unique value that designates the namespace from which to extract the value.
526 @param TokenNumber The PCD token number.
527 @param Value The value to set for the PCD token.
528
529 @retval EFI_SUCCESS Procedure returned successfully.
530 @retval EFI_INVALID_PARAMETER The PCD service determined that the size of the data
531 being set was incompatible with a call to this function.
532 Use GetSize() to retrieve the size of the target data.
533 @retval EFI_NOT_FOUND The PCD service could not find the requested token number.
534
535 **/
536 typedef
537 EFI_STATUS
538 (EFIAPI *PCD_PPI_SET_EX_8) (
539 IN CONST EFI_GUID *Guid,
540 IN UINTN TokenNumber,
541 IN UINT8 Value
542 );
543
544
545
546 /**
547 Sets an 16-bit value for a given PCD token.
548
549 When the PCD service sets a value, it will check to ensure that the
550 size of the value being set is compatible with the Token's existing definition.
551 If it is not, an error will be returned.
552
553 @param Guid The 128-bit unique value that designates the namespace from which to extract the value.
554 @param TokenNumber The PCD token number.
555 @param Value The value to set for the PCD token.
556
557 @retval EFI_SUCCESS Procedure returned successfully.
558 @retval EFI_INVALID_PARAMETER The PCD service determined that the size of the data
559 being set was incompatible with a call to this function.
560 Use GetSize() to retrieve the size of the target data.
561 @retval EFI_NOT_FOUND The PCD service could not find the requested token number.
562
563 **/
564 typedef
565 EFI_STATUS
566 (EFIAPI *PCD_PPI_SET_EX_16) (
567 IN CONST EFI_GUID *Guid,
568 IN UINTN TokenNumber,
569 IN UINT16 Value
570 );
571
572
573
574 /**
575 Sets an 32-bit value for a given PCD token.
576
577 When the PCD service sets a value, it will check to ensure that the
578 size of the value being set is compatible with the Token's existing definition.
579 If it is not, an error will be returned.
580
581 @param Guid The 128-bit unique value that designates the namespace from which to extract the value.
582 @param TokenNumber The PCD token number.
583 @param Value The value to set for the PCD token.
584
585 @retval EFI_SUCCESS Procedure returned successfully.
586 @retval EFI_INVALID_PARAMETER The PCD service determined that the size of the data
587 being set was incompatible with a call to this function.
588 Use GetSize() to retrieve the size of the target data.
589 @retval EFI_NOT_FOUND The PCD service could not find the requested token number.
590
591 **/
592 typedef
593 EFI_STATUS
594 (EFIAPI *PCD_PPI_SET_EX_32) (
595 IN CONST EFI_GUID *Guid,
596 IN UINTN TokenNumber,
597 IN UINT32 Value
598 );
599
600
601
602 /**
603 Sets an 64-bit value for a given PCD token.
604
605 When the PCD service sets a value, it will check to ensure that the
606 size of the value being set is compatible with the Token's existing definition.
607 If it is not, an error will be returned.
608
609 @param Guid The 128-bit unique value that designates the namespace from which to extract the value.
610 @param TokenNumber The PCD token number.
611 @param Value The value to set for the PCD token.
612
613 @retval EFI_SUCCESS Procedure returned successfully.
614 @retval EFI_INVALID_PARAMETER The PCD service determined that the size of the data
615 being set was incompatible with a call to this function.
616 Use GetSize() to retrieve the size of the target data.
617 @retval EFI_NOT_FOUND The PCD service could not find the requested token number.
618
619 **/
620 typedef
621 EFI_STATUS
622 (EFIAPI *PCD_PPI_SET_EX_64) (
623 IN CONST EFI_GUID *Guid,
624 IN UINTN TokenNumber,
625 IN UINT64 Value
626 );
627
628
629
630 /**
631 Sets a value of a specified size for a given PCD token.
632
633 When the PCD service sets a value, it will check to ensure that the
634 size of the value being set is compatible with the Token's existing definition.
635 If it is not, an error will be returned.
636
637 @param Guid The 128-bit unique value that designates the namespace from which to extract the value.
638 @param TokenNumber The PCD token number.
639 @param SizeOfBuffer A pointer to the length of the value being set for the PCD token.
640 On input, if the SizeOfValue is greater than the maximum size supported
641 for this TokenNumber then the output value of SizeOfValue will reflect
642 the maximum size supported for this TokenNumber.
643 @param Buffer The buffer to set for the PCD token.
644
645 @retval EFI_SUCCESS Procedure returned successfully.
646 @retval EFI_INVALID_PARAMETER The PCD service determined that the size of the data
647 being set was incompatible with a call to this function.
648 Use GetSize() to retrieve the size of the target data.
649 @retval EFI_NOT_FOUND The PCD service could not find the requested token number.
650
651 **/
652 typedef
653 EFI_STATUS
654 (EFIAPI *PCD_PPI_SET_EX_POINTER) (
655 IN CONST EFI_GUID *Guid,
656 IN UINTN TokenNumber,
657 IN OUT UINTN *SizeOfBuffer,
658 IN VOID *Buffer
659 );
660
661
662
663 /**
664 Sets an Boolean value for a given PCD token.
665
666 When the PCD service sets a value, it will check to ensure that the
667 size of the value being set is compatible with the Token's existing definition.
668 If it is not, an error will be returned.
669
670 @param Guid The 128-bit unique value that designates the namespace from which to extract the value.
671 @param TokenNumber The PCD token number.
672 @param Value The value to set for the PCD token.
673
674 @retval EFI_SUCCESS Procedure returned successfully.
675 @retval EFI_INVALID_PARAMETER The PCD service determined that the size of the data
676 being set was incompatible with a call to this function.
677 Use GetSize() to retrieve the size of the target data.
678 @retval EFI_NOT_FOUND The PCD service could not find the requested token number.
679
680 **/
681 typedef
682 EFI_STATUS
683 (EFIAPI *PCD_PPI_SET_EX_BOOLEAN) (
684 IN CONST EFI_GUID *Guid,
685 IN UINTN TokenNumber,
686 IN BOOLEAN Value
687 );
688
689
690
691 /**
692 Callback on SET function prototype definition.
693
694 @param CallBackGuid The PCD token GUID being set.
695 @param CallBackToken The PCD token number being set.
696 @param TokenData A pointer to the token data being set.
697 @param TokenDataSize The size, in bytes, of the data being set.
698
699 @retval VOID
700
701 **/
702 typedef
703 VOID
704 (EFIAPI *PCD_PPI_CALLBACK) (
705 IN CONST EFI_GUID *CallBackGuid, OPTIONAL
706 IN UINTN CallBackToken,
707 IN OUT VOID *TokenData,
708 IN UINTN TokenDataSize
709 );
710
711
712
713 /**
714 Specifies a function to be called anytime the value of a designated token is changed.
715
716 @param TokenNumber The PCD token number.
717 @param Guid The 128-bit unique value that designates the namespace from which to extract the value.
718 @param CallBackFunction The function prototype called when the value associated with the CallBackToken is set.
719
720 @retval EFI_SUCCESS The PCD service has successfully established a call event
721 for the CallBackToken requested.
722 @retval EFI_NOT_FOUND The PCD service could not find the referenced token number.
723
724 **/
725 typedef
726 EFI_STATUS
727 (EFIAPI *PCD_PPI_CALLBACK_ONSET) (
728 IN UINTN TokenNumber,
729 IN CONST EFI_GUID *Guid, OPTIONAL
730 IN PCD_PPI_CALLBACK CallBackFunction
731 );
732
733
734
735 /**
736 Cancels a previously set callback function for a particular PCD token number.
737
738 @param TokenNumber The PCD token number.
739 @param Guid The 128-bit unique value that designates the namespace from which to extract the value.
740 @param CallBackFunction The function prototype called when the value associated with the CallBackToken is set.
741
742 @retval EFI_SUCCESS The PCD service has successfully established a call event
743 for the CallBackToken requested.
744 @retval EFI_NOT_FOUND The PCD service could not find the referenced token number.
745
746 **/
747 typedef
748 EFI_STATUS
749 (EFIAPI *PCD_PPI_CANCEL_CALLBACK) (
750 IN UINTN TokenNumber,
751 IN CONST EFI_GUID *Guid, OPTIONAL
752 IN PCD_PPI_CALLBACK CallBackFunction
753 );
754
755
756
757 /**
758 Retrieves the next valid PCD token for a given namespace.
759
760 @param Guid The 128-bit unique value that designates the namespace from which to extract the value.
761 @param TokenNumber A pointer to the PCD token number to use to find the subsequent token number.
762 To retrieve the "first" token, have the pointer reference a TokenNumber value of 0.
763
764 @retval EFI_SUCCESS The PCD service retrieved the value requested.
765 @retval EFI_NOT_FOUND The PCD service could not find data from the requested token number.
766
767 **/
768 typedef
769 EFI_STATUS
770 (EFIAPI *PCD_PPI_GET_NEXT_TOKEN) (
771 IN CONST EFI_GUID *Guid, OPTIONAL
772 IN OUT UINTN *TokenNumber
773 );
774
775
776
777 /**
778 Retrieves the next valid PCD token namespace for a given namespace.
779
780 @param Guid An indirect pointer to EFI_GUID. On input it designates a known
781 token namespace from which the search will start. On output,
782 it designates the next valid token namespace on the platform.
783 If *Guid is NULL, then the GUID of the first token space of the current platform is returned.
784 If this input token namespace is the last tokenspace on the platform,
785 *Guid will be assigned to NULL and the function return EFI_SUCCESS.
786 If the search cannot locate the input token namespace, an error is returned and
787 the value of *Guid is undefined.
788
789 @retval EFI_SUCCESS The PCD service retrieved the value requested.
790 @retval EFI_NOT_FOUND The PCD service could not find the input token namespace.
791
792 **/
793 typedef
794 EFI_STATUS
795 (EFIAPI *PCD_PPI_GET_NEXT_TOKENSPACE) (
796 IN OUT CONST EFI_GUID **Guid
797 );
798
799
800
801 //
802 // Interface structure for the PCD PPI
803 //
804 typedef struct {
805 PCD_PPI_SET_SKU SetSku;
806
807 PCD_PPI_GET8 Get8;
808 PCD_PPI_GET16 Get16;
809 PCD_PPI_GET32 Get32;
810 PCD_PPI_GET64 Get64;
811 PCD_PPI_GET_POINTER GetPtr;
812 PCD_PPI_GET_BOOLEAN GetBool;
813 PCD_PPI_GET_SIZE GetSize;
814
815 PCD_PPI_GET_EX_8 Get8Ex;
816 PCD_PPI_GET_EX_16 Get16Ex;
817 PCD_PPI_GET_EX_32 Get32Ex;
818 PCD_PPI_GET_EX_64 Get64Ex;
819 PCD_PPI_GET_EX_POINTER GetPtrEx;
820 PCD_PPI_GET_EX_BOOLEAN GetBoolEx;
821 PCD_PPI_GET_EX_SIZE GetSizeEx;
822
823 PCD_PPI_SET8 Set8;
824 PCD_PPI_SET16 Set16;
825 PCD_PPI_SET32 Set32;
826 PCD_PPI_SET64 Set64;
827 PCD_PPI_SET_POINTER SetPtr;
828 PCD_PPI_SET_BOOLEAN SetBool;
829
830 PCD_PPI_SET_EX_8 Set8Ex;
831 PCD_PPI_SET_EX_16 Set16Ex;
832 PCD_PPI_SET_EX_32 Set32Ex;
833 PCD_PPI_SET_EX_64 Set64Ex;
834 PCD_PPI_SET_EX_POINTER SetPtrEx;
835 PCD_PPI_SET_EX_BOOLEAN SetBoolEx;
836
837 PCD_PPI_CALLBACK_ONSET CallbackOnSet;
838 PCD_PPI_CANCEL_CALLBACK CancelCallback;
839 PCD_PPI_GET_NEXT_TOKEN GetNextToken;
840 PCD_PPI_GET_NEXT_TOKENSPACE GetNextTokenSpace;
841 } PCD_PPI;
842
843
844 #endif