]> git.proxmox.com Git - mirror_edk2.git/blobdiff - MdePkg/Include/Library/PcdLib.h
Put the our jar files before the system's CLASSPATH
[mirror_edk2.git] / MdePkg / Include / Library / PcdLib.h
index 37d435596e0327be2d09a4810f7aa810f21ca7f1..038443b993c9dcbe0a30a92449fc2c80edc2c1ef 100644 (file)
@@ -26,7 +26,7 @@ Module Name: PcdLib.h
 //\r
 // Feature Flag is in the form of a global constant\r
 //\r
-#define FeaturePcdGet(TokenName)            _PCD_VALUE_##TokenName\r
+#define FeaturePcdGet(TokenName)            _PCD_GET_MODE_BOOL_##TokenName\r
 \r
 \r
 //\r
@@ -39,9 +39,6 @@ Module Name: PcdLib.h
 #define FixedPcdGetBool(TokenName)          _PCD_VALUE_##TokenName\r
 \r
 \r
-//\r
-// BugBug: This works for strings, but not constants.\r
-//\r
 #define FixedPcdGetPtr(TokenName)           ((VOID *)_PCD_VALUE_##TokenName)\r
 \r
 \r
@@ -61,7 +58,12 @@ Module Name: PcdLib.h
 #define PatchPcdSet64(TokenName, Value)     (_gPcd_BinaryPatch_##TokenName = (Value))\r
 #define PatchPcdSetBool(TokenName, Value)   (_gPcd_BinaryPatch_##TokenName = (Value))\r
 #define PatchPcdSetPtr(TokenName, Size, Buffer) \\r
-                                            CopyMem (_gPcd_BinaryPatch_##TokenName, (Buffer), (Size))\r
+                                            LibPatchPcdSetPtr (                        \\r
+                                              _gPcd_BinaryPatch_##TokenName,           \\r
+                                              (UINTN)_PCD_PATCHABLE_##TokenName##_SIZE, \\r
+                                              (Size),                                  \\r
+                                              (Buffer)                                 \\r
+                                              )\r
 \r
 //\r
 // Dynamic is via the protocol with only the TokenNumber as argument\r
@@ -627,9 +629,17 @@ LibPcdSetExBool (
   If Guid is NULL, then the default token space is used. \r
   If NotificationFunction is NULL, then ASSERT().\r
 \r
+  This notification function serves two purposes. Firstly, it notifies the module which \r
+  did the registration that the value of this PCD token has been set. Secondly, \r
+  it provides a mechanism for the module which did the registration to intercept \r
+  the set operation and override the value been set if necessary. After the invocation \r
+  of the callback function, TokenData will be used by PCD service PEIM or driver to \r
+  modify the internal data in PCD database. \r
+\r
+\r
   @param[in]  CallBackGuid The PCD token GUID being set.\r
   @param[in]  CallBackToken The PCD token number being set.\r
-  @param[in]  TokenData A pointer to the token data being set.\r
+  @param[in, out]  TokenData A pointer to the token data being set.\r
   @param[in]  TokenDataSize The size, in bytes, of the data being set.\r
 \r
   @retval VOID\r