1530d68baSNigel Croxon #ifndef _EFI_PROT_H 2530d68baSNigel Croxon #define _EFI_PROT_H 3530d68baSNigel Croxon 4530d68baSNigel Croxon /*++ 5530d68baSNigel Croxon 6530d68baSNigel Croxon Copyright (c) 1998 Intel Corporation 7530d68baSNigel Croxon 8530d68baSNigel Croxon Module Name: 9530d68baSNigel Croxon 10530d68baSNigel Croxon efiprot.h 11530d68baSNigel Croxon 12530d68baSNigel Croxon Abstract: 13530d68baSNigel Croxon 14530d68baSNigel Croxon EFI Protocols 15530d68baSNigel Croxon 16530d68baSNigel Croxon 17530d68baSNigel Croxon 18530d68baSNigel Croxon Revision History 19530d68baSNigel Croxon 20530d68baSNigel Croxon --*/ 21530d68baSNigel Croxon 22530d68baSNigel Croxon // 23530d68baSNigel Croxon // FPSWA library protocol 24530d68baSNigel Croxon // 25530d68baSNigel Croxon #define FPSWA_PROTOCOL \ 26530d68baSNigel Croxon { 0xc41b6531, 0x97b9, 0x11d3, {0x9a, 0x29, 0x0, 0x90, 0x27, 0x3f, 0xc1, 0x4d} } 27530d68baSNigel Croxon 28530d68baSNigel Croxon // 29530d68baSNigel Croxon // Device Path protocol 30530d68baSNigel Croxon // 31530d68baSNigel Croxon 32530d68baSNigel Croxon #define DEVICE_PATH_PROTOCOL \ 33530d68baSNigel Croxon { 0x9576e91, 0x6d3f, 0x11d2, {0x8e, 0x39, 0x0, 0xa0, 0xc9, 0x69, 0x72, 0x3b} } 34530d68baSNigel Croxon 35530d68baSNigel Croxon 36530d68baSNigel Croxon // 37530d68baSNigel Croxon // Block IO protocol 38530d68baSNigel Croxon // 39530d68baSNigel Croxon 40530d68baSNigel Croxon #define BLOCK_IO_PROTOCOL \ 41530d68baSNigel Croxon { 0x964e5b21, 0x6459, 0x11d2, {0x8e, 0x39, 0x0, 0xa0, 0xc9, 0x69, 0x72, 0x3b} } 42530d68baSNigel Croxon #define EFI_BLOCK_IO_INTERFACE_REVISION 0x00010000 43530d68baSNigel Croxon #define EFI_BLOCK_IO_INTERFACE_REVISION2 0x00020001 44530d68baSNigel Croxon #define EFI_BLOCK_IO_INTERFACE_REVISION3 ((2<<16) | 31) 45530d68baSNigel Croxon 46530d68baSNigel Croxon INTERFACE_DECL(_EFI_BLOCK_IO); 47530d68baSNigel Croxon 48530d68baSNigel Croxon typedef 49530d68baSNigel Croxon EFI_STATUS 50530d68baSNigel Croxon (EFIAPI *EFI_BLOCK_RESET) ( 51530d68baSNigel Croxon IN struct _EFI_BLOCK_IO *This, 52530d68baSNigel Croxon IN BOOLEAN ExtendedVerification 53530d68baSNigel Croxon ); 54530d68baSNigel Croxon 55530d68baSNigel Croxon typedef 56530d68baSNigel Croxon EFI_STATUS 57530d68baSNigel Croxon (EFIAPI *EFI_BLOCK_READ) ( 58530d68baSNigel Croxon IN struct _EFI_BLOCK_IO *This, 59530d68baSNigel Croxon IN UINT32 MediaId, 60530d68baSNigel Croxon IN EFI_LBA LBA, 61530d68baSNigel Croxon IN UINTN BufferSize, 62530d68baSNigel Croxon OUT VOID *Buffer 63530d68baSNigel Croxon ); 64530d68baSNigel Croxon 65530d68baSNigel Croxon 66530d68baSNigel Croxon typedef 67530d68baSNigel Croxon EFI_STATUS 68530d68baSNigel Croxon (EFIAPI *EFI_BLOCK_WRITE) ( 69530d68baSNigel Croxon IN struct _EFI_BLOCK_IO *This, 70530d68baSNigel Croxon IN UINT32 MediaId, 71530d68baSNigel Croxon IN EFI_LBA LBA, 72530d68baSNigel Croxon IN UINTN BufferSize, 73530d68baSNigel Croxon IN VOID *Buffer 74530d68baSNigel Croxon ); 75530d68baSNigel Croxon 76530d68baSNigel Croxon 77530d68baSNigel Croxon typedef 78530d68baSNigel Croxon EFI_STATUS 79530d68baSNigel Croxon (EFIAPI *EFI_BLOCK_FLUSH) ( 80530d68baSNigel Croxon IN struct _EFI_BLOCK_IO *This 81530d68baSNigel Croxon ); 82530d68baSNigel Croxon 83530d68baSNigel Croxon 84530d68baSNigel Croxon 85530d68baSNigel Croxon typedef struct { 86530d68baSNigel Croxon UINT32 MediaId; 87530d68baSNigel Croxon BOOLEAN RemovableMedia; 88530d68baSNigel Croxon BOOLEAN MediaPresent; 89530d68baSNigel Croxon 90530d68baSNigel Croxon BOOLEAN LogicalPartition; 91530d68baSNigel Croxon BOOLEAN ReadOnly; 92530d68baSNigel Croxon BOOLEAN WriteCaching; 93530d68baSNigel Croxon 94530d68baSNigel Croxon UINT32 BlockSize; 95530d68baSNigel Croxon UINT32 IoAlign; 96530d68baSNigel Croxon 97530d68baSNigel Croxon EFI_LBA LastBlock; 98530d68baSNigel Croxon 99530d68baSNigel Croxon /* revision 2 */ 100530d68baSNigel Croxon EFI_LBA LowestAlignedLba; 101530d68baSNigel Croxon UINT32 LogicalBlocksPerPhysicalBlock; 102530d68baSNigel Croxon /* revision 3 */ 103530d68baSNigel Croxon UINT32 OptimalTransferLengthGranularity; 104530d68baSNigel Croxon } EFI_BLOCK_IO_MEDIA; 105530d68baSNigel Croxon 106530d68baSNigel Croxon typedef struct _EFI_BLOCK_IO { 107530d68baSNigel Croxon UINT64 Revision; 108530d68baSNigel Croxon 109530d68baSNigel Croxon EFI_BLOCK_IO_MEDIA *Media; 110530d68baSNigel Croxon 111530d68baSNigel Croxon EFI_BLOCK_RESET Reset; 112530d68baSNigel Croxon EFI_BLOCK_READ ReadBlocks; 113530d68baSNigel Croxon EFI_BLOCK_WRITE WriteBlocks; 114530d68baSNigel Croxon EFI_BLOCK_FLUSH FlushBlocks; 115530d68baSNigel Croxon 116530d68baSNigel Croxon } EFI_BLOCK_IO; 117530d68baSNigel Croxon 118530d68baSNigel Croxon 119530d68baSNigel Croxon 120530d68baSNigel Croxon // 121530d68baSNigel Croxon // Disk Block IO protocol 122530d68baSNigel Croxon // 123530d68baSNigel Croxon 124530d68baSNigel Croxon #define DISK_IO_PROTOCOL \ 125530d68baSNigel Croxon { 0xce345171, 0xba0b, 0x11d2, {0x8e, 0x4f, 0x0, 0xa0, 0xc9, 0x69, 0x72, 0x3b} } 126530d68baSNigel Croxon #define EFI_DISK_IO_INTERFACE_REVISION 0x00010000 127530d68baSNigel Croxon 128530d68baSNigel Croxon INTERFACE_DECL(_EFI_DISK_IO); 129530d68baSNigel Croxon 130530d68baSNigel Croxon typedef 131530d68baSNigel Croxon EFI_STATUS 132530d68baSNigel Croxon (EFIAPI *EFI_DISK_READ) ( 133530d68baSNigel Croxon IN struct _EFI_DISK_IO *This, 134530d68baSNigel Croxon IN UINT32 MediaId, 135530d68baSNigel Croxon IN UINT64 Offset, 136530d68baSNigel Croxon IN UINTN BufferSize, 137530d68baSNigel Croxon OUT VOID *Buffer 138530d68baSNigel Croxon ); 139530d68baSNigel Croxon 140530d68baSNigel Croxon 141530d68baSNigel Croxon typedef 142530d68baSNigel Croxon EFI_STATUS 143530d68baSNigel Croxon (EFIAPI *EFI_DISK_WRITE) ( 144530d68baSNigel Croxon IN struct _EFI_DISK_IO *This, 145530d68baSNigel Croxon IN UINT32 MediaId, 146530d68baSNigel Croxon IN UINT64 Offset, 147530d68baSNigel Croxon IN UINTN BufferSize, 148530d68baSNigel Croxon IN VOID *Buffer 149530d68baSNigel Croxon ); 150530d68baSNigel Croxon 151530d68baSNigel Croxon 152530d68baSNigel Croxon typedef struct _EFI_DISK_IO { 153530d68baSNigel Croxon UINT64 Revision; 154530d68baSNigel Croxon EFI_DISK_READ ReadDisk; 155530d68baSNigel Croxon EFI_DISK_WRITE WriteDisk; 156530d68baSNigel Croxon } EFI_DISK_IO; 157530d68baSNigel Croxon 158530d68baSNigel Croxon 159530d68baSNigel Croxon // 160530d68baSNigel Croxon // Simple file system protocol 161530d68baSNigel Croxon // 162530d68baSNigel Croxon 163530d68baSNigel Croxon #define SIMPLE_FILE_SYSTEM_PROTOCOL \ 164530d68baSNigel Croxon { 0x964e5b22, 0x6459, 0x11d2, {0x8e, 0x39, 0x0, 0xa0, 0xc9, 0x69, 0x72, 0x3b} } 165530d68baSNigel Croxon 166530d68baSNigel Croxon INTERFACE_DECL(_EFI_FILE_IO_INTERFACE); 167530d68baSNigel Croxon INTERFACE_DECL(_EFI_FILE_HANDLE); 168530d68baSNigel Croxon 169530d68baSNigel Croxon typedef 170530d68baSNigel Croxon EFI_STATUS 171530d68baSNigel Croxon (EFIAPI *EFI_VOLUME_OPEN) ( 172530d68baSNigel Croxon IN struct _EFI_FILE_IO_INTERFACE *This, 173530d68baSNigel Croxon OUT struct _EFI_FILE_HANDLE **Root 174530d68baSNigel Croxon ); 175530d68baSNigel Croxon 176530d68baSNigel Croxon #define EFI_FILE_IO_INTERFACE_REVISION 0x00010000 177530d68baSNigel Croxon 178530d68baSNigel Croxon typedef struct _EFI_FILE_IO_INTERFACE { 179530d68baSNigel Croxon UINT64 Revision; 180530d68baSNigel Croxon EFI_VOLUME_OPEN OpenVolume; 181530d68baSNigel Croxon } EFI_FILE_IO_INTERFACE; 182530d68baSNigel Croxon 183530d68baSNigel Croxon // 184530d68baSNigel Croxon // 185530d68baSNigel Croxon // 186530d68baSNigel Croxon 187530d68baSNigel Croxon typedef 188530d68baSNigel Croxon EFI_STATUS 189530d68baSNigel Croxon (EFIAPI *EFI_FILE_OPEN) ( 190530d68baSNigel Croxon IN struct _EFI_FILE_HANDLE *File, 191530d68baSNigel Croxon OUT struct _EFI_FILE_HANDLE **NewHandle, 192530d68baSNigel Croxon IN CHAR16 *FileName, 193530d68baSNigel Croxon IN UINT64 OpenMode, 194530d68baSNigel Croxon IN UINT64 Attributes 195530d68baSNigel Croxon ); 196530d68baSNigel Croxon 197530d68baSNigel Croxon // Open modes 198530d68baSNigel Croxon #define EFI_FILE_MODE_READ 0x0000000000000001 199530d68baSNigel Croxon #define EFI_FILE_MODE_WRITE 0x0000000000000002 200530d68baSNigel Croxon #define EFI_FILE_MODE_CREATE 0x8000000000000000 201530d68baSNigel Croxon 202530d68baSNigel Croxon // File attributes 203530d68baSNigel Croxon #define EFI_FILE_READ_ONLY 0x0000000000000001 204530d68baSNigel Croxon #define EFI_FILE_HIDDEN 0x0000000000000002 205530d68baSNigel Croxon #define EFI_FILE_SYSTEM 0x0000000000000004 206530d68baSNigel Croxon #define EFI_FILE_RESERVIED 0x0000000000000008 207530d68baSNigel Croxon #define EFI_FILE_DIRECTORY 0x0000000000000010 208530d68baSNigel Croxon #define EFI_FILE_ARCHIVE 0x0000000000000020 209530d68baSNigel Croxon #define EFI_FILE_VALID_ATTR 0x0000000000000037 210530d68baSNigel Croxon 211530d68baSNigel Croxon typedef 212530d68baSNigel Croxon EFI_STATUS 213530d68baSNigel Croxon (EFIAPI *EFI_FILE_CLOSE) ( 214530d68baSNigel Croxon IN struct _EFI_FILE_HANDLE *File 215530d68baSNigel Croxon ); 216530d68baSNigel Croxon 217530d68baSNigel Croxon typedef 218530d68baSNigel Croxon EFI_STATUS 219530d68baSNigel Croxon (EFIAPI *EFI_FILE_DELETE) ( 220530d68baSNigel Croxon IN struct _EFI_FILE_HANDLE *File 221530d68baSNigel Croxon ); 222530d68baSNigel Croxon 223530d68baSNigel Croxon typedef 224530d68baSNigel Croxon EFI_STATUS 225530d68baSNigel Croxon (EFIAPI *EFI_FILE_READ) ( 226530d68baSNigel Croxon IN struct _EFI_FILE_HANDLE *File, 227530d68baSNigel Croxon IN OUT UINTN *BufferSize, 228530d68baSNigel Croxon OUT VOID *Buffer 229530d68baSNigel Croxon ); 230530d68baSNigel Croxon 231530d68baSNigel Croxon typedef 232530d68baSNigel Croxon EFI_STATUS 233530d68baSNigel Croxon (EFIAPI *EFI_FILE_WRITE) ( 234530d68baSNigel Croxon IN struct _EFI_FILE_HANDLE *File, 235530d68baSNigel Croxon IN OUT UINTN *BufferSize, 236530d68baSNigel Croxon IN VOID *Buffer 237530d68baSNigel Croxon ); 238530d68baSNigel Croxon 239530d68baSNigel Croxon typedef 240530d68baSNigel Croxon EFI_STATUS 241530d68baSNigel Croxon (EFIAPI *EFI_FILE_SET_POSITION) ( 242530d68baSNigel Croxon IN struct _EFI_FILE_HANDLE *File, 243530d68baSNigel Croxon IN UINT64 Position 244530d68baSNigel Croxon ); 245530d68baSNigel Croxon 246530d68baSNigel Croxon typedef 247530d68baSNigel Croxon EFI_STATUS 248530d68baSNigel Croxon (EFIAPI *EFI_FILE_GET_POSITION) ( 249530d68baSNigel Croxon IN struct _EFI_FILE_HANDLE *File, 250530d68baSNigel Croxon OUT UINT64 *Position 251530d68baSNigel Croxon ); 252530d68baSNigel Croxon 253530d68baSNigel Croxon typedef 254530d68baSNigel Croxon EFI_STATUS 255530d68baSNigel Croxon (EFIAPI *EFI_FILE_GET_INFO) ( 256530d68baSNigel Croxon IN struct _EFI_FILE_HANDLE *File, 257530d68baSNigel Croxon IN EFI_GUID *InformationType, 258530d68baSNigel Croxon IN OUT UINTN *BufferSize, 259530d68baSNigel Croxon OUT VOID *Buffer 260530d68baSNigel Croxon ); 261530d68baSNigel Croxon 262530d68baSNigel Croxon typedef 263530d68baSNigel Croxon EFI_STATUS 264530d68baSNigel Croxon (EFIAPI *EFI_FILE_SET_INFO) ( 265530d68baSNigel Croxon IN struct _EFI_FILE_HANDLE *File, 266530d68baSNigel Croxon IN EFI_GUID *InformationType, 267530d68baSNigel Croxon IN UINTN BufferSize, 268530d68baSNigel Croxon IN VOID *Buffer 269530d68baSNigel Croxon ); 270530d68baSNigel Croxon 271530d68baSNigel Croxon typedef 272530d68baSNigel Croxon EFI_STATUS 273530d68baSNigel Croxon (EFIAPI *EFI_FILE_FLUSH) ( 274530d68baSNigel Croxon IN struct _EFI_FILE_HANDLE *File 275530d68baSNigel Croxon ); 276530d68baSNigel Croxon 277530d68baSNigel Croxon 278530d68baSNigel Croxon 279530d68baSNigel Croxon #define EFI_FILE_HANDLE_REVISION 0x00010000 280530d68baSNigel Croxon typedef struct _EFI_FILE_HANDLE { 281530d68baSNigel Croxon UINT64 Revision; 282530d68baSNigel Croxon EFI_FILE_OPEN Open; 283530d68baSNigel Croxon EFI_FILE_CLOSE Close; 284530d68baSNigel Croxon EFI_FILE_DELETE Delete; 285530d68baSNigel Croxon EFI_FILE_READ Read; 286530d68baSNigel Croxon EFI_FILE_WRITE Write; 287530d68baSNigel Croxon EFI_FILE_GET_POSITION GetPosition; 288530d68baSNigel Croxon EFI_FILE_SET_POSITION SetPosition; 289530d68baSNigel Croxon EFI_FILE_GET_INFO GetInfo; 290530d68baSNigel Croxon EFI_FILE_SET_INFO SetInfo; 291530d68baSNigel Croxon EFI_FILE_FLUSH Flush; 292530d68baSNigel Croxon } EFI_FILE, *EFI_FILE_HANDLE; 293530d68baSNigel Croxon 294530d68baSNigel Croxon 295530d68baSNigel Croxon // 296530d68baSNigel Croxon // File information types 297530d68baSNigel Croxon // 298530d68baSNigel Croxon 299530d68baSNigel Croxon #define EFI_FILE_INFO_ID \ 300530d68baSNigel Croxon { 0x9576e92, 0x6d3f, 0x11d2, {0x8e, 0x39, 0x0, 0xa0, 0xc9, 0x69, 0x72, 0x3b} } 301530d68baSNigel Croxon 302530d68baSNigel Croxon typedef struct { 303530d68baSNigel Croxon UINT64 Size; 304530d68baSNigel Croxon UINT64 FileSize; 305530d68baSNigel Croxon UINT64 PhysicalSize; 306530d68baSNigel Croxon EFI_TIME CreateTime; 307530d68baSNigel Croxon EFI_TIME LastAccessTime; 308530d68baSNigel Croxon EFI_TIME ModificationTime; 309530d68baSNigel Croxon UINT64 Attribute; 310530d68baSNigel Croxon CHAR16 FileName[1]; 311530d68baSNigel Croxon } EFI_FILE_INFO; 312530d68baSNigel Croxon 313530d68baSNigel Croxon // 314530d68baSNigel Croxon // The FileName field of the EFI_FILE_INFO data structure is variable length. 315530d68baSNigel Croxon // Whenever code needs to know the size of the EFI_FILE_INFO data structure, it needs to 316530d68baSNigel Croxon // be the size of the data structure without the FileName field. The following macro 317530d68baSNigel Croxon // computes this size correctly no matter how big the FileName array is declared. 318530d68baSNigel Croxon // This is required to make the EFI_FILE_INFO data structure ANSI compilant. 319530d68baSNigel Croxon // 320530d68baSNigel Croxon 321530d68baSNigel Croxon #define SIZE_OF_EFI_FILE_INFO EFI_FIELD_OFFSET(EFI_FILE_INFO,FileName) 322530d68baSNigel Croxon 323530d68baSNigel Croxon #define EFI_FILE_SYSTEM_INFO_ID \ 324530d68baSNigel Croxon { 0x9576e93, 0x6d3f, 0x11d2, {0x8e, 0x39, 0x0, 0xa0, 0xc9, 0x69, 0x72, 0x3b} } 325530d68baSNigel Croxon 326530d68baSNigel Croxon typedef struct { 327530d68baSNigel Croxon UINT64 Size; 328530d68baSNigel Croxon BOOLEAN ReadOnly; 329530d68baSNigel Croxon UINT64 VolumeSize; 330530d68baSNigel Croxon UINT64 FreeSpace; 331530d68baSNigel Croxon UINT32 BlockSize; 332530d68baSNigel Croxon CHAR16 VolumeLabel[1]; 333530d68baSNigel Croxon } EFI_FILE_SYSTEM_INFO; 334530d68baSNigel Croxon 335530d68baSNigel Croxon // 336530d68baSNigel Croxon // The VolumeLabel field of the EFI_FILE_SYSTEM_INFO data structure is variable length. 337530d68baSNigel Croxon // Whenever code needs to know the size of the EFI_FILE_SYSTEM_INFO data structure, it needs 338530d68baSNigel Croxon // to be the size of the data structure without the VolumeLable field. The following macro 339530d68baSNigel Croxon // computes this size correctly no matter how big the VolumeLable array is declared. 340530d68baSNigel Croxon // This is required to make the EFI_FILE_SYSTEM_INFO data structure ANSI compilant. 341530d68baSNigel Croxon // 342530d68baSNigel Croxon 343530d68baSNigel Croxon #define SIZE_OF_EFI_FILE_SYSTEM_INFO EFI_FIELD_OFFSET(EFI_FILE_SYSTEM_INFO,VolumeLabel) 344530d68baSNigel Croxon 345530d68baSNigel Croxon #define EFI_FILE_SYSTEM_VOLUME_LABEL_INFO_ID \ 346530d68baSNigel Croxon { 0xDB47D7D3,0xFE81, 0x11d3, {0x9A, 0x35, 0x00, 0x90, 0x27, 0x3F, 0xC1, 0x4D} } 347530d68baSNigel Croxon 348530d68baSNigel Croxon typedef struct { 349530d68baSNigel Croxon CHAR16 VolumeLabel[1]; 350530d68baSNigel Croxon } EFI_FILE_SYSTEM_VOLUME_LABEL_INFO; 351530d68baSNigel Croxon 352530d68baSNigel Croxon #define SIZE_OF_EFI_FILE_SYSTEM_VOLUME_LABEL_INFO EFI_FIELD_OFFSET(EFI_FILE_SYSTEM_VOLUME_LABEL_INFO,VolumeLabel) 353530d68baSNigel Croxon 354530d68baSNigel Croxon // 355530d68baSNigel Croxon // Load file protocol 356530d68baSNigel Croxon // 357530d68baSNigel Croxon 358530d68baSNigel Croxon 359530d68baSNigel Croxon #define LOAD_FILE_PROTOCOL \ 360530d68baSNigel Croxon { 0x56EC3091, 0x954C, 0x11d2, {0x8E, 0x3F, 0x00, 0xA0, 0xC9, 0x69, 0x72, 0x3B} } 361530d68baSNigel Croxon 362530d68baSNigel Croxon INTERFACE_DECL(_EFI_LOAD_FILE_INTERFACE); 363530d68baSNigel Croxon 364530d68baSNigel Croxon typedef 365530d68baSNigel Croxon EFI_STATUS 366530d68baSNigel Croxon (EFIAPI *EFI_LOAD_FILE) ( 367530d68baSNigel Croxon IN struct _EFI_LOAD_FILE_INTERFACE *This, 368530d68baSNigel Croxon IN EFI_DEVICE_PATH *FilePath, 369530d68baSNigel Croxon IN BOOLEAN BootPolicy, 370530d68baSNigel Croxon IN OUT UINTN *BufferSize, 371530d68baSNigel Croxon IN VOID *Buffer OPTIONAL 372530d68baSNigel Croxon ); 373530d68baSNigel Croxon 374530d68baSNigel Croxon typedef struct _EFI_LOAD_FILE_INTERFACE { 375530d68baSNigel Croxon EFI_LOAD_FILE LoadFile; 376530d68baSNigel Croxon } EFI_LOAD_FILE_INTERFACE; 377530d68baSNigel Croxon 378530d68baSNigel Croxon 379530d68baSNigel Croxon // 380530d68baSNigel Croxon // Device IO protocol 381530d68baSNigel Croxon // 382530d68baSNigel Croxon 383530d68baSNigel Croxon #define DEVICE_IO_PROTOCOL \ 384530d68baSNigel Croxon { 0xaf6ac311, 0x84c3, 0x11d2, {0x8e, 0x3c, 0x00, 0xa0, 0xc9, 0x69, 0x72, 0x3b} } 385530d68baSNigel Croxon 386530d68baSNigel Croxon INTERFACE_DECL(_EFI_DEVICE_IO_INTERFACE); 387530d68baSNigel Croxon 388530d68baSNigel Croxon typedef enum { 389530d68baSNigel Croxon IO_UINT8, 390530d68baSNigel Croxon IO_UINT16, 391530d68baSNigel Croxon IO_UINT32, 392530d68baSNigel Croxon IO_UINT64, 393530d68baSNigel Croxon // 394530d68baSNigel Croxon // Specification Change: Copy from MMIO to MMIO vs. MMIO to buffer, buffer to MMIO 395530d68baSNigel Croxon // 396530d68baSNigel Croxon MMIO_COPY_UINT8, 397530d68baSNigel Croxon MMIO_COPY_UINT16, 398530d68baSNigel Croxon MMIO_COPY_UINT32, 399530d68baSNigel Croxon MMIO_COPY_UINT64 400530d68baSNigel Croxon } EFI_IO_WIDTH; 401530d68baSNigel Croxon 402530d68baSNigel Croxon #define EFI_PCI_ADDRESS(_bus,_dev,_func) \ 403530d68baSNigel Croxon ( (UINT64) ( (((UINTN)_bus) << 24) + (((UINTN)_dev) << 16) + (((UINTN)_func) << 8) ) ) 404530d68baSNigel Croxon 405530d68baSNigel Croxon 406530d68baSNigel Croxon typedef 407530d68baSNigel Croxon EFI_STATUS 408530d68baSNigel Croxon (EFIAPI *EFI_DEVICE_IO) ( 409530d68baSNigel Croxon IN struct _EFI_DEVICE_IO_INTERFACE *This, 410530d68baSNigel Croxon IN EFI_IO_WIDTH Width, 411530d68baSNigel Croxon IN UINT64 Address, 412530d68baSNigel Croxon IN UINTN Count, 413530d68baSNigel Croxon IN OUT VOID *Buffer 414530d68baSNigel Croxon ); 415530d68baSNigel Croxon 416530d68baSNigel Croxon typedef struct { 417530d68baSNigel Croxon EFI_DEVICE_IO Read; 418530d68baSNigel Croxon EFI_DEVICE_IO Write; 419530d68baSNigel Croxon } EFI_IO_ACCESS; 420530d68baSNigel Croxon 421530d68baSNigel Croxon typedef 422530d68baSNigel Croxon EFI_STATUS 423530d68baSNigel Croxon (EFIAPI *EFI_PCI_DEVICE_PATH) ( 424530d68baSNigel Croxon IN struct _EFI_DEVICE_IO_INTERFACE *This, 425530d68baSNigel Croxon IN UINT64 Address, 426530d68baSNigel Croxon IN OUT EFI_DEVICE_PATH **PciDevicePath 427530d68baSNigel Croxon ); 428530d68baSNigel Croxon 429530d68baSNigel Croxon typedef enum { 430530d68baSNigel Croxon EfiBusMasterRead, 431530d68baSNigel Croxon EfiBusMasterWrite, 432530d68baSNigel Croxon EfiBusMasterCommonBuffer 433530d68baSNigel Croxon } EFI_IO_OPERATION_TYPE; 434530d68baSNigel Croxon 435530d68baSNigel Croxon typedef 436530d68baSNigel Croxon EFI_STATUS 437530d68baSNigel Croxon (EFIAPI *EFI_IO_MAP) ( 438530d68baSNigel Croxon IN struct _EFI_DEVICE_IO_INTERFACE *This, 439530d68baSNigel Croxon IN EFI_IO_OPERATION_TYPE Operation, 440530d68baSNigel Croxon IN EFI_PHYSICAL_ADDRESS *HostAddress, 441530d68baSNigel Croxon IN OUT UINTN *NumberOfBytes, 442530d68baSNigel Croxon OUT EFI_PHYSICAL_ADDRESS *DeviceAddress, 443530d68baSNigel Croxon OUT VOID **Mapping 444530d68baSNigel Croxon ); 445530d68baSNigel Croxon 446530d68baSNigel Croxon typedef 447530d68baSNigel Croxon EFI_STATUS 448530d68baSNigel Croxon (EFIAPI *EFI_IO_UNMAP) ( 449530d68baSNigel Croxon IN struct _EFI_DEVICE_IO_INTERFACE *This, 450530d68baSNigel Croxon IN VOID *Mapping 451530d68baSNigel Croxon ); 452530d68baSNigel Croxon 453530d68baSNigel Croxon typedef 454530d68baSNigel Croxon EFI_STATUS 455530d68baSNigel Croxon (EFIAPI *EFI_IO_ALLOCATE_BUFFER) ( 456530d68baSNigel Croxon IN struct _EFI_DEVICE_IO_INTERFACE *This, 457530d68baSNigel Croxon IN EFI_ALLOCATE_TYPE Type, 458530d68baSNigel Croxon IN EFI_MEMORY_TYPE MemoryType, 459530d68baSNigel Croxon IN UINTN Pages, 460530d68baSNigel Croxon IN OUT EFI_PHYSICAL_ADDRESS *HostAddress 461530d68baSNigel Croxon ); 462530d68baSNigel Croxon 463530d68baSNigel Croxon typedef 464530d68baSNigel Croxon EFI_STATUS 465530d68baSNigel Croxon (EFIAPI *EFI_IO_FLUSH) ( 466530d68baSNigel Croxon IN struct _EFI_DEVICE_IO_INTERFACE *This 467530d68baSNigel Croxon ); 468530d68baSNigel Croxon 469530d68baSNigel Croxon typedef 470530d68baSNigel Croxon EFI_STATUS 471530d68baSNigel Croxon (EFIAPI *EFI_IO_FREE_BUFFER) ( 472530d68baSNigel Croxon IN struct _EFI_DEVICE_IO_INTERFACE *This, 473530d68baSNigel Croxon IN UINTN Pages, 474530d68baSNigel Croxon IN EFI_PHYSICAL_ADDRESS HostAddress 475530d68baSNigel Croxon ); 476530d68baSNigel Croxon 477530d68baSNigel Croxon typedef struct _EFI_DEVICE_IO_INTERFACE { 478530d68baSNigel Croxon EFI_IO_ACCESS Mem; 479530d68baSNigel Croxon EFI_IO_ACCESS Io; 480530d68baSNigel Croxon EFI_IO_ACCESS Pci; 481530d68baSNigel Croxon EFI_IO_MAP Map; 482530d68baSNigel Croxon EFI_PCI_DEVICE_PATH PciDevicePath; 483530d68baSNigel Croxon EFI_IO_UNMAP Unmap; 484530d68baSNigel Croxon EFI_IO_ALLOCATE_BUFFER AllocateBuffer; 485530d68baSNigel Croxon EFI_IO_FLUSH Flush; 486530d68baSNigel Croxon EFI_IO_FREE_BUFFER FreeBuffer; 487530d68baSNigel Croxon } EFI_DEVICE_IO_INTERFACE; 488530d68baSNigel Croxon 489530d68baSNigel Croxon 490530d68baSNigel Croxon // 491530d68baSNigel Croxon // Unicode Collation protocol 492530d68baSNigel Croxon // 493530d68baSNigel Croxon 494530d68baSNigel Croxon #define UNICODE_COLLATION_PROTOCOL \ 495530d68baSNigel Croxon { 0x1d85cd7f, 0xf43d, 0x11d2, {0x9a, 0xc, 0x0, 0x90, 0x27, 0x3f, 0xc1, 0x4d} } 496530d68baSNigel Croxon 497530d68baSNigel Croxon #define UNICODE_BYTE_ORDER_MARK (CHAR16)(0xfeff) 498530d68baSNigel Croxon 499530d68baSNigel Croxon INTERFACE_DECL(_EFI_UNICODE_COLLATION_INTERFACE); 500530d68baSNigel Croxon 501530d68baSNigel Croxon typedef 502530d68baSNigel Croxon INTN 503530d68baSNigel Croxon (EFIAPI *EFI_UNICODE_STRICOLL) ( 504530d68baSNigel Croxon IN struct _EFI_UNICODE_COLLATION_INTERFACE *This, 505530d68baSNigel Croxon IN CHAR16 *s1, 506530d68baSNigel Croxon IN CHAR16 *s2 507530d68baSNigel Croxon ); 508530d68baSNigel Croxon 509530d68baSNigel Croxon typedef 510530d68baSNigel Croxon BOOLEAN 511530d68baSNigel Croxon (EFIAPI *EFI_UNICODE_METAIMATCH) ( 512530d68baSNigel Croxon IN struct _EFI_UNICODE_COLLATION_INTERFACE *This, 513530d68baSNigel Croxon IN CHAR16 *String, 514530d68baSNigel Croxon IN CHAR16 *Pattern 515530d68baSNigel Croxon ); 516530d68baSNigel Croxon 517530d68baSNigel Croxon typedef 518530d68baSNigel Croxon VOID 519530d68baSNigel Croxon (EFIAPI *EFI_UNICODE_STRLWR) ( 520530d68baSNigel Croxon IN struct _EFI_UNICODE_COLLATION_INTERFACE *This, 521530d68baSNigel Croxon IN OUT CHAR16 *Str 522530d68baSNigel Croxon ); 523530d68baSNigel Croxon 524530d68baSNigel Croxon typedef 525530d68baSNigel Croxon VOID 526530d68baSNigel Croxon (EFIAPI *EFI_UNICODE_STRUPR) ( 527530d68baSNigel Croxon IN struct _EFI_UNICODE_COLLATION_INTERFACE *This, 528530d68baSNigel Croxon IN OUT CHAR16 *Str 529530d68baSNigel Croxon ); 530530d68baSNigel Croxon 531530d68baSNigel Croxon typedef 532530d68baSNigel Croxon VOID 533530d68baSNigel Croxon (EFIAPI *EFI_UNICODE_FATTOSTR) ( 534530d68baSNigel Croxon IN struct _EFI_UNICODE_COLLATION_INTERFACE *This, 535530d68baSNigel Croxon IN UINTN FatSize, 536530d68baSNigel Croxon IN CHAR8 *Fat, 537530d68baSNigel Croxon OUT CHAR16 *String 538530d68baSNigel Croxon ); 539530d68baSNigel Croxon 540530d68baSNigel Croxon typedef 541530d68baSNigel Croxon BOOLEAN 542530d68baSNigel Croxon (EFIAPI *EFI_UNICODE_STRTOFAT) ( 543530d68baSNigel Croxon IN struct _EFI_UNICODE_COLLATION_INTERFACE *This, 544530d68baSNigel Croxon IN CHAR16 *String, 545530d68baSNigel Croxon IN UINTN FatSize, 546530d68baSNigel Croxon OUT CHAR8 *Fat 547530d68baSNigel Croxon ); 548530d68baSNigel Croxon 5498c29617eSNigel Croxon // 5508c29617eSNigel Croxon // Hash Protocol 5518c29617eSNigel Croxon // 5528c29617eSNigel Croxon #define HASH_PROTOCOL \ 5538c29617eSNigel Croxon { 0xC5184932, 0xDBA5, 0x46DB, { 0xA5, 0xBA, 0xCC, 0x0B, 0xDA, 0x9C, 0x14, 0x35 } } 5548c29617eSNigel Croxon 5558c29617eSNigel Croxon #define EFI_HASH_ALGORITHM_SHA1 \ 5568c29617eSNigel Croxon { 0x2AE9D80F, 0x3FB2, 0x4095, { 0xB7, 0xB1, 0xE9, 0x31, 0x57, 0xB9, 0x46, 0xB6 } } // Deprecated 5578c29617eSNigel Croxon 5588c29617eSNigel Croxon #define EFI_HASH_ALGORITHM_SHA224 \ 5598c29617eSNigel Croxon { 0x8DF01A06, 0x9BD5, 0x4BF7, { 0xB0, 0x21, 0xDB, 0x4F, 0xD9, 0xCC, 0xF4, 0x5B } } // Deprecated 5608c29617eSNigel Croxon 5618c29617eSNigel Croxon #define EFI_HASH_ALGORITHM_SHA256 \ 5628c29617eSNigel Croxon { 0x51AA59DE, 0xFDF2, 0x4EA3, { 0xBC, 0x63, 0x87, 0x5F, 0xB7, 0x84, 0x2E, 0xE9 } } // Deprecated 5638c29617eSNigel Croxon 5648c29617eSNigel Croxon #define EFI_HASH_ALGORITHM_SHA384 \ 5658c29617eSNigel Croxon { 0xEFA96432, 0xDE33, 0x4DD2, { 0xAE, 0xE6, 0x32, 0x8C, 0x33, 0xDF, 0x77, 0x7A } } // Deprecated 5668c29617eSNigel Croxon 5678c29617eSNigel Croxon #define EFI_HASH_ALGORITHM_SHA512 \ 5688c29617eSNigel Croxon { 0xCAA4381E, 0x750C, 0x4770, { 0xB8, 0x70, 0x7A, 0x23, 0xB4, 0xE4, 0x21, 0x30 } } // Deprecated 5698c29617eSNigel Croxon 5708c29617eSNigel Croxon #define EFI_HASH_ALGORITHM_MD5 \ 5718c29617eSNigel Croxon { 0x0AF7C79C, 0x65B5, 0x4319, { 0xB0, 0xAE, 0x44, 0xEC, 0x48, 0x4E, 0x4A, 0xD7 } } // Deprecated 5728c29617eSNigel Croxon 5738c29617eSNigel Croxon #define EFI_HASH_ALGORITHM_SHA1_NOPAD \ 5748c29617eSNigel Croxon { 0x24C5DC2F, 0x53E2, 0x40CA, { 0x9E, 0xD6, 0xA5, 0xD9, 0xA4, 0x9F, 0x46, 0x3B } } 5758c29617eSNigel Croxon 5768c29617eSNigel Croxon #define EFI_HASH_ALGORITHM_SHA256_NOPAD \ 5778c29617eSNigel Croxon { 0x8628752A, 0x6CB7, 0x4814, { 0x96, 0xFC, 0x24, 0xA8, 0x15, 0xAC, 0x22, 0x26 } } 5788c29617eSNigel Croxon 5798c29617eSNigel Croxon 5808c29617eSNigel Croxon INTERFACE_DECL(_EFI_HASH); 5818c29617eSNigel Croxon 5828c29617eSNigel Croxon typedef UINT8 EFI_MD5_HASH[16]; 5838c29617eSNigel Croxon typedef UINT8 EFI_SHA1_HASH[20]; 5848c29617eSNigel Croxon typedef UINT8 EFI_SHA224_HASH[28]; 5858c29617eSNigel Croxon typedef UINT8 EFI_SHA256_HASH[32]; 5868c29617eSNigel Croxon typedef UINT8 EFI_SHA384_HASH[48]; 5878c29617eSNigel Croxon typedef UINT8 EFI_SHA512_HASH[64]; 5888c29617eSNigel Croxon typedef union _EFI_HASH_OUTPUT { 5898c29617eSNigel Croxon EFI_MD5_HASH *Md5Hash; 5908c29617eSNigel Croxon EFI_SHA1_HASH *Sha1Hash; 5918c29617eSNigel Croxon EFI_SHA224_HASH *Sha224Hash; 5928c29617eSNigel Croxon EFI_SHA256_HASH *Sha256Hash; 5938c29617eSNigel Croxon EFI_SHA384_HASH *Sha384Hash; 5948c29617eSNigel Croxon EFI_SHA512_HASH *Sha512Hash; 5958c29617eSNigel Croxon } EFI_HASH_OUTPUT; 5968c29617eSNigel Croxon 5978c29617eSNigel Croxon typedef 5988c29617eSNigel Croxon EFI_STATUS 5998c29617eSNigel Croxon (EFIAPI *EFI_HASH_GET_HASH_SIZE) ( 6008c29617eSNigel Croxon IN CONST struct _EFI_HASH *This, 6018c29617eSNigel Croxon IN CONST EFI_GUID *HashAlgorithm, 6028c29617eSNigel Croxon OUT UINTN *HashSize); 6038c29617eSNigel Croxon 6048c29617eSNigel Croxon typedef 6058c29617eSNigel Croxon EFI_STATUS 6068c29617eSNigel Croxon (EFIAPI *EFI_HASH_HASH) ( 6078c29617eSNigel Croxon IN CONST struct _EFI_HASH *This, 6088c29617eSNigel Croxon IN CONST EFI_GUID *HashAlgorithm, 6098c29617eSNigel Croxon IN BOOLEAN Extend, 6108c29617eSNigel Croxon IN CONST UINT8 *Message, 6118c29617eSNigel Croxon IN UINT64 MessageSize, 6128c29617eSNigel Croxon IN OUT EFI_HASH_OUTPUT *Hash); 6138c29617eSNigel Croxon 6148c29617eSNigel Croxon typedef struct _EFI_HASH { 6158c29617eSNigel Croxon EFI_HASH_GET_HASH_SIZE GetHashSize; 6168c29617eSNigel Croxon EFI_HASH_HASH Hash; 6178c29617eSNigel Croxon } EFI_HASH; 6188c29617eSNigel Croxon 619530d68baSNigel Croxon 620530d68baSNigel Croxon typedef struct _EFI_UNICODE_COLLATION_INTERFACE { 621530d68baSNigel Croxon 622530d68baSNigel Croxon // general 623530d68baSNigel Croxon EFI_UNICODE_STRICOLL StriColl; 624530d68baSNigel Croxon EFI_UNICODE_METAIMATCH MetaiMatch; 625530d68baSNigel Croxon EFI_UNICODE_STRLWR StrLwr; 626530d68baSNigel Croxon EFI_UNICODE_STRUPR StrUpr; 627530d68baSNigel Croxon 628530d68baSNigel Croxon // for supporting fat volumes 629530d68baSNigel Croxon EFI_UNICODE_FATTOSTR FatToStr; 630530d68baSNigel Croxon EFI_UNICODE_STRTOFAT StrToFat; 631530d68baSNigel Croxon 632530d68baSNigel Croxon CHAR8 *SupportedLanguages; 633530d68baSNigel Croxon } EFI_UNICODE_COLLATION_INTERFACE; 634530d68baSNigel Croxon 635530d68baSNigel Croxon /* Graphics output protocol */ 636530d68baSNigel Croxon #define EFI_GRAPHICS_OUTPUT_PROTOCOL_GUID \ 637530d68baSNigel Croxon { \ 638530d68baSNigel Croxon 0x9042a9de, 0x23dc, 0x4a38, {0x96, 0xfb, 0x7a, 0xde, 0xd0, 0x80, 0x51, 0x6a } \ 639530d68baSNigel Croxon } 640530d68baSNigel Croxon 641530d68baSNigel Croxon typedef struct _EFI_GRAPHICS_OUTPUT_PROTOCOL EFI_GRAPHICS_OUTPUT_PROTOCOL; 642530d68baSNigel Croxon 643530d68baSNigel Croxon typedef struct { 644530d68baSNigel Croxon UINT32 RedMask; 645530d68baSNigel Croxon UINT32 GreenMask; 646530d68baSNigel Croxon UINT32 BlueMask; 647530d68baSNigel Croxon UINT32 ReservedMask; 648530d68baSNigel Croxon } EFI_PIXEL_BITMASK; 649530d68baSNigel Croxon 650530d68baSNigel Croxon typedef enum { 651530d68baSNigel Croxon PixelRedGreenBlueReserved8BitPerColor, 652530d68baSNigel Croxon PixelBlueGreenRedReserved8BitPerColor, 653530d68baSNigel Croxon PixelBitMask, 654530d68baSNigel Croxon PixelBltOnly, 655530d68baSNigel Croxon PixelFormatMax 656530d68baSNigel Croxon } EFI_GRAPHICS_PIXEL_FORMAT; 657530d68baSNigel Croxon 658530d68baSNigel Croxon typedef struct { 659530d68baSNigel Croxon UINT32 Version; 660530d68baSNigel Croxon UINT32 HorizontalResolution; 661530d68baSNigel Croxon UINT32 VerticalResolution; 662530d68baSNigel Croxon EFI_GRAPHICS_PIXEL_FORMAT PixelFormat; 663530d68baSNigel Croxon EFI_PIXEL_BITMASK PixelInformation; 664530d68baSNigel Croxon UINT32 PixelsPerScanLine; 665530d68baSNigel Croxon } EFI_GRAPHICS_OUTPUT_MODE_INFORMATION; 666530d68baSNigel Croxon 667530d68baSNigel Croxon /** 668530d68baSNigel Croxon Return the current video mode information. 669530d68baSNigel Croxon 670530d68baSNigel Croxon @param This Protocol instance pointer. 671530d68baSNigel Croxon @param ModeNumber The mode number to return information on. 672530d68baSNigel Croxon @param SizeOfInfo A pointer to the size, in bytes, of the Info buffer. 673530d68baSNigel Croxon @param Info A pointer to callee allocated buffer that returns information about ModeNumber. 674530d68baSNigel Croxon 675530d68baSNigel Croxon @retval EFI_SUCCESS Mode information returned. 676530d68baSNigel Croxon @retval EFI_BUFFER_TOO_SMALL The Info buffer was too small. 677530d68baSNigel Croxon @retval EFI_DEVICE_ERROR A hardware error occurred trying to retrieve the video mode. 678530d68baSNigel Croxon @retval EFI_NOT_STARTED Video display is not initialized. Call SetMode () 679530d68baSNigel Croxon @retval EFI_INVALID_PARAMETER One of the input args was NULL. 680530d68baSNigel Croxon 681530d68baSNigel Croxon **/ 682530d68baSNigel Croxon typedef 683530d68baSNigel Croxon EFI_STATUS 684530d68baSNigel Croxon (EFIAPI *EFI_GRAPHICS_OUTPUT_PROTOCOL_QUERY_MODE) ( 685530d68baSNigel Croxon IN EFI_GRAPHICS_OUTPUT_PROTOCOL *This, 686530d68baSNigel Croxon IN UINT32 ModeNumber, 687530d68baSNigel Croxon OUT UINTN *SizeOfInfo, 688530d68baSNigel Croxon OUT EFI_GRAPHICS_OUTPUT_MODE_INFORMATION **Info 689530d68baSNigel Croxon ) 690530d68baSNigel Croxon ; 691530d68baSNigel Croxon 692530d68baSNigel Croxon /** 693530d68baSNigel Croxon Return the current video mode information. 694530d68baSNigel Croxon 695530d68baSNigel Croxon @param This Protocol instance pointer. 696530d68baSNigel Croxon @param ModeNumber The mode number to be set. 697530d68baSNigel Croxon 698530d68baSNigel Croxon @retval EFI_SUCCESS Graphics mode was changed. 699530d68baSNigel Croxon @retval EFI_DEVICE_ERROR The device had an error and could not complete the request. 700530d68baSNigel Croxon @retval EFI_UNSUPPORTED ModeNumber is not supported by this device. 701530d68baSNigel Croxon 702530d68baSNigel Croxon **/ 703530d68baSNigel Croxon typedef 704530d68baSNigel Croxon EFI_STATUS 705530d68baSNigel Croxon (EFIAPI *EFI_GRAPHICS_OUTPUT_PROTOCOL_SET_MODE) ( 706530d68baSNigel Croxon IN EFI_GRAPHICS_OUTPUT_PROTOCOL *This, 707530d68baSNigel Croxon IN UINT32 ModeNumber 708530d68baSNigel Croxon ); 709530d68baSNigel Croxon 710530d68baSNigel Croxon typedef struct { 711530d68baSNigel Croxon UINT8 Blue; 712530d68baSNigel Croxon UINT8 Green; 713530d68baSNigel Croxon UINT8 Red; 714530d68baSNigel Croxon UINT8 Reserved; 715530d68baSNigel Croxon } EFI_GRAPHICS_OUTPUT_BLT_PIXEL; 716530d68baSNigel Croxon 717530d68baSNigel Croxon typedef union { 718530d68baSNigel Croxon EFI_GRAPHICS_OUTPUT_BLT_PIXEL Pixel; 719530d68baSNigel Croxon UINT32 Raw; 720530d68baSNigel Croxon } EFI_GRAPHICS_OUTPUT_BLT_PIXEL_UNION; 721530d68baSNigel Croxon 722530d68baSNigel Croxon typedef enum { 723530d68baSNigel Croxon EfiBltVideoFill, 724530d68baSNigel Croxon EfiBltVideoToBltBuffer, 725530d68baSNigel Croxon EfiBltBufferToVideo, 726530d68baSNigel Croxon EfiBltVideoToVideo, 727530d68baSNigel Croxon EfiGraphicsOutputBltOperationMax 728530d68baSNigel Croxon } EFI_GRAPHICS_OUTPUT_BLT_OPERATION; 729530d68baSNigel Croxon 730530d68baSNigel Croxon /** 731530d68baSNigel Croxon The following table defines actions for BltOperations: 732530d68baSNigel Croxon 733530d68baSNigel Croxon <B>EfiBltVideoFill</B> - Write data from the BltBuffer pixel (SourceX, SourceY) 734530d68baSNigel Croxon directly to every pixel of the video display rectangle 735530d68baSNigel Croxon (DestinationX, DestinationY) (DestinationX + Width, DestinationY + Height). 736530d68baSNigel Croxon Only one pixel will be used from the BltBuffer. Delta is NOT used. 737530d68baSNigel Croxon 738530d68baSNigel Croxon <B>EfiBltVideoToBltBuffer</B> - Read data from the video display rectangle 739530d68baSNigel Croxon (SourceX, SourceY) (SourceX + Width, SourceY + Height) and place it in 740530d68baSNigel Croxon the BltBuffer rectangle (DestinationX, DestinationY ) 741530d68baSNigel Croxon (DestinationX + Width, DestinationY + Height). If DestinationX or 742530d68baSNigel Croxon DestinationY is not zero then Delta must be set to the length in bytes 743530d68baSNigel Croxon of a row in the BltBuffer. 744530d68baSNigel Croxon 745530d68baSNigel Croxon <B>EfiBltBufferToVideo</B> - Write data from the BltBuffer rectangle 746530d68baSNigel Croxon (SourceX, SourceY) (SourceX + Width, SourceY + Height) directly to the 747530d68baSNigel Croxon video display rectangle (DestinationX, DestinationY) 748530d68baSNigel Croxon (DestinationX + Width, DestinationY + Height). If SourceX or SourceY is 749530d68baSNigel Croxon not zero then Delta must be set to the length in bytes of a row in the 750530d68baSNigel Croxon BltBuffer. 751530d68baSNigel Croxon 752530d68baSNigel Croxon <B>EfiBltVideoToVideo</B> - Copy from the video display rectangle (SourceX, SourceY) 753530d68baSNigel Croxon (SourceX + Width, SourceY + Height) .to the video display rectangle 754530d68baSNigel Croxon (DestinationX, DestinationY) (DestinationX + Width, DestinationY + Height). 755530d68baSNigel Croxon The BltBuffer and Delta are not used in this mode. 756530d68baSNigel Croxon 757530d68baSNigel Croxon @param This Protocol instance pointer. 758530d68baSNigel Croxon @param BltBuffer Buffer containing data to blit into video buffer. This 759530d68baSNigel Croxon buffer has a size of Width*Height*sizeof(EFI_GRAPHICS_OUTPUT_BLT_PIXEL) 760530d68baSNigel Croxon @param BltOperation Operation to perform on BlitBuffer and video memory 761530d68baSNigel Croxon @param SourceX X coordinate of source for the BltBuffer. 762530d68baSNigel Croxon @param SourceY Y coordinate of source for the BltBuffer. 763530d68baSNigel Croxon @param DestinationX X coordinate of destination for the BltBuffer. 764530d68baSNigel Croxon @param DestinationY Y coordinate of destination for the BltBuffer. 765530d68baSNigel Croxon @param Width Width of rectangle in BltBuffer in pixels. 766530d68baSNigel Croxon @param Height Hight of rectangle in BltBuffer in pixels. 767530d68baSNigel Croxon @param Delta OPTIONAL 768530d68baSNigel Croxon 769530d68baSNigel Croxon @retval EFI_SUCCESS The Blt operation completed. 770530d68baSNigel Croxon @retval EFI_INVALID_PARAMETER BltOperation is not valid. 771530d68baSNigel Croxon @retval EFI_DEVICE_ERROR A hardware error occured writting to the video buffer. 772530d68baSNigel Croxon 773530d68baSNigel Croxon **/ 774530d68baSNigel Croxon typedef 775530d68baSNigel Croxon EFI_STATUS 776530d68baSNigel Croxon (EFIAPI *EFI_GRAPHICS_OUTPUT_PROTOCOL_BLT) ( 777530d68baSNigel Croxon IN EFI_GRAPHICS_OUTPUT_PROTOCOL *This, 778530d68baSNigel Croxon IN EFI_GRAPHICS_OUTPUT_BLT_PIXEL *BltBuffer, OPTIONAL 779530d68baSNigel Croxon IN EFI_GRAPHICS_OUTPUT_BLT_OPERATION BltOperation, 780530d68baSNigel Croxon IN UINTN SourceX, 781530d68baSNigel Croxon IN UINTN SourceY, 782530d68baSNigel Croxon IN UINTN DestinationX, 783530d68baSNigel Croxon IN UINTN DestinationY, 784530d68baSNigel Croxon IN UINTN Width, 785530d68baSNigel Croxon IN UINTN Height, 786530d68baSNigel Croxon IN UINTN Delta OPTIONAL 787530d68baSNigel Croxon ); 788530d68baSNigel Croxon 789530d68baSNigel Croxon typedef struct { 790530d68baSNigel Croxon UINT32 MaxMode; 791530d68baSNigel Croxon UINT32 Mode; 792530d68baSNigel Croxon EFI_GRAPHICS_OUTPUT_MODE_INFORMATION *Info; 793530d68baSNigel Croxon UINTN SizeOfInfo; 794530d68baSNigel Croxon EFI_PHYSICAL_ADDRESS FrameBufferBase; 795530d68baSNigel Croxon UINTN FrameBufferSize; 796530d68baSNigel Croxon } EFI_GRAPHICS_OUTPUT_PROTOCOL_MODE; 797530d68baSNigel Croxon 798530d68baSNigel Croxon struct _EFI_GRAPHICS_OUTPUT_PROTOCOL { 799530d68baSNigel Croxon EFI_GRAPHICS_OUTPUT_PROTOCOL_QUERY_MODE QueryMode; 800530d68baSNigel Croxon EFI_GRAPHICS_OUTPUT_PROTOCOL_SET_MODE SetMode; 801530d68baSNigel Croxon EFI_GRAPHICS_OUTPUT_PROTOCOL_BLT Blt; 802530d68baSNigel Croxon EFI_GRAPHICS_OUTPUT_PROTOCOL_MODE *Mode; 803530d68baSNigel Croxon }; 804530d68baSNigel Croxon 805*8118d087SNigel Croxon 806530d68baSNigel Croxon INTERFACE_DECL(_EFI_SERVICE_BINDING); 807530d68baSNigel Croxon 808530d68baSNigel Croxon typedef 809530d68baSNigel Croxon EFI_STATUS 810530d68baSNigel Croxon (EFIAPI *EFI_SERVICE_BINDING_CREATE_CHILD) ( 811530d68baSNigel Croxon IN struct _EFI_SERVICE_BINDING *This, 812530d68baSNigel Croxon IN EFI_HANDLE *ChildHandle 813530d68baSNigel Croxon ); 814530d68baSNigel Croxon 815530d68baSNigel Croxon typedef 816530d68baSNigel Croxon EFI_STATUS 817530d68baSNigel Croxon (EFIAPI *EFI_SERVICE_BINDING_DESTROY_CHILD) ( 818530d68baSNigel Croxon IN struct _EFI_SERVICE_BINDING *This, 819530d68baSNigel Croxon IN EFI_HANDLE ChildHandle 820530d68baSNigel Croxon ); 821530d68baSNigel Croxon 822530d68baSNigel Croxon typedef struct _EFI_SERVICE_BINDING { 823530d68baSNigel Croxon EFI_SERVICE_BINDING_CREATE_CHILD CreateChild; 824530d68baSNigel Croxon EFI_SERVICE_BINDING_DESTROY_CHILD DestroyChild; 825530d68baSNigel Croxon } EFI_SERVICE_BINDING; 826530d68baSNigel Croxon 827533a042dSNigel Croxon 828*8118d087SNigel Croxon 829*8118d087SNigel Croxon /* 830*8118d087SNigel Croxon * EFI Driver Binding Protocol 831*8118d087SNigel Croxon * UEFI Specification Version 2.5 Section 10.1 832*8118d087SNigel Croxon */ 833*8118d087SNigel Croxon #define EFI_DRIVER_BINDING_PROTOCOL_GUID \ 834533a042dSNigel Croxon { 0x18A031AB, 0xB443, 0x4D1A, { 0xA5, 0xC0, 0x0C, 0x09, 0x26, 0x1E, 0x9F, 0x71} } 835533a042dSNigel Croxon 836*8118d087SNigel Croxon INTERFACE_DECL(_EFI_DRIVER_BINDING_PROTOCOL); 837533a042dSNigel Croxon 838533a042dSNigel Croxon typedef 839533a042dSNigel Croxon EFI_STATUS 840*8118d087SNigel Croxon (EFIAPI *EFI_DRIVER_BINDING_PROTOCOL_SUPPORTED) ( 841*8118d087SNigel Croxon IN struct _EFI_DRIVER_BINDING_PROTOCOL *This, 842533a042dSNigel Croxon IN EFI_HANDLE ControllerHandle, 843533a042dSNigel Croxon IN EFI_DEVICE_PATH *RemainingDevicePath OPTIONAL); 844533a042dSNigel Croxon 845533a042dSNigel Croxon typedef 846533a042dSNigel Croxon EFI_STATUS 847*8118d087SNigel Croxon (EFIAPI *EFI_DRIVER_BINDING_PROTOCOL_START) ( 848*8118d087SNigel Croxon IN struct _EFI_DRIVER_BINDING_PROTOCOL *This, 849533a042dSNigel Croxon IN EFI_HANDLE ControllerHandle, 850533a042dSNigel Croxon IN EFI_DEVICE_PATH *RemainingDevicePath OPTIONAL); 851533a042dSNigel Croxon 852533a042dSNigel Croxon typedef 853533a042dSNigel Croxon EFI_STATUS 854*8118d087SNigel Croxon (EFIAPI *EFI_DRIVER_BINDING_PROTOCOL_STOP) ( 855*8118d087SNigel Croxon IN struct _EFI_DRIVER_BINDING_PROTOCOL *This, 856533a042dSNigel Croxon IN EFI_HANDLE ControllerHandle, 857533a042dSNigel Croxon IN UINTN NumberOfChildren, 858533a042dSNigel Croxon IN EFI_HANDLE *ChildHandleBuffer OPTIONAL); 859533a042dSNigel Croxon 860*8118d087SNigel Croxon typedef struct _EFI_DRIVER_BINDING_PROTOCOL { 861*8118d087SNigel Croxon EFI_DRIVER_BINDING_PROTOCOL_SUPPORTED Supported; 862*8118d087SNigel Croxon EFI_DRIVER_BINDING_PROTOCOL_START Start; 863*8118d087SNigel Croxon EFI_DRIVER_BINDING_PROTOCOL_STOP Stop; 864533a042dSNigel Croxon UINT32 Version; 865533a042dSNigel Croxon EFI_HANDLE ImageHandle; 866533a042dSNigel Croxon EFI_HANDLE DriverBindingHandle; 867*8118d087SNigel Croxon } EFI_DRIVER_BINDING_PROTOCOL; 868533a042dSNigel Croxon 869883702e8SNigel Croxon 870*8118d087SNigel Croxon 871*8118d087SNigel Croxon /* 872*8118d087SNigel Croxon * Backwards compatibility with older GNU-EFI versions. Deprecated. 873*8118d087SNigel Croxon */ 874*8118d087SNigel Croxon #define DRIVER_BINDING_PROTOCOL EFI_DRIVER_BINDING_PROTOCOL_GUID 875*8118d087SNigel Croxon #define EFI_DRIVER_SUPPORTED EFI_DRIVER_BINDING_PROTOCOL_SUPPORTED 876*8118d087SNigel Croxon #define EFI_DRIVER_START EFI_DRIVER_BINDING_PROTOCOL_START 877*8118d087SNigel Croxon #define EFI_DRIVER_STOP EFI_DRIVER_BINDING_PROTOCOL_STOP 878*8118d087SNigel Croxon #define _EFI_DRIVER_BINDING _EFI_DRIVER_BINDING_PROTOCOL 879*8118d087SNigel Croxon #define EFI_DRIVER_BINDING EFI_DRIVER_BINDING_PROTOCOL 880*8118d087SNigel Croxon 881*8118d087SNigel Croxon 882*8118d087SNigel Croxon 883*8118d087SNigel Croxon /* 884*8118d087SNigel Croxon * EFI Component Name Protocol 885*8118d087SNigel Croxon * Deprecated - use EFI Component Name 2 Protocol instead 886*8118d087SNigel Croxon */ 887*8118d087SNigel Croxon #define EFI_COMPONENT_NAME_PROTOCOL_GUID \ 888883702e8SNigel Croxon {0x107A772C, 0xD5E1, 0x11D4, { 0x9A, 0x46, 0x00, 0x90, 0x27, 0x3F, 0xC1, 0x4D} } 889883702e8SNigel Croxon 890*8118d087SNigel Croxon INTERFACE_DECL(_EFI_COMPONENT_NAME_PROTOCOL); 891883702e8SNigel Croxon 892883702e8SNigel Croxon typedef 893883702e8SNigel Croxon EFI_STATUS 894883702e8SNigel Croxon (EFIAPI *EFI_COMPONENT_NAME_GET_DRIVER_NAME) ( 895*8118d087SNigel Croxon IN struct _EFI_COMPONENT_NAME_PROTOCOL *This, 896883702e8SNigel Croxon IN CHAR8 *Language, 897883702e8SNigel Croxon OUT CHAR16 **DriverName); 898883702e8SNigel Croxon 899883702e8SNigel Croxon typedef 900883702e8SNigel Croxon EFI_STATUS 901883702e8SNigel Croxon (EFIAPI *EFI_COMPONENT_NAME_GET_CONTROLLER_NAME) ( 902*8118d087SNigel Croxon IN struct _EFI_COMPONENT_NAME_PROTOCOL *This, 903883702e8SNigel Croxon IN EFI_HANDLE ControllerHandle, 904883702e8SNigel Croxon IN EFI_HANDLE ChildHandle OPTIONAL, 905883702e8SNigel Croxon IN CHAR8 *Language, 906883702e8SNigel Croxon OUT CHAR16 **ControllerName); 907883702e8SNigel Croxon 908*8118d087SNigel Croxon typedef struct _EFI_COMPONENT_NAME_PROTOCOL { 909883702e8SNigel Croxon EFI_COMPONENT_NAME_GET_DRIVER_NAME GetDriverName; 910883702e8SNigel Croxon EFI_COMPONENT_NAME_GET_CONTROLLER_NAME GetControllerName; 911883702e8SNigel Croxon CHAR8 *SupportedLanguages; 912*8118d087SNigel Croxon } EFI_COMPONENT_NAME_PROTOCOL; 913883702e8SNigel Croxon 914883702e8SNigel Croxon 915*8118d087SNigel Croxon 916*8118d087SNigel Croxon /* 917*8118d087SNigel Croxon * Backwards compatibility with older GNU-EFI versions. Deprecated. 918*8118d087SNigel Croxon */ 919*8118d087SNigel Croxon #define COMPONENT_NAME_PROTOCOL EFI_COMPONENT_NAME_PROTOCOL_GUID 920*8118d087SNigel Croxon #define _EFI_COMPONENT_NAME _EFI_COMPONENT_NAME_PROTOCOL 921*8118d087SNigel Croxon #define EFI_COMPONENT_NAME EFI_COMPONENT_NAME_PROTOCOL 922*8118d087SNigel Croxon 923*8118d087SNigel Croxon 924*8118d087SNigel Croxon 925*8118d087SNigel Croxon /* 926*8118d087SNigel Croxon * EFI Component Name 2 Protocol 927*8118d087SNigel Croxon * UEFI Specification Version 2.5 Section 10.5 928*8118d087SNigel Croxon */ 929*8118d087SNigel Croxon #define EFI_COMPONENT_NAME2_PROTOCOL_GUID \ 930883702e8SNigel Croxon {0x6A7A5CFF, 0xE8D9, 0x4F70, { 0xBA, 0xDA, 0x75, 0xAB, 0x30, 0x25, 0xCE, 0x14} } 931883702e8SNigel Croxon 932*8118d087SNigel Croxon INTERFACE_DECL(_EFI_COMPONENT_NAME2_PROTOCOL); 933883702e8SNigel Croxon 934883702e8SNigel Croxon typedef 935883702e8SNigel Croxon EFI_STATUS 936883702e8SNigel Croxon (EFIAPI *EFI_COMPONENT_NAME2_GET_DRIVER_NAME) ( 937*8118d087SNigel Croxon IN struct _EFI_COMPONENT_NAME2_PROTOCOL *This, 938883702e8SNigel Croxon IN CHAR8 *Language, 939883702e8SNigel Croxon OUT CHAR16 **DriverName); 940883702e8SNigel Croxon 941883702e8SNigel Croxon typedef 942883702e8SNigel Croxon EFI_STATUS 943883702e8SNigel Croxon (EFIAPI *EFI_COMPONENT_NAME2_GET_CONTROLLER_NAME) ( 944*8118d087SNigel Croxon IN struct _EFI_COMPONENT_NAME2_PROTOCOL *This, 945883702e8SNigel Croxon IN EFI_HANDLE ControllerHandle, 946883702e8SNigel Croxon IN EFI_HANDLE ChildHandle OPTIONAL, 947883702e8SNigel Croxon IN CHAR8 *Language, 948883702e8SNigel Croxon OUT CHAR16 **ControllerName); 949883702e8SNigel Croxon 950*8118d087SNigel Croxon typedef struct _EFI_COMPONENT_NAME2_PROTOCOL { 951883702e8SNigel Croxon EFI_COMPONENT_NAME2_GET_DRIVER_NAME GetDriverName; 952883702e8SNigel Croxon EFI_COMPONENT_NAME2_GET_CONTROLLER_NAME GetControllerName; 953883702e8SNigel Croxon CHAR8 *SupportedLanguages; 954*8118d087SNigel Croxon } EFI_COMPONENT_NAME2_PROTOCOL; 955883702e8SNigel Croxon 9563b31a5e3SNigel Croxon 957*8118d087SNigel Croxon 958*8118d087SNigel Croxon /* 959*8118d087SNigel Croxon * Backwards compatibility with older GNU-EFI versions. Deprecated. 960*8118d087SNigel Croxon */ 961*8118d087SNigel Croxon #define COMPONENT_NAME2_PROTOCOL EFI_COMPONENT_NAME2_PROTOCOL_GUID 962*8118d087SNigel Croxon #define _EFI_COMPONENT_NAME2 _EFI_COMPONENT_NAME2_PROTOCOL 963*8118d087SNigel Croxon #define EFI_COMPONENT_NAME2 EFI_COMPONENT_NAME2_PROTOCOL 964*8118d087SNigel Croxon 965*8118d087SNigel Croxon 966*8118d087SNigel Croxon 967*8118d087SNigel Croxon /* 968*8118d087SNigel Croxon * EFI Loaded Image Protocol 969*8118d087SNigel Croxon * UEFI Specification Version 2.5 Section 8.1 970*8118d087SNigel Croxon */ 971*8118d087SNigel Croxon #define EFI_LOADED_IMAGE_PROTOCOL_GUID \ 9723b31a5e3SNigel Croxon { 0x5B1B31A1, 0x9562, 0x11d2, {0x8E, 0x3F, 0x00, 0xA0, 0xC9, 0x69, 0x72, 0x3B} } 9733b31a5e3SNigel Croxon 974*8118d087SNigel Croxon #define EFI_LOADED_IMAGE_PROTOCOL_REVISION 0x1000 975*8118d087SNigel Croxon 9763b31a5e3SNigel Croxon typedef 9773b31a5e3SNigel Croxon EFI_STATUS 9783b31a5e3SNigel Croxon (EFIAPI *EFI_IMAGE_UNLOAD) ( 9793b31a5e3SNigel Croxon IN EFI_HANDLE ImageHandle 9803b31a5e3SNigel Croxon ); 9813b31a5e3SNigel Croxon 9823b31a5e3SNigel Croxon typedef struct { 9833b31a5e3SNigel Croxon UINT32 Revision; 9843b31a5e3SNigel Croxon EFI_HANDLE ParentHandle; 9853b31a5e3SNigel Croxon struct _EFI_SYSTEM_TABLE *SystemTable; 9863b31a5e3SNigel Croxon 9873b31a5e3SNigel Croxon // Source location of image 9883b31a5e3SNigel Croxon EFI_HANDLE DeviceHandle; 9893b31a5e3SNigel Croxon EFI_DEVICE_PATH *FilePath; 9903b31a5e3SNigel Croxon VOID *Reserved; 9913b31a5e3SNigel Croxon 9923b31a5e3SNigel Croxon // Images load options 9933b31a5e3SNigel Croxon UINT32 LoadOptionsSize; 9943b31a5e3SNigel Croxon VOID *LoadOptions; 9953b31a5e3SNigel Croxon 9963b31a5e3SNigel Croxon // Location of where image was loaded 9973b31a5e3SNigel Croxon VOID *ImageBase; 9983b31a5e3SNigel Croxon UINT64 ImageSize; 9993b31a5e3SNigel Croxon EFI_MEMORY_TYPE ImageCodeType; 10003b31a5e3SNigel Croxon EFI_MEMORY_TYPE ImageDataType; 10013b31a5e3SNigel Croxon 10023b31a5e3SNigel Croxon // If the driver image supports a dynamic unload request 10033b31a5e3SNigel Croxon EFI_IMAGE_UNLOAD Unload; 1004*8118d087SNigel Croxon } EFI_LOADED_IMAGE_PROTOCOL; 10053b31a5e3SNigel Croxon 10063b31a5e3SNigel Croxon 10079b0fe34eSNigel Croxon 1008*8118d087SNigel Croxon /* 1009*8118d087SNigel Croxon * Backwards compatibility with older GNU-EFI versions. Deprecated. 1010*8118d087SNigel Croxon */ 1011*8118d087SNigel Croxon #define LOADED_IMAGE_PROTOCOL EFI_LOADED_IMAGE_PROTOCOL_GUID 1012*8118d087SNigel Croxon #define EFI_IMAGE_INFORMATION_REVISION EFI_LOADED_IMAGE_PROTOCOL_REVISION 1013*8118d087SNigel Croxon #define EFI_LOADED_IMAGE EFI_LOADED_IMAGE_PROTOCOL 1014*8118d087SNigel Croxon 1015*8118d087SNigel Croxon 1016*8118d087SNigel Croxon 1017*8118d087SNigel Croxon /* 1018*8118d087SNigel Croxon * Random Number Generator Protocol 1019*8118d087SNigel Croxon * UEFI Specification Version 2.5 Section 35.5 1020*8118d087SNigel Croxon */ 10219b0fe34eSNigel Croxon #define EFI_RNG_PROTOCOL_GUID \ 10229b0fe34eSNigel Croxon { 0x3152bca5, 0xeade, 0x433d, {0x86, 0x2e, 0xc0, 0x1c, 0xdc, 0x29, 0x1f, 0x44} } 10239b0fe34eSNigel Croxon 10249b0fe34eSNigel Croxon typedef EFI_GUID EFI_RNG_ALGORITHM; 10259b0fe34eSNigel Croxon 10269b0fe34eSNigel Croxon #define EFI_RNG_ALGORITHM_SP800_90_HASH_256_GUID \ 10279b0fe34eSNigel Croxon {0xa7af67cb, 0x603b, 0x4d42, {0xba, 0x21, 0x70, 0xbf, 0xb6, 0x29, 0x3f, 0x96} } 10289b0fe34eSNigel Croxon 10299b0fe34eSNigel Croxon #define EFI_RNG_ALGORITHM_SP800_90_HMAC_256_GUID \ 10309b0fe34eSNigel Croxon {0xc5149b43, 0xae85, 0x4f53, {0x99, 0x82, 0xb9, 0x43, 0x35, 0xd3, 0xa9, 0xe7} } 10319b0fe34eSNigel Croxon 10329b0fe34eSNigel Croxon #define EFI_RNG_ALGORITHM_SP800_90_CTR_256_GUID \ 10339b0fe34eSNigel Croxon {0x44f0de6e, 0x4d8c, 0x4045, {0xa8, 0xc7, 0x4d, 0xd1, 0x68, 0x85, 0x6b, 0x9e} } 10349b0fe34eSNigel Croxon 10359b0fe34eSNigel Croxon #define EFI_RNG_ALGORITHM_X9_31_3DES_GUID \ 10369b0fe34eSNigel Croxon {0x63c4785a, 0xca34, 0x4012, {0xa3, 0xc8, 0x0b, 0x6a, 0x32, 0x4f, 0x55, 0x46} } 10379b0fe34eSNigel Croxon 10389b0fe34eSNigel Croxon #define EFI_RNG_ALGORITHM_X9_31_AES_GUID \ 10399b0fe34eSNigel Croxon {0xacd03321, 0x777e, 0x4d3d, {0xb1, 0xc8, 0x20, 0xcf, 0xd8, 0x88, 0x20, 0xc9} } 10409b0fe34eSNigel Croxon 10419b0fe34eSNigel Croxon #define EFI_RNG_ALGORITHM_RAW \ 10429b0fe34eSNigel Croxon {0xe43176d7, 0xb6e8, 0x4827, {0xb7, 0x84, 0x7f, 0xfd, 0xc4, 0xb6, 0x85, 0x61} } 10439b0fe34eSNigel Croxon 10449b0fe34eSNigel Croxon INTERFACE_DECL(_EFI_RNG_PROTOCOL); 10459b0fe34eSNigel Croxon 10469b0fe34eSNigel Croxon typedef 10479b0fe34eSNigel Croxon EFI_STATUS 10489b0fe34eSNigel Croxon (EFIAPI *EFI_RNG_GET_INFO) ( 10499b0fe34eSNigel Croxon IN struct _EFI_RNG_PROTOCOL *This, 10509b0fe34eSNigel Croxon IN OUT UINTN *RNGAlgorithmListSize, 10519b0fe34eSNigel Croxon OUT EFI_RNG_ALGORITHM *RNGAlgorithmList 10529b0fe34eSNigel Croxon ); 10539b0fe34eSNigel Croxon 10549b0fe34eSNigel Croxon typedef 10559b0fe34eSNigel Croxon EFI_STATUS 10569b0fe34eSNigel Croxon (EFIAPI *EFI_RNG_GET_RNG) ( 10579b0fe34eSNigel Croxon IN struct _EFI_RNG_PROTOCOL *This, 10589b0fe34eSNigel Croxon IN EFI_RNG_ALGORITHM *RNGAlgorithm, OPTIONAL 10599b0fe34eSNigel Croxon IN UINTN RNGValueLength, 10609b0fe34eSNigel Croxon OUT UINT8 *RNGValue 10619b0fe34eSNigel Croxon ); 10629b0fe34eSNigel Croxon 10639b0fe34eSNigel Croxon typedef struct _EFI_RNG_PROTOCOL { 10649b0fe34eSNigel Croxon EFI_RNG_GET_INFO GetInfo; 10659b0fe34eSNigel Croxon EFI_RNG_GET_RNG GetRNG; 10669b0fe34eSNigel Croxon } EFI_RNG_PROTOCOL; 10679b0fe34eSNigel Croxon 10689b0fe34eSNigel Croxon 106963213a7bSNigel Croxon // 107063213a7bSNigel Croxon // EFI_PLATFORM_DRIVER_OVERRIDE_PROTOCOL 107163213a7bSNigel Croxon // 107263213a7bSNigel Croxon 107363213a7bSNigel Croxon #define EFI_PLATFORM_DRIVER_OVERRIDE_PROTOCOL_GUID \ 107463213a7bSNigel Croxon { 0x6b30c738, 0xa391, 0x11d4, {0x9a, 0x3b, 0x00, 0x90, 0x27, 0x3f, 0xc1, 0x4d} } 107563213a7bSNigel Croxon 107663213a7bSNigel Croxon INTERFACE_DECL(_EFI_PLATFORM_DRIVER_OVERRIDE_PROTOCOL); 107763213a7bSNigel Croxon 107863213a7bSNigel Croxon typedef 107963213a7bSNigel Croxon EFI_STATUS 108063213a7bSNigel Croxon (EFIAPI *EFI_PLATFORM_DRIVER_OVERRIDE_GET_DRIVER) ( 108163213a7bSNigel Croxon IN struct _EFI_PLATFORM_DRIVER_OVERRIDE_PROTOCOL *This, 108263213a7bSNigel Croxon IN EFI_HANDLE ControllerHandle, 108363213a7bSNigel Croxon IN OUT EFI_HANDLE *DriverImageHandle); 108463213a7bSNigel Croxon 108563213a7bSNigel Croxon typedef 108663213a7bSNigel Croxon EFI_STATUS 108763213a7bSNigel Croxon (EFIAPI *EFI_PLATFORM_DRIVER_OVERRIDE_GET_DRIVER_PATH) ( 108863213a7bSNigel Croxon IN struct _EFI_PLATFORM_DRIVER_OVERRIDE_PROTOCOL *This, 108963213a7bSNigel Croxon IN EFI_HANDLE ControllerHandle, 109063213a7bSNigel Croxon IN OUT EFI_DEVICE_PATH **DriverImagePath); 109163213a7bSNigel Croxon 109263213a7bSNigel Croxon typedef 109363213a7bSNigel Croxon EFI_STATUS 109463213a7bSNigel Croxon (EFIAPI *EFI_PLATFORM_DRIVER_OVERRIDE_DRIVER_LOADED) ( 109563213a7bSNigel Croxon IN struct _EFI_PLATFORM_DRIVER_OVERRIDE_PROTOCOL *This, 109663213a7bSNigel Croxon IN EFI_HANDLE ControllerHandle, 109763213a7bSNigel Croxon IN EFI_DEVICE_PATH *DriverImagePath, 109863213a7bSNigel Croxon IN EFI_HANDLE DriverImageHandle); 109963213a7bSNigel Croxon 110063213a7bSNigel Croxon typedef struct _EFI_PLATFORM_DRIVER_OVERRIDE_PROTOCOL { 110163213a7bSNigel Croxon EFI_PLATFORM_DRIVER_OVERRIDE_GET_DRIVER GetDriver; 110263213a7bSNigel Croxon EFI_PLATFORM_DRIVER_OVERRIDE_GET_DRIVER_PATH GetDriverPath; 110363213a7bSNigel Croxon EFI_PLATFORM_DRIVER_OVERRIDE_DRIVER_LOADED DriverLoaded; 110463213a7bSNigel Croxon } EFI_PLATFORM_DRIVER_OVERRIDE_PROTOCOL; 110563213a7bSNigel Croxon 110663213a7bSNigel Croxon // 110763213a7bSNigel Croxon // EFI_BUS_SPECIFIC_DRIVER_OVERRIDE_PROTOCOL 110863213a7bSNigel Croxon // 110963213a7bSNigel Croxon 111063213a7bSNigel Croxon #define EFI_BUS_SPECIFIC_DRIVER_OVERRIDE_PROTOCOL_GUID \ 111163213a7bSNigel Croxon { 0x3bc1b285, 0x8a15, 0x4a82, {0xaa, 0xbf, 0x4d, 0x7d, 0x13, 0xfb, 0x32, 0x65} } 111263213a7bSNigel Croxon 111363213a7bSNigel Croxon INTERFACE_DECL(_EFI_BUS_SPECIFIC_DRIVER_OVERRIDE_PROTOCOL); 111463213a7bSNigel Croxon 111563213a7bSNigel Croxon typedef 111663213a7bSNigel Croxon EFI_STATUS 111763213a7bSNigel Croxon (EFIAPI *EFI_BUS_SPECIFIC_DRIVER_OVERRIDE_GET_DRIVER) ( 111863213a7bSNigel Croxon IN struct _EFI_BUS_SPECIFIC_DRIVER_OVERRIDE_PROTOCOL *This, 111963213a7bSNigel Croxon IN OUT EFI_HANDLE *DriverImageHandle); 112063213a7bSNigel Croxon 112163213a7bSNigel Croxon typedef struct _EFI_BUS_SPECIFIC_DRIVER_OVERRIDE_PROTOCOL { 112263213a7bSNigel Croxon EFI_BUS_SPECIFIC_DRIVER_OVERRIDE_GET_DRIVER GetDriver; 112363213a7bSNigel Croxon } EFI_BUS_SPECIFIC_DRIVER_OVERRIDE_PROTOCOL; 112463213a7bSNigel Croxon 112563213a7bSNigel Croxon // 112663213a7bSNigel Croxon // EFI_DRIVER_FAMILY_OVERRIDE_PROTOCOL 112763213a7bSNigel Croxon // 112863213a7bSNigel Croxon 112963213a7bSNigel Croxon #define EFI_DRIVER_FAMILY_OVERRIDE_PROTOCOL_GUID \ 113063213a7bSNigel Croxon { 0xb1ee129e, 0xda36, 0x4181, {0x91, 0xf8, 0x04, 0xa4, 0x92, 0x37, 0x66, 0xa7} } 113163213a7bSNigel Croxon 113263213a7bSNigel Croxon INTERFACE_DECL(_EFI_DRIVER_FAMILY_OVERRIDE_PROTOCOL); 113363213a7bSNigel Croxon 113463213a7bSNigel Croxon typedef 113563213a7bSNigel Croxon UINT32 113663213a7bSNigel Croxon (EFIAPI *EFI_DRIVER_FAMILY_OVERRIDE_GET_VERSION) ( 113763213a7bSNigel Croxon IN struct _EFI_DRIVER_FAMILY_OVERRIDE_PROTOCOL *This); 113863213a7bSNigel Croxon 113963213a7bSNigel Croxon typedef struct _EFI_DRIVER_FAMILY_OVERRIDE_PROTOCOL { 114063213a7bSNigel Croxon EFI_DRIVER_FAMILY_OVERRIDE_GET_VERSION GetVersion; 114163213a7bSNigel Croxon } EFI_DRIVER_FAMILY_OVERRIDE_PROTOCOL; 114263213a7bSNigel Croxon 114363213a7bSNigel Croxon 1144530d68baSNigel Croxon #endif 1145530d68baSNigel Croxon 1146