28 #ifndef INCLUDED_NVGPH_H
29 #define INCLUDED_NVGPH_H
32 #include <crypto_data.h>
34 #define CMAC_AES_HASH_LENGTH 4
35 #define NVGPH_MAX_COPIES 64
36 #define NVGPH_COPIES_OFFSET 2048
52 #define MAX_BOOTLOADERS 2
53 #define GPH_CUSTOMER_DATA_SIZE 424
201 NvU32 *NumInstances);
258 NvS8 *FileName, NvU32 Size);
Valid BLs in the structure.
QbDriver
Defines Quickboot device driver types.
PartitionTable Start location.
NvError NvGphInit(QbDriver DeviceId, NvU32 DevInstance, NvU64 Offset, NvU32 PartId)
Initializes GPH.
NvGPH_ValidationEnum ValidationType
Specifies AES_CMAC for validation.
void NvPrintGPH(void)
Prints GPH information to console.
NvU32 Unused[3]
To make start of Sign-section align to 16 byte.
NvU32 Version
Specifies a version number for the BL.
NvGPH_ValidationEnum
Specifies the type of Validataion to be used.
NvGPHObjectSignature Signature
Specifies the AES-CMAC MAC for the rest of the GPH structure.
Generic Partition Header.
union NvGPHObjectSignatureRec::@12 SignType
Stores information needed to locate and verify a boot loader.
NvU32 PartitionTableStart
Specifies Guest Partition Table Start.
NvError NvGPHGetData(NvGPHDataType DataType, NvU32 Size, NvU32 Instance, void *Data)
Gets the contents of the GPH element.
NvU8 Reserved[48]
Reserved for future use.
struct NvGPHBLInfoRec NvGuestBLInfo
Stores information needed to locate and verify a boot loader.
NvError NvGPHSetData(NvGPHDataType DataType, NvU32 Size, NvU32 Instance, void *Data)
Sets the contents of the GPH element.
NvGPHDataType
Data elements of the NvGPH which can be queried and set via the NvGPH set/get API.
NvU32 Start
Specifies the start offset from start of the Guest partition.
struct NvGPHRec NvGPH
Generic Partition Header.
struct NvGPHObjectSignatureRec NvGPHObjectSignature
NvU8 SHA256[SHA256_DIGEST_SIZE]
Specifies the SHA256 signature for the rest of the BCT structure.
NvError NvGphWriteGphApp(NvS8 *FileName, NvU32 Size)
Writes the GPH to a file.
#define GPH_CUSTOMER_DATA_SIZE
NvU32 BootLoadersUsed
Specifies the number of BLs described in the BootLoader table.
NvGuestBLInfo BootLoader[MAX_BOOTLOADERS]
Specifies the information needed to locate and validate each BL.
NvU32 LoadAddress
Specifies the starting address of the memory region into which the BL will be loaded.
#define CMAC_AES_HASH_LENGTH
NvU32 EntryPoint
Specifies the entry point address in the loaded BL image.
NvU32 Hash[CMAC_AES_HASH_LENGTH]
Specifies the AES-CMAC signature for the rest of the BCT structure.
NvGPHObjectSignature UnUsed1
Unused field kept for backword compatibility.
Valdation/Encryption type for the GPH and BL.
NvError NvGPHGetDataSize(NvGPHDataType DataType, NvU32 *Size, NvU32 *NumInstances)
Gets data size of GPH element.
void NvGphDeinit(void)
Deinitializes GPH.
NvU8 CustomerData[GPH_CUSTOMER_DATA_SIZE]
Customer Data.