diff options
author | imp <imp@FreeBSD.org> | 2015-02-20 01:40:55 +0000 |
---|---|---|
committer | imp <imp@FreeBSD.org> | 2015-02-20 01:40:55 +0000 |
commit | 61f8188c8c1d2f26d679a3d943c15046056f1cda (patch) | |
tree | 51593f4e6b3403843618a1e71c33414612ee6969 /sys/boot/efi | |
parent | 579c83b67c6c51404a77fc446b06fc046f541031 (diff) | |
download | FreeBSD-src-61f8188c8c1d2f26d679a3d943c15046056f1cda.zip FreeBSD-src-61f8188c8c1d2f26d679a3d943c15046056f1cda.tar.gz |
Allow EFI and ACPI to be included together. When ACPI is included
first, EFI will use its definitions for {,U}INT{8,16,32,64} and
BOOLEAN. When EFI is included first, define ACPI_USE_SYSTEM_INTTYPES
to tell ACPI that these are already defined.
Differential Revision: https://reviews.freebsd.org/D1905
Diffstat (limited to 'sys/boot/efi')
-rw-r--r-- | sys/boot/efi/include/amd64/efibind.h | 4 | ||||
-rw-r--r-- | sys/boot/efi/include/efidef.h | 2 | ||||
-rw-r--r-- | sys/boot/efi/include/i386/efibind.h | 4 |
3 files changed, 10 insertions, 0 deletions
diff --git a/sys/boot/efi/include/amd64/efibind.h b/sys/boot/efi/include/amd64/efibind.h index 1905596..3d70b58a 100644 --- a/sys/boot/efi/include/amd64/efibind.h +++ b/sys/boot/efi/include/amd64/efibind.h @@ -85,6 +85,9 @@ Revision History // Basic EFI types of various widths // +#ifndef ACPI_THREAD_ID /* ACPI's definitions are fine */ +#define ACPI_USE_SYSTEM_INTTYPES 1 /* Tell ACPI we've defined types */ + typedef uint64_t UINT64; typedef int64_t INT64; @@ -98,6 +101,7 @@ typedef int16_t INT16; typedef uint8_t UINT8; typedef int8_t INT8; +#endif #undef VOID #define VOID void diff --git a/sys/boot/efi/include/efidef.h b/sys/boot/efi/include/efidef.h index 2d5d7ef..a770f03 100644 --- a/sys/boot/efi/include/efidef.h +++ b/sys/boot/efi/include/efidef.h @@ -30,7 +30,9 @@ Revision History typedef UINT16 CHAR16; typedef UINT8 CHAR8; +#ifndef ACPI_THREAD_ID /* ACPI's definitions are fine */ typedef UINT8 BOOLEAN; +#endif #ifndef TRUE #define TRUE ((BOOLEAN) 1) diff --git a/sys/boot/efi/include/i386/efibind.h b/sys/boot/efi/include/i386/efibind.h index f28057b..de3658f 100644 --- a/sys/boot/efi/include/i386/efibind.h +++ b/sys/boot/efi/include/i386/efibind.h @@ -85,6 +85,9 @@ Revision History // Basic EFI types of various widths // +#ifndef ACPI_THREAD_ID /* ACPI's definitions are fine, use those */ +#define ACPI_USE_SYSTEM_INTTYPES 1 /* Tell ACPI we've defined types */ + typedef uint64_t UINT64; typedef int64_t INT64; @@ -98,6 +101,7 @@ typedef int16_t INT16; typedef uint8_t UINT8; typedef int8_t INT8; +#endif #undef VOID #define VOID void |