diff --git a/.DS_Store b/.DS_Store new file mode 100644 index 0000000..544a01e Binary files /dev/null and b/.DS_Store differ diff --git a/efi_types.h b/efi_types.h index e6b66ab..c56fb5e 100644 --- a/efi_types.h +++ b/efi_types.h @@ -2,35 +2,35 @@ #define EFI_TYPES_H // Standard Data types -typedef char int8_t; -typedef unsigned char uint8_t; -typedef short int16_t; -typedef unsigned short uint16_t; -typedef int int32_t; -typedef unsigned int uint32_t; +typedef char efi_int8_t; +typedef unsigned char efi_uint8_t; +typedef short efi_int16_t; +typedef unsigned short efi_uint16_t; +typedef efi_int efi_int32_t; +typedef unsigned efi_int efi_uint32_t; #if defined(_X64) -typedef long int64_t; -typedef unsigned long uint64_t; +typedef long efi_int64_t; +typedef unsigned long efi_uint64_t; #elif defined (_X32) -typedef long long int64_t; -typedef unsigned long long uint64_t; +typedef long long efi_int64_t; +typedef unsigned long long efi_uint64_t; #else #error _X32/_X64 is undefined! #endif // Common UEFI Data types -typedef int8_t EFI_INT8; -typedef uint8_t EFI_UINT8; -typedef int16_t EFI_INT16; -typedef uint16_t EFI_UINT16; -typedef int32_t EFI_INT32; -typedef uint32_t EFI_UINT32; -typedef int64_t EFI_INT64; -typedef uint64_t EFI_UINT64; -typedef int64_t EFI_INTN; -typedef uint64_t EFI_UINTN; +typedef efi_int8_t EFI_INT8; +typedef efi_uint8_t EFI_UINT8; +typedef efi_int16_t EFI_INT16; +typedef efi_uint16_t EFI_UINT16; +typedef efi_int32_t EFI_INT32; +typedef efi_uint32_t EFI_UINT32; +typedef efi_int64_t EFI_INT64; +typedef efi_uint64_t EFI_UINT64; +typedef efi_int64_t EFI_INTN; +typedef efi_uint64_t EFI_UINTN; typedef char CHAR8; -typedef uint16_t CHAR16; +typedef efi_uint16_t CHAR16; typedef void VOID; typedef EFI_INT32 EFI_INT; @@ -177,7 +177,7 @@ typedef struct { #define EFI_BACKGROUND_BROWN 0x60 #define EFI_BACKGROUND_LIGHTGRAY 0x70 -// Converts Foreground and Background colors into a single value +// Converts Foreground and Background colors efi_into a single value #define EFI_TEXT_ATTR(Foreground,Background) \ ((Foreground) | ((Background) << 4)) diff --git a/protocols/acpi_table.h b/protocols/acpi_table.h new file mode 100644 index 0000000..4223352 --- /dev/null +++ b/protocols/acpi_table.h @@ -0,0 +1,33 @@ +#ifndef EFI_PROTOCOLS_ACPI_H +#define EFI_PROTOCOLS_ACPI_H + +//// +// ACPI Table Protocol +/// + +#define EFI_ACPI_TABLE_PROTOCOL_GUID {0xffe06bdd,0x6107,0x46a6, {0x7b,0xb2,0x5a,0x9c,0x7e,0xc5,0x27,0x5c}} + +typedef struct _EFI_ACPI_TABLE_PROTOCOL EFI_ACPI_TABLE_PROTOCOL; + +typedef +EFI_STATUS +(EFIAPI *EFI_ACPI_TABLE_INSTALL_ACPI_TABLE)( + IN EFI_ACPI_TABLE_PROTOCOL *This, + IN VOID *AcpiTableBuffer, + IN UINTN AcpiTableBufferSize, + OUT UINTN *TableKey +); + +typedef +EFI_STATUS +(EFIAPI *EFI_ACPI_TABLE_UNINSTALL_ACPI_TABLE)( + IN EFI_ACPI_TABLE_PROTOCOL *This, + IN UINTN TableKey +); + +typedef struct _EFI_ACPI_TABLE_PROTOCOL { + EFI_ACPI_TABLE_INSTALL_ACPI_TABLE InstallAcpiTable; + EFI_ACPI_TABLE_UNINSTALL_ACPI_TABLE UninstallAcpiTable; +} EFI_ACPI_TABLE_PROTOCOL; + +#endif /* EFI_PROTOCOLS_ACPI_H */