3 PCD PPI

Summary

A platform database that contains a variety of current platform settings or directives that can be accessed by a driver or application.

GUID

#define PCD_PPI_GUID \
  { 0x6e81c58, 0x4ad7, 0x44bc,{ 0x83, 0x90, 0xf1, 0x2, 0x65, 0xf7, 0x24, 0x80 }}

Protocol Interface Structure

typedef struct {
  PCD_PPI_SET_SKU              SetSku;

  PCD_PPI_GET8                 Get8;
  PCD_PPI_GET16                Get16;
  PCD_PPI_GET32                Get32;
  PCD_PPI_GET64                Get64;
  PCD_PPI_GET_POINTER          GetPtr;
  PCD_PPI_GET_BOOLEAN          GetBool;
  PCD_PPI_GET_SIZE             GetSize;

  PCD_PPI_GET_EX_8             Get8Ex;
  PCD_PPI_GET_EX_16            Get16Ex;
  PCD_PPI_GET_EX_32            Get32Ex;
  PCD_PPI_GET_EX_64            Get64Ex;
  PCD_PPI_GET_EX_POINTER       GetPtrEx;
  PCD_PPI_GET_EX_BOOLEAN       GetBoolEx;
  PCD_PPI_GET_EX_SIZE          GetSizeEx;

  PCD_PPI_SET8                 Set8;
  PCD_PPI_SET16                Set16;
  PCD_PPI_SET32                Set32;
  PCD_PPI_SET64                Set64;
  PCD_PPI_SET_POINTER          SetPtr;
  PCD_PPI_SET_BOOLEAN          SetBool;

  PCD_PPI_SET_EX_8             Set8Ex;
  PCD_PPI_SET_EX_16            Set16Ex;
  PCD_PPI_SET_EX_32            Set32Ex;
  PCD_PPI_SET_EX_64            Set64Ex;
  PCD_PPI_SET_EX_POINTER       SetPtrEx;
  PCD_PPI_SET_EX_BOOLEAN       SetBoolEx;

  PCD_PPI_CALLBACK_ON_SET      CallbackOnSet;
  PCD_PPI_CANCEL_CALLBACK      CancelCallback;
  PCD_PPI_GET_NEXT_TOKEN       GetNextToken;
  PCD_PPI_GET_NEXT_TOKENSPACE  GetNextTokenSpace;
} PCD_PPI;

Parameters

SetSku

Establish a current SKU value for the PCD service to use for subsequent data Get/Set requests.

Get8

Retrieve an 8-bit value from the PCD service using the standard platform namespace.

Get16

Retrieve a 16-bit value from the PCD service using the standard platform namespace.

Get32

Retrieve a 32-bit value from the PCD service using the standard platform namespace.

Get64

Retrieve a 64-bit value from the PCD service using the standard platform namespace.

GetPtr

Retrieve a pointer to a value from the PCD service using the standard platform namespace. Can be used to retrieve an array of bytes that may represent a data structure, ASCII string, or Unicode string

GetBool

Retrieve a Boolean value from the PCD service using the standard platform namespace.

GetSize

Retrieve the size of a particular PCD Token value using the standard platform namespace.

Get8Ex

Retrieve an 8-bit value from the PCD service using a GUIDed token namespace.

Get16Ex

Retrieve a 16-bit value from the PCD service using a GUIDed token namespace.

Get32Ex

Retrieve a 32-bit value from the PCD service using a GUIDed token namespace.

Get64Ex

Retrieve a 64-bit value from the PCD service using a GUIDed token namespace.

GetPtrEx

Retrieve a pointer to a value from the PCD service using a GUIDed token namespace. Can be used to retrieve an array of bytes that represents a data structure, ASCII string, or Unicode string

GetBoolEx

Retrieve a Boolean value from the PCD service using a GUIDed token namespace.

GetSizeEx

Retrieve the size of a particular PCD Token value using a GUIDed token namespace.

Set8

Set an 8-bit value in the PCD service using the standard platform namespace.

Set16

Set an 8-bit value in the PCD service using the standard platform namespace.

Set32

Set a 32-bit value in the PCD service using the standard platform namespace.

Set64

Set a 64-bit value in the PCD service using the standard platform namespace.

SetPtr

Set a pointer to a value in the PCD service using the standard platform namespace. Can be used to set an array of bytes that represents a data structure, ASCII string, or Unicode string

SetBool

Set a Boolean value in the PCD service using the standard platform namespace.

Set8Ex

Set an 8-bit value in the PCD service using a GUIDed token namespace.

Set16Ex

Set a 16-bit value in the PCD service using a GUIDed token namespace.

Set32Ex

Set a 32-bit value in the PCD service using a GUIDed token namespace.

Set64Ex

Set a 64-bit value in the PCD service using a GUIDed token namespace.

SetPtrEx

Set a pointer to a value in the PCD service using a GUIDed token namespace. Can be used to set an array of bytes that represents a data structure, ASCII string, or Unicode string

SetBoolEx

Set a Boolean value in the PCD service using a GUIDed token namespace.

CallBackOnSet

Establish a notification when a particular PCD Token value is set.

CancelCallBackOnSet

Cancel a previously set notification for a particular PCD Token value.

GetNextToken

Retrieve the next token number that is contained in the PCD name -space.

GetNextTokenSpace

Retrieves the next valid PCD token namespace for a given namespace.

Description

This is the base PCD service API that provides an abstraction for accessing configuration content in the platform. It is a seamless mechanism for extracting information regardless of where the information is stored (such as in VPD, in an EFI Variable, or PCD FFS file).

This PPI provides access to data through size-granular APIs and provides a mechanism for a firmware component to monitor specific settings and be alerted when a setting is changed.