]> git.proxmox.com Git - mirror_edk2.git/blobdiff - MdePkg/Include/Ppi/Pcd.h
Synchronize PCD_Infrastructure 0.55 with source code.
[mirror_edk2.git] / MdePkg / Include / Ppi / Pcd.h
index 73f027b5e7c7d188f971a001bcaa170203ac9db9..def6b46e0bb5701a75b4f3613e0c623e4d833d07 100644 (file)
@@ -750,18 +750,24 @@ EFI_STATUS
 \r
 \r
 /**\r
-  Retrieves the next valid PCD token for a given namespace.\r
+  Retrieves the next valid token number in a given namespace.  \r
   \r
-  If the input token namespace or token number does not exist on the platform, an error is \r
-  returned and the value of *TokenNumber is undefined. To retrieve the "first" token, \r
-  have the pointer reference a TokenNumber value of 0. \r
-  If the input token number is 0 and there is no valid token number for this token namespace,\r
-  *TokenNumber will be assigned to 0 and the function return EFI_SUCCESS. \r
-  If the token number is the last valid token number, *TokenNumber will be assigned to 0 and\r
-  the function return EFI_SUCCESS.\r
+  This is useful since the PCD infrastructure contains a sparse list of token numbers, \r
+  and one cannot a priori know what token numbers are valid in the database. \r
+  \r
+  If TokenNumber is 0 and Guid is not NULL, then the first token from the token space specified by Guid is returned.  \r
+  If TokenNumber is not 0 and Guid is not NULL, then the next token in the token space specified by Guid is returned.  \r
+  If TokenNumber is 0 and Guid is NULL, then the first token in the default token space is returned.  \r
+  If TokenNumber is not 0 and Guid is NULL, then the next token in the default token space is returned.  \r
+  The token numbers in the default token space may not be related to token numbers in token spaces that are named by Guid.  \r
+  If the next token number can be retrieved, then it is returned in TokenNumber, and EFI_SUCCESS is returned.  \r
+  If TokenNumber represents the last token number in the token space specified by Guid, then EFI_NOT_FOUND is returned.  \r
+  If TokenNumber is not present in the token space specified by Guid, then EFI_NOT_FOUND is returned.\r
 \r
 \r
-  @param[in]       Guid        The 128-bit unique value that designates the namespace from which to extract the value.\r
+  @param[in]       Guid        The 128-bit unique value that designates the namespace from which to extract the value.  \r
+                               This is an optional parameter that may be NULL.  If this parameter is NULL, then a request \r
+                               is being made to retrieve tokens from the default token space.\r
   @param[in, out]  TokenNumber A pointer to the PCD token number to use to find the subsequent token number.\r
                    \r
   @retval EFI_SUCCESS   The PCD service has retrieved the next valid token number. \r