]> git.proxmox.com Git - mirror_edk2.git/blob - MdePkg/Include/Protocol/PiPcdInfo.h
MdePkg: Replace BSD License with BSD+Patent License
[mirror_edk2.git] / MdePkg / Include / Protocol / PiPcdInfo.h
1 /** @file
2 Platform Configuration Database (PCD) Info Protocol defined in PI 1.2.1 Vol3.
3
4 The protocol that provides additional information about items that reside in the PCD database.
5
6 Copyright (c) 2013, Intel Corporation. All rights reserved.<BR>
7 SPDX-License-Identifier: BSD-2-Clause-Patent
8
9 @par Revision Reference:
10 PI Version 1.2.1 Vol 3.
11 **/
12
13 #ifndef __PI_PCD_INFO_H__
14 #define __PI_PCD_INFO_H__
15
16 extern EFI_GUID gEfiGetPcdInfoProtocolGuid;
17
18 #define EFI_GET_PCD_INFO_PROTOCOL_GUID \
19 { 0xfd0f4478, 0xefd, 0x461d, { 0xba, 0x2d, 0xe5, 0x8c, 0x45, 0xfd, 0x5f, 0x5e } }
20
21 ///
22 /// The forward declaration for EFI_GET_PCD_INFO_PROTOCOL.
23 ///
24 typedef struct _EFI_GET_PCD_INFO_PROTOCOL EFI_GET_PCD_INFO_PROTOCOL;
25
26 /**
27 Retrieve additional information associated with a PCD token.
28
29 This includes information such as the type of value the TokenNumber is associated with as well as possible
30 human readable name that is associated with the token.
31
32 @param[in] Guid The 128-bit unique value that designates the namespace from which to extract the value.
33 @param[in] TokenNumber The PCD token number.
34 @param[out] PcdInfo The returned information associated with the requested TokenNumber.
35
36 @retval EFI_SUCCESS The PCD information was returned successfully
37 @retval EFI_NOT_FOUND The PCD service could not find the requested token number.
38 **/
39 typedef
40 EFI_STATUS
41 (EFIAPI *EFI_GET_PCD_INFO_PROTOCOL_GET_INFO) (
42 IN CONST EFI_GUID *Guid,
43 IN UINTN TokenNumber,
44 OUT EFI_PCD_INFO *PcdInfo
45 );
46
47 /**
48 Retrieve the currently set SKU Id.
49
50 @return The currently set SKU Id. If the platform has not set at a SKU Id, then the
51 default SKU Id value of 0 is returned. If the platform has set a SKU Id, then the currently set SKU
52 Id is returned.
53 **/
54 typedef
55 UINTN
56 (EFIAPI *EFI_GET_PCD_INFO_PROTOCOL_GET_SKU) (
57 VOID
58 );
59
60 ///
61 /// Callers to this protocol must be at a TPL_APPLICATION task priority level.
62 /// This is the PCD service to use when querying for some additional data that can be contained in the
63 /// PCD database.
64 ///
65 struct _EFI_GET_PCD_INFO_PROTOCOL {
66 ///
67 /// Retrieve additional information associated with a PCD.
68 ///
69 EFI_GET_PCD_INFO_PROTOCOL_GET_INFO GetInfo;
70 ///
71 /// Retrieve the currently set SKU Id.
72 ///
73 EFI_GET_PCD_INFO_PROTOCOL_GET_SKU GetSku;
74 };
75
76 #endif
77