2006-05-24 10:11:21 +02:00
|
|
|
//
|
|
|
|
// The following definition will be generated by build tool
|
|
|
|
//
|
|
|
|
|
|
|
|
//
|
|
|
|
// Common definitions
|
|
|
|
//
|
2006-06-07 14:31:33 +02:00
|
|
|
typedef UINT8 SKU_ID;
|
|
|
|
|
2006-07-06 08:10:20 +02:00
|
|
|
#define PCD_TYPE_SHIFT 28
|
2006-05-24 10:11:21 +02:00
|
|
|
|
2006-07-06 08:10:20 +02:00
|
|
|
#define PCD_TYPE_DATA (0x0 << PCD_TYPE_SHIFT)
|
|
|
|
#define PCD_TYPE_HII (0x8 << PCD_TYPE_SHIFT)
|
|
|
|
#define PCD_TYPE_VPD (0x4 << PCD_TYPE_SHIFT)
|
|
|
|
#define PCD_TYPE_SKU_ENABLED (0x2 << PCD_TYPE_SHIFT)
|
|
|
|
#define PCD_TYPE_STRING (0x1 << PCD_TYPE_SHIFT)
|
2006-05-24 10:11:21 +02:00
|
|
|
|
2006-07-06 08:10:20 +02:00
|
|
|
#define PCD_TYPE_ALL_SET (PCD_TYPE_DATA | PCD_TYPE_HII | PCD_TYPE_VPD | PCD_TYPE_SKU_ENABLED | PCD_TYPE_STRING)
|
2006-05-24 10:11:21 +02:00
|
|
|
|
2006-07-06 08:10:20 +02:00
|
|
|
#define PCD_DATUM_TYPE_SHIFT 24
|
2006-05-24 10:11:21 +02:00
|
|
|
|
2006-07-06 08:10:20 +02:00
|
|
|
#define PCD_DATUM_TYPE_POINTER (0x0 << PCD_DATUM_TYPE_SHIFT)
|
|
|
|
#define PCD_DATUM_TYPE_UINT8 (0x1 << PCD_DATUM_TYPE_SHIFT)
|
|
|
|
#define PCD_DATUM_TYPE_UINT16 (0x2 << PCD_DATUM_TYPE_SHIFT)
|
|
|
|
#define PCD_DATUM_TYPE_UINT32 (0x4 << PCD_DATUM_TYPE_SHIFT)
|
|
|
|
#define PCD_DATUM_TYPE_UINT64 (0x8 << PCD_DATUM_TYPE_SHIFT)
|
|
|
|
|
|
|
|
#define PCD_DATUM_TYPE_ALL_SET (PCD_DATUM_TYPE_POINTER | \
|
|
|
|
PCD_DATUM_TYPE_UINT8 | \
|
|
|
|
PCD_DATUM_TYPE_UINT16 | \
|
|
|
|
PCD_DATUM_TYPE_UINT32 | \
|
|
|
|
PCD_DATUM_TYPE_UINT64)
|
|
|
|
|
|
|
|
|
|
|
|
#define PCD_DATABASE_OFFSET_MASK (~(PCD_TYPE_ALL_SET | PCD_DATUM_TYPE_ALL_SET))
|
2006-05-24 10:11:21 +02:00
|
|
|
|
|
|
|
typedef struct {
|
|
|
|
UINT32 ExTokenNumber;
|
2006-07-03 17:40:49 +02:00
|
|
|
UINT16 LocalTokenNumber; // PCD Number of this particular platform build
|
2006-05-24 10:11:21 +02:00
|
|
|
UINT16 ExGuidIndex; // Index of GuidTable
|
|
|
|
} DYNAMICEX_MAPPING;
|
|
|
|
|
|
|
|
|
|
|
|
typedef struct {
|
|
|
|
UINT32 SkuDataStartOffset; //We have to use offsetof MACRO as we don't know padding done by compiler
|
|
|
|
UINT32 SkuIdTableOffset; //Offset from the PCD_DB
|
|
|
|
} SKU_HEAD;
|
|
|
|
|
|
|
|
|
|
|
|
typedef struct {
|
2006-06-23 06:30:23 +02:00
|
|
|
UINT16 GuidTableIndex; // Offset in Guid Table in units of GUID.
|
|
|
|
UINT16 StringIndex; // Offset in String Table in units of UINT16.
|
|
|
|
UINT16 Offset; // Offset in Variable
|
|
|
|
UINT16 DefaultValueOffset; // Offset of the Default Value
|
2006-05-24 10:11:21 +02:00
|
|
|
} VARIABLE_HEAD ;
|
|
|
|
|
|
|
|
|
|
|
|
typedef struct {
|
|
|
|
UINT32 Offset;
|
|
|
|
} VPD_HEAD;
|
|
|
|
|
2006-06-23 06:30:23 +02:00
|
|
|
typedef UINT16 STRING_HEAD;
|
|
|
|
|
2006-07-06 08:10:20 +02:00
|
|
|
typedef UINT16 SIZE_INFO;
|
2006-05-24 10:11:21 +02:00
|
|
|
|
2006-06-09 05:10:22 +02:00
|
|
|
#define offsetof(s,m) (UINT32) (UINTN) &(((s *)0)->m)
|
2006-05-24 10:11:21 +02:00
|
|
|
|
|
|
|
|
|
|
|
|