2013-01-31 01:25:25 +04:00
|
|
|
/*++
|
|
|
|
|
|
|
|
Copyright (c) 1998 Intel Corporation
|
|
|
|
|
|
|
|
Module Name:
|
|
|
|
|
|
|
|
efi.h
|
|
|
|
|
|
|
|
Abstract:
|
|
|
|
|
|
|
|
Public EFI header files
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
Revision History
|
|
|
|
|
|
|
|
--*/
|
|
|
|
|
Update global protocol GUIDs definitions to match EDK2
This patch introduces the use of the EDK2 names for the global GUID
variables, to allow for easier code conversion between EDK2 and
gnu-efi. All the existing GUID global variables have also been
aliased for backwards compatibility.
The patch also completes some of the earlier work with regards to
protocol struct definitions to also match the EDK2, with the
following caveat:
Because some of gnu-efi GUID macro definitions were declared with
the name that the EDK2 uses for the protocol struct itself, we have
to immediately deprecate the following GUID data aliases:
EFI_NETWORK_INTERFACE_IDENTIFIER_PROTOCOL
EFI_SIMPLE_NETWORK_PROTOCOL
EFI_PCI_IO_PROTOCOL
EFI_PXE_BASE_CODE_CALLBACK_PROTOCOL
This means that existing code using one of the above will break
on compilation. To mitigate this, explicit warnings have been
placed at the location where a developer will look for breakage,
detailing how they should amend their code.
The KnownGuids short labels in guid.c were also updated/amended
in a manner that should be a bit more consistent (though I have
no idea what the EDK2 does here, since I haven't looked at the
actual EDK2 source).
Finally, besides clean up (typo, whitespaces, duplicate removal),
we introduce the _GNU_EFI macro, in efi.h, to allow for conditional
selection of specific gnu-efi API calls, in code that may be
compiled with either EDK2 or gnu-efi.
Signed-off-by: Pete Batard <pete@akeo.ie>
Signed-off-by: Nigel Croxon <nigel.croxon@hpe.com>
2016-08-18 15:42:11 +03:00
|
|
|
|
|
|
|
// Add a predefined macro to detect usage of the library
|
|
|
|
#ifndef _GNU_EFI
|
|
|
|
#define _GNU_EFI
|
|
|
|
#endif
|
|
|
|
|
2013-01-31 01:25:25 +04:00
|
|
|
//
|
|
|
|
// Build flags on input
|
|
|
|
// EFI32
|
|
|
|
// EFI_DEBUG - Enable debugging code
|
|
|
|
// EFI_NT_EMULATOR - Building for running under NT
|
|
|
|
//
|
|
|
|
|
|
|
|
|
|
|
|
#ifndef _EFI_INCLUDE_
|
|
|
|
#define _EFI_INCLUDE_
|
|
|
|
|
2023-06-13 14:46:50 +03:00
|
|
|
#ifdef __cplusplus
|
|
|
|
extern "C" {
|
|
|
|
#endif
|
|
|
|
|
2024-07-16 12:32:02 +03:00
|
|
|
#if defined(__APPLE__)
|
|
|
|
#error "Mach-O toolchain isn't supported; please compile with an ELF toolchain from Homebrew"
|
|
|
|
#endif
|
|
|
|
|
2013-01-31 01:25:25 +04:00
|
|
|
#define EFI_FIRMWARE_VENDOR L"INTEL"
|
|
|
|
#define EFI_FIRMWARE_MAJOR_REVISION 12
|
|
|
|
#define EFI_FIRMWARE_MINOR_REVISION 33
|
|
|
|
#define EFI_FIRMWARE_REVISION ((EFI_FIRMWARE_MAJOR_REVISION <<16) | (EFI_FIRMWARE_MINOR_REVISION))
|
|
|
|
|
2021-02-17 02:48:16 +03:00
|
|
|
#if defined(_M_X64) || defined(__x86_64__) || defined(__amd64__)
|
|
|
|
#include "x86_64/efibind.h"
|
|
|
|
#elif defined(_M_IX86) || defined(__i386__)
|
|
|
|
#include "ia32/efibind.h"
|
|
|
|
#elif defined(_M_IA64) || defined(__ia64__)
|
|
|
|
#include "ia64/efibind.h"
|
|
|
|
#elif defined (_M_ARM64) || defined(__aarch64__)
|
|
|
|
#include "aarch64/efibind.h"
|
|
|
|
#elif defined (_M_ARM) || defined(__arm__)
|
|
|
|
#include "arm/efibind.h"
|
2022-01-13 12:29:10 +03:00
|
|
|
#elif defined (_M_MIPS64) || defined(__mips64__) || defined(__mips64)
|
2021-02-17 02:48:16 +03:00
|
|
|
#include "mips64el/efibind.h"
|
2021-03-19 19:38:42 +03:00
|
|
|
#elif defined (__riscv) && __riscv_xlen == 64
|
|
|
|
#include "riscv64/efibind.h"
|
2021-12-30 10:39:47 +03:00
|
|
|
#elif defined (__loongarch64)
|
|
|
|
#include "loongarch64/efibind.h"
|
2021-02-17 02:48:16 +03:00
|
|
|
#else
|
|
|
|
#error Usupported architecture
|
|
|
|
#endif
|
|
|
|
|
2016-03-25 20:32:54 +03:00
|
|
|
#include "eficompiler.h"
|
2013-01-31 01:25:25 +04:00
|
|
|
#include "efidef.h"
|
2024-04-24 19:12:04 +03:00
|
|
|
#include "legacy.h"
|
2013-01-31 01:25:25 +04:00
|
|
|
#include "efidevp.h"
|
|
|
|
#include "efipciio.h"
|
|
|
|
#include "efiprot.h"
|
|
|
|
#include "eficon.h"
|
2020-07-21 11:05:43 +03:00
|
|
|
#include "eficonex.h"
|
2013-01-31 01:25:25 +04:00
|
|
|
#include "efiser.h"
|
|
|
|
#include "efi_nii.h"
|
|
|
|
#include "efipxebc.h"
|
|
|
|
#include "efinet.h"
|
|
|
|
#include "efiapi.h"
|
|
|
|
#include "efifs.h"
|
|
|
|
#include "efierr.h"
|
|
|
|
#include "efiui.h"
|
2013-05-09 00:29:45 +04:00
|
|
|
#include "efiip.h"
|
|
|
|
#include "efiudp.h"
|
|
|
|
#include "efitcp.h"
|
2014-03-17 18:23:39 +04:00
|
|
|
#include "efipoint.h"
|
2020-11-15 10:12:25 +03:00
|
|
|
#include "efishell.h"
|
2013-01-31 01:25:25 +04:00
|
|
|
|
2023-06-13 14:46:50 +03:00
|
|
|
#ifdef __cplusplus
|
|
|
|
}
|
|
|
|
#endif
|
|
|
|
|
2013-01-31 01:25:25 +04:00
|
|
|
#endif
|