diff options
Diffstat (limited to 'source/include')
| -rw-r--r-- | source/include/acdebug.h | 4 | ||||
| -rw-r--r-- | source/include/acdisasm.h | 11 | ||||
| -rw-r--r-- | source/include/acevents.h | 4 | ||||
| -rw-r--r-- | source/include/acglobal.h | 10 | ||||
| -rw-r--r-- | source/include/acinterp.h | 2 | ||||
| -rw-r--r-- | source/include/aclocal.h | 1 | ||||
| -rw-r--r-- | source/include/acmacros.h | 4 | ||||
| -rw-r--r-- | source/include/acnamesp.h | 4 | ||||
| -rw-r--r-- | source/include/acparser.h | 2 | ||||
| -rw-r--r-- | source/include/acpixf.h | 2 | ||||
| -rw-r--r-- | source/include/acresrc.h | 4 | ||||
| -rw-r--r-- | source/include/acstruct.h | 2 | ||||
| -rw-r--r-- | source/include/actbl.h | 2 | ||||
| -rw-r--r-- | source/include/actbl1.h | 49 | ||||
| -rw-r--r-- | source/include/actbl2.h | 42 | ||||
| -rw-r--r-- | source/include/actbl3.h | 52 | ||||
| -rw-r--r-- | source/include/actypes.h | 4 | ||||
| -rw-r--r-- | source/include/acutils.h | 18 | ||||
| -rw-r--r-- | source/include/platform/acenv.h | 44 | ||||
| -rw-r--r-- | source/include/platform/acqnx.h | 74 |
20 files changed, 254 insertions, 81 deletions
diff --git a/source/include/acdebug.h b/source/include/acdebug.h index 63b8be88c0e32..8f3f47175b139 100644 --- a/source/include/acdebug.h +++ b/source/include/acdebug.h @@ -55,7 +55,7 @@ typedef struct acpi_db_command_info { - char *Name; /* Command Name */ + const char *Name; /* Command Name */ UINT8 MinArgs; /* Minimum arguments required */ } ACPI_DB_COMMAND_INFO; @@ -70,7 +70,7 @@ typedef struct acpi_db_command_help typedef struct acpi_db_argument_info { - char *Name; /* Argument Name */ + const char *Name; /* Argument Name */ } ACPI_DB_ARGUMENT_INFO; diff --git a/source/include/acdisasm.h b/source/include/acdisasm.h index e722416d514eb..3a066c8ee9aed 100644 --- a/source/include/acdisasm.h +++ b/source/include/acdisasm.h @@ -319,6 +319,7 @@ extern ACPI_DMTABLE_INFO AcpiDmTableInfoIort3[]; extern ACPI_DMTABLE_INFO AcpiDmTableInfoIort3a[]; extern ACPI_DMTABLE_INFO AcpiDmTableInfoIort3b[]; extern ACPI_DMTABLE_INFO AcpiDmTableInfoIort3c[]; +extern ACPI_DMTABLE_INFO AcpiDmTableInfoIort4[]; extern ACPI_DMTABLE_INFO AcpiDmTableInfoIortAcc[]; extern ACPI_DMTABLE_INFO AcpiDmTableInfoIortHdr[]; extern ACPI_DMTABLE_INFO AcpiDmTableInfoIortMap[]; @@ -808,22 +809,22 @@ AcpiDmGetExternalsFromFile ( void AcpiDmDumpInteger8 ( UINT8 Value, - char *Name); + const char *Name); void AcpiDmDumpInteger16 ( UINT16 Value, - char *Name); + const char *Name); void AcpiDmDumpInteger32 ( UINT32 Value, - char *Name); + const char *Name); void AcpiDmDumpInteger64 ( UINT64 Value, - char *Name); + const char *Name); void AcpiDmResourceTemplate ( @@ -935,7 +936,7 @@ AcpiDmSerialBusDescriptor ( void AcpiDmVendorCommon ( - char *Name, + const char *Name, UINT8 *ByteData, UINT32 Length, UINT32 Level); diff --git a/source/include/acevents.h b/source/include/acevents.h index 62bc0edeb2cb4..a14dbe57c1b20 100644 --- a/source/include/acevents.h +++ b/source/include/acevents.h @@ -273,10 +273,6 @@ AcpiEvDetachRegion ( BOOLEAN AcpiNsIsLocked); void -AcpiEvAssociateRegMethod ( - ACPI_OPERAND_OBJECT *RegionObj); - -void AcpiEvExecuteRegMethods ( ACPI_NAMESPACE_NODE *Node, ACPI_ADR_SPACE_TYPE SpaceId, diff --git a/source/include/acglobal.h b/source/include/acglobal.h index 11361c5d9ccac..1918e0c31f20c 100644 --- a/source/include/acglobal.h +++ b/source/include/acglobal.h @@ -189,6 +189,8 @@ extern const char *AcpiGbl_SleepStateNames[ACPI_S_STATE_COU extern const char *AcpiGbl_LowestDstateNames[ACPI_NUM_SxW_METHODS]; extern const char *AcpiGbl_HighestDstateNames[ACPI_NUM_SxD_METHODS]; extern const char *AcpiGbl_RegionTypes[ACPI_NUM_PREDEFINED_REGIONS]; +extern const char AcpiGbl_LowerHexDigits[]; +extern const char AcpiGbl_UpperHexDigits[]; extern const ACPI_OPCODE_INFO AcpiGbl_AmlOpInfo[AML_NUM_OPCODES]; @@ -370,6 +372,14 @@ ACPI_GLOBAL (ACPI_MUTEX, AcpiGbl_DbCommandComplete); #endif /* ACPI_DEBUGGER */ +#if defined (ACPI_DISASSEMBLER) || defined (ACPI_ASL_COMPILER) + +ACPI_GLOBAL (const char, *AcpiGbl_PldPanelList[]); +ACPI_GLOBAL (const char, *AcpiGbl_PldVerticalPositionList[]); +ACPI_GLOBAL (const char, *AcpiGbl_PldHorizontalPositionList[]); +ACPI_GLOBAL (const char, *AcpiGbl_PldShapeList[]); + +#endif /***************************************************************************** * diff --git a/source/include/acinterp.h b/source/include/acinterp.h index 454e8bafbe6bd..148e8d0cafe3e 100644 --- a/source/include/acinterp.h +++ b/source/include/acinterp.h @@ -69,7 +69,7 @@ typedef const struct acpi_exdump_info { UINT8 Opcode; UINT8 Offset; - char *Name; + const char *Name; } ACPI_EXDUMP_INFO; diff --git a/source/include/aclocal.h b/source/include/aclocal.h index 46d430a7ec2d4..48cff57676b57 100644 --- a/source/include/aclocal.h +++ b/source/include/aclocal.h @@ -1285,6 +1285,7 @@ typedef struct acpi_external_list #define ACPI_EXT_ORIGIN_FROM_FILE 0x02 /* External came from a file */ #define ACPI_EXT_INTERNAL_PATH_ALLOCATED 0x04 /* Deallocate internal path on completion */ #define ACPI_EXT_EXTERNAL_EMITTED 0x08 /* External() statement has been emitted */ +#define ACPI_EXT_ORIGIN_FROM_OPCODE 0x10 /* External came from a External() opcode */ typedef struct acpi_external_file diff --git a/source/include/acmacros.h b/source/include/acmacros.h index 13934129245f2..ecb8050b39cb3 100644 --- a/source/include/acmacros.h +++ b/source/include/acmacros.h @@ -264,6 +264,10 @@ #define ACPI_IS_MISALIGNED(value) (((ACPI_SIZE) value) & (sizeof(ACPI_SIZE)-1)) +/* Generic (power-of-two) rounding */ + +#define ACPI_IS_POWER_OF_TWO(a) (((a) & ((a) - 1)) == 0) + /* * Bitmask creation * Bit positions start at zero. diff --git a/source/include/acnamesp.h b/source/include/acnamesp.h index e3c089f0883b7..11ee70d044ed3 100644 --- a/source/include/acnamesp.h +++ b/source/include/acnamesp.h @@ -258,14 +258,14 @@ AcpiNsDumpEntry ( void AcpiNsDumpPathname ( ACPI_HANDLE Handle, - char *Msg, + const char *Msg, UINT32 Level, UINT32 Component); void AcpiNsPrintPathname ( UINT32 NumSegments, - char *Pathname); + const char *Pathname); ACPI_STATUS AcpiNsDumpOneObject ( diff --git a/source/include/acparser.h b/source/include/acparser.h index 26651280eb82d..dd2782199d008 100644 --- a/source/include/acparser.h +++ b/source/include/acparser.h @@ -171,7 +171,7 @@ const ACPI_OPCODE_INFO * AcpiPsGetOpcodeInfo ( UINT16 Opcode); -char * +const char * AcpiPsGetOpcodeName ( UINT16 Opcode); diff --git a/source/include/acpixf.h b/source/include/acpixf.h index 53adadcaf736a..0c7e021063449 100644 --- a/source/include/acpixf.h +++ b/source/include/acpixf.h @@ -46,7 +46,7 @@ /* Current ACPICA subsystem version in YYYYMMDD format */ -#define ACPI_CA_VERSION 0x20160212 +#define ACPI_CA_VERSION 0x20160318 #include "acconfig.h" #include "actypes.h" diff --git a/source/include/acresrc.h b/source/include/acresrc.h index cbce5dea60e1d..1d077caac09bd 100644 --- a/source/include/acresrc.h +++ b/source/include/acresrc.h @@ -130,7 +130,7 @@ typedef const struct acpi_rsdump_info { UINT8 Opcode; UINT8 Offset; - char *Name; + const char *Name; const char **Pointer; } ACPI_RSDUMP_INFO; @@ -227,7 +227,7 @@ AcpiRsGetPrsMethodData ( ACPI_STATUS AcpiRsGetMethodData ( ACPI_HANDLE Handle, - char *Path, + const char *Path, ACPI_BUFFER *RetBuffer); ACPI_STATUS diff --git a/source/include/acstruct.h b/source/include/acstruct.h index e1d8fa58dc719..f7538aded9b2f 100644 --- a/source/include/acstruct.h +++ b/source/include/acstruct.h @@ -202,7 +202,7 @@ typedef struct acpi_evaluate_info /* The first 3 elements are passed by the caller to AcpiNsEvaluate */ ACPI_NAMESPACE_NODE *PrefixNode; /* Input: starting node */ - char *RelativePathname; /* Input: path relative to PrefixNode */ + const char *RelativePathname; /* Input: path relative to PrefixNode */ ACPI_OPERAND_OBJECT **Parameters; /* Input: argument list */ ACPI_NAMESPACE_NODE *Node; /* Resolved node (PrefixNode:RelativePathname) */ diff --git a/source/include/actbl.h b/source/include/actbl.h index 6aa1df2e64900..faeb744962eb3 100644 --- a/source/include/actbl.h +++ b/source/include/actbl.h @@ -449,4 +449,6 @@ typedef struct acpi_table_desc #define ACPI_FADT_V5_SIZE (UINT32) (ACPI_FADT_OFFSET (HypervisorId)) #define ACPI_FADT_V6_SIZE (UINT32) (sizeof (ACPI_TABLE_FADT)) +#define ACPI_FADT_CONFORMANCE "ACPI 6.1 (FADT version 6)" + #endif /* __ACTBL_H__ */ diff --git a/source/include/actbl1.h b/source/include/actbl1.h index df5abe353962f..0fe925a84bf50 100644 --- a/source/include/actbl1.h +++ b/source/include/actbl1.h @@ -581,7 +581,11 @@ enum AcpiHestNotifyTypes ACPI_HEST_NOTIFY_NMI = 4, ACPI_HEST_NOTIFY_CMCI = 5, /* ACPI 5.0 */ ACPI_HEST_NOTIFY_MCE = 6, /* ACPI 5.0 */ - ACPI_HEST_NOTIFY_RESERVED = 7 /* 7 and greater are reserved */ + ACPI_HEST_NOTIFY_GPIO = 7, /* ACPI 6.0 */ + ACPI_HEST_NOTIFY_SEA = 8, /* ACPI 6.1 */ + ACPI_HEST_NOTIFY_SEI = 9, /* ACPI 6.1 */ + ACPI_HEST_NOTIFY_GSIV = 10, /* ACPI 6.1 */ + ACPI_HEST_NOTIFY_RESERVED = 11 /* 11 and greater are reserved */ }; /* Values for ConfigWriteEnable bitfield above */ @@ -754,10 +758,38 @@ typedef struct acpi_hest_generic_data UINT32 ErrorDataLength; UINT8 FruId[16]; UINT8 FruText[20]; - UINT64 TimeStamp; } ACPI_HEST_GENERIC_DATA; +/* Extension for revision 0x0300 */ + +typedef struct acpi_hest_generic_data_v300 +{ + UINT8 SectionType[16]; + UINT32 ErrorSeverity; + UINT16 Revision; + UINT8 ValidationBits; + UINT8 Flags; + UINT32 ErrorDataLength; + UINT8 FruId[16]; + UINT8 FruText[20]; + UINT64 TimeStamp; + +} ACPI_HEST_GENERIC_DATA_V300; + +/* Values for ErrorSeverity above */ + +#define ACPI_HEST_GEN_ERROR_RECOVERABLE 0 +#define ACPI_HEST_GEN_ERROR_FATAL 1 +#define ACPI_HEST_GEN_ERROR_CORRECTED 2 +#define ACPI_HEST_GEN_ERROR_NONE 3 + +/* Flags for ValidationBits above */ + +#define ACPI_HEST_GEN_VALID_FRU_ID (1) +#define ACPI_HEST_GEN_VALID_FRU_STRING (1<<1) +#define ACPI_HEST_GEN_VALID_TIMESTAMP (1<<2) + /******************************************************************************* * @@ -1120,7 +1152,7 @@ typedef struct acpi_msct_proximity /******************************************************************************* * - * NFIT - NVDIMM Interface Table (ACPI 6.0) + * NFIT - NVDIMM Interface Table (ACPI 6.0+) * Version 1 * ******************************************************************************/ @@ -1252,7 +1284,10 @@ typedef struct acpi_nfit_control_region UINT16 SubsystemVendorId; UINT16 SubsystemDeviceId; UINT16 SubsystemRevisionId; - UINT8 Reserved[6]; /* Reserved, must be zero */ + UINT8 ValidFields; + UINT8 ManufacturingLocation; + UINT16 ManufacturingDate; + UINT8 Reserved[2]; /* Reserved, must be zero */ UINT32 SerialNumber; UINT16 Code; UINT16 Windows; @@ -1268,7 +1303,11 @@ typedef struct acpi_nfit_control_region /* Flags */ -#define ACPI_NFIT_CONTROL_BUFFERED (1) /* Block Data Windows implementation is buffered */ +#define ACPI_NFIT_CONTROL_BUFFERED (1) /* Block Data Windows implementation is buffered */ + +/* ValidFields bits */ + +#define ACPI_NFIT_CONTROL_MFG_INFO_VALID (1) /* Manufacturing fields are valid */ /* 5: NVDIMM Block Data Window Region Structure */ diff --git a/source/include/actbl2.h b/source/include/actbl2.h index 2a955bac46303..625d33fab9ce9 100644 --- a/source/include/actbl2.h +++ b/source/include/actbl2.h @@ -364,7 +364,7 @@ typedef struct acpi_csrt_descriptor * DBG2 - Debug Port Table 2 * Version 0 (Both main table and subtables) * - * Conforms to "Microsoft Debug Port Table 2 (DBG2)", May 22 2012. + * Conforms to "Microsoft Debug Port Table 2 (DBG2)", December 10, 2015 * ******************************************************************************/ @@ -421,6 +421,11 @@ typedef struct acpi_dbg2_device #define ACPI_DBG2_16550_COMPATIBLE 0x0000 #define ACPI_DBG2_16550_SUBSET 0x0001 +#define ACPI_DBG2_ARM_PL011 0x0003 +#define ACPI_DBG2_ARM_SBSA_32BIT 0x000D +#define ACPI_DBG2_ARM_SBSA_GENERIC 0x000E +#define ACPI_DBG2_ARM_DCC 0x000F +#define ACPI_DBG2_BCM2835 0x0010 #define ACPI_DBG2_1394_STANDARD 0x0000 @@ -453,7 +458,7 @@ typedef struct acpi_table_dbgp * Version 1 * * Conforms to "Intel Virtualization Technology for Directed I/O", - * Version 2.2, Sept. 2013 + * Version 2.3, October 2014 * ******************************************************************************/ @@ -469,6 +474,8 @@ typedef struct acpi_table_dmar /* Masks for Flags field above */ #define ACPI_DMAR_INTR_REMAP (1) +#define ACPI_DMAR_X2APIC_OPT_OUT (1<<1) +#define ACPI_DMAR_X2APIC_MODE (1<<2) /* DMAR subtable header */ @@ -757,7 +764,7 @@ typedef struct acpi_ibft_target * IORT - IO Remapping Table * * Conforms to "IO Remapping Table System Software on ARM Platforms", - * Document number: ARM DEN 0049A, 2015 + * Document number: ARM DEN 0049B, October 2015 * ******************************************************************************/ @@ -793,7 +800,8 @@ enum AcpiIortNodeType ACPI_IORT_NODE_ITS_GROUP = 0x00, ACPI_IORT_NODE_NAMED_COMPONENT = 0x01, ACPI_IORT_NODE_PCI_ROOT_COMPLEX = 0x02, - ACPI_IORT_NODE_SMMU = 0x03 + ACPI_IORT_NODE_SMMU = 0x03, + ACPI_IORT_NODE_SMMU_V3 = 0x04 }; @@ -902,6 +910,26 @@ typedef struct acpi_iort_smmu #define ACPI_IORT_SMMU_COHERENT_WALK (1<<1) +typedef struct acpi_iort_smmu_v3 +{ + UINT64 BaseAddress; /* SMMUv3 base address */ + UINT32 Flags; + UINT32 Reserved; + UINT64 VatosAddress; + UINT32 Model; /* O: generic SMMUv3 */ + UINT32 EventGsiv; + UINT32 PriGsiv; + UINT32 GerrGsiv; + UINT32 SyncGsiv; + +} ACPI_IORT_SMMU_V3; + +/* Masks for Flags field above */ + +#define ACPI_IORT_SMMU_V3_COHACC_OVERRIDE (1) +#define ACPI_IORT_SMMU_V3_HTTU_OVERRIDE (1<<1) + + /******************************************************************************* * * IVRS - I/O Virtualization Reporting Structure @@ -1284,10 +1312,10 @@ typedef struct acpi_table_slic /******************************************************************************* * * SPCR - Serial Port Console Redirection table - * Version 1 + * Version 2 * * Conforms to "Serial Port Console Redirection Table", - * Version 1.00, January 11, 2002 + * Version 1.03, August 10, 2015 * ******************************************************************************/ @@ -1321,6 +1349,8 @@ typedef struct acpi_table_spcr #define ACPI_SPCR_DO_NOT_DISABLE (1) +/* Values for Interface Type: See the definition of the DBG2 table */ + /******************************************************************************* * diff --git a/source/include/actbl3.h b/source/include/actbl3.h index c27bb9619178d..bc876a9e781b9 100644 --- a/source/include/actbl3.h +++ b/source/include/actbl3.h @@ -205,7 +205,7 @@ typedef struct acpi_table_fpdt } ACPI_TABLE_FPDT; -/* FPDT subtable header */ +/* FPDT subtable header (Performance Record Structure) */ typedef struct acpi_fpdt_header { @@ -230,33 +230,29 @@ enum AcpiFpdtType /* 0: Firmware Basic Boot Performance Record */ -typedef struct acpi_fpdt_boot +typedef struct acpi_fpdt_boot_pointer { ACPI_FPDT_HEADER Header; UINT8 Reserved[4]; - UINT64 ResetEnd; - UINT64 LoadStart; - UINT64 StartupStart; - UINT64 ExitServicesEntry; - UINT64 ExitServicesExit; + UINT64 Address; -} ACPI_FPDT_BOOT; +} ACPI_FPDT_BOOT_POINTER; /* 1: S3 Performance Table Pointer Record */ -typedef struct acpi_fpdt_s3pt_ptr +typedef struct acpi_fpdt_s3pt_pointer { ACPI_FPDT_HEADER Header; UINT8 Reserved[4]; UINT64 Address; -} ACPI_FPDT_S3PT_PTR; +} ACPI_FPDT_S3PT_POINTER; /* * S3PT - S3 Performance Table. This table is pointed to by the - * FPDT S3 Pointer Record above. + * S3 Pointer Record above. */ typedef struct acpi_table_s3pt { @@ -267,27 +263,21 @@ typedef struct acpi_table_s3pt /* - * S3PT Subtables + * S3PT Subtables (Not part of the actual FPDT) */ -typedef struct acpi_s3pt_header -{ - UINT16 Type; - UINT8 Length; - UINT8 Revision; -} ACPI_S3PT_HEADER; - -/* Values for Type field above */ +/* Values for Type field in S3PT header */ enum AcpiS3ptType { ACPI_S3PT_TYPE_RESUME = 0, - ACPI_S3PT_TYPE_SUSPEND = 1 + ACPI_S3PT_TYPE_SUSPEND = 1, + ACPI_FPDT_BOOT_PERFORMANCE = 2 }; typedef struct acpi_s3pt_resume { - ACPI_S3PT_HEADER Header; + ACPI_FPDT_HEADER Header; UINT32 ResumeCount; UINT64 FullResume; UINT64 AverageResume; @@ -296,13 +286,29 @@ typedef struct acpi_s3pt_resume typedef struct acpi_s3pt_suspend { - ACPI_S3PT_HEADER Header; + ACPI_FPDT_HEADER Header; UINT64 SuspendStart; UINT64 SuspendEnd; } ACPI_S3PT_SUSPEND; +/* + * FPDT Boot Performance Record (Not part of the actual FPDT) + */ +typedef struct acpi_fpdt_boot +{ + ACPI_FPDT_HEADER Header; + UINT8 Reserved[4]; + UINT64 ResetEnd; + UINT64 LoadStart; + UINT64 StartupStart; + UINT64 ExitServicesEntry; + UINT64 ExitServicesExit; + +} ACPI_FPDT_BOOT; + + /******************************************************************************* * * GTDT - Generic Timer Description Table (ACPI 5.1) diff --git a/source/include/actypes.h b/source/include/actypes.h index e1a733e50419a..395b915383810 100644 --- a/source/include/actypes.h +++ b/source/include/actypes.h @@ -1034,7 +1034,7 @@ typedef struct acpi_buffer */ typedef struct acpi_predefined_names { - char *Name; + const char *Name; UINT8 Type; char *Val; @@ -1325,7 +1325,7 @@ typedef struct acpi_mem_space_context */ typedef struct acpi_memory_list { - char *ListName; + const char *ListName; void *ListHead; UINT16 ObjectSize; UINT16 MaxDepth; diff --git a/source/include/acutils.h b/source/include/acutils.h index cbbf7c5093e46..ed45ef873fbe9 100644 --- a/source/include/acutils.h +++ b/source/include/acutils.h @@ -194,8 +194,14 @@ ACPI_STATUS AcpiUtStrtoul64 ( char *String, UINT32 Base, + UINT32 MaxIntegerByteWidth, UINT64 *RetInteger); +/* Values for MaxIntegerByteWidth above */ + +#define ACPI_MAX32_BYTE_WIDTH 4 +#define ACPI_MAX64_BYTE_WIDTH 8 + /* * utglobal - Global data structures and procedures @@ -341,7 +347,7 @@ AcpiUtTracePtr ( const char *FunctionName, const char *ModuleName, UINT32 ComponentId, - void *Pointer); + const void *Pointer); void AcpiUtTraceU32 ( @@ -357,7 +363,7 @@ AcpiUtTraceStr ( const char *FunctionName, const char *ModuleName, UINT32 ComponentId, - char *String); + const char *String); void AcpiUtExit ( @@ -460,13 +466,13 @@ AcpiUtDeleteInternalObjectList ( ACPI_STATUS AcpiUtEvaluateObject ( ACPI_NAMESPACE_NODE *PrefixNode, - char *Path, + const char *Path, UINT32 ExpectedReturnBtypes, ACPI_OPERAND_OBJECT **ReturnDesc); ACPI_STATUS AcpiUtEvaluateNumericObject ( - char *ObjectName, + const char *ObjectName, ACPI_NAMESPACE_NODE *DeviceNode, UINT64 *Value); @@ -757,7 +763,7 @@ void AcpiUtDisplayInitPathname ( UINT8 Type, ACPI_NAMESPACE_NODE *ObjHandle, - char *Path); + const char *Path); #endif @@ -934,7 +940,7 @@ AcpiUtDumpAllocations ( ACPI_STATUS AcpiUtCreateList ( - char *ListName, + const char *ListName, UINT16 ObjectSize, ACPI_MEMORY_LIST **ReturnCache); diff --git a/source/include/platform/acenv.h b/source/include/platform/acenv.h index 6fab715b50bb2..99adf5f4913d3 100644 --- a/source/include/platform/acenv.h +++ b/source/include/platform/acenv.h @@ -67,17 +67,28 @@ * *****************************************************************************/ +/* Common application configuration. All single threaded except for AcpiExec. */ + +#if (defined ACPI_ASL_COMPILER) || \ + (defined ACPI_BIN_APP) || \ + (defined ACPI_DUMP_APP) || \ + (defined ACPI_HELP_APP) || \ + (defined ACPI_NAMES_APP) || \ + (defined ACPI_SRC_APP) || \ + (defined ACPI_XTRACT_APP) || \ + (defined ACPI_EXAMPLE_APP) +#define ACPI_APPLICATION +#define ACPI_SINGLE_THREADED +#endif + /* iASL configuration */ #ifdef ACPI_ASL_COMPILER -#define ACPI_APPLICATION #define ACPI_DEBUG_OUTPUT #define ACPI_CONSTANT_EVAL_ONLY #define ACPI_LARGE_NAMESPACE_NODE #define ACPI_DATA_TABLE_DISASSEMBLY -#define ACPI_SINGLE_THREADED #define ACPI_32BIT_PHYSICAL_ADDRESS - #define ACPI_DISASSEMBLER 1 #endif @@ -90,21 +101,6 @@ #define ACPI_DBG_TRACK_ALLOCATIONS #endif -/* - * AcpiBin/AcpiDump/AcpiHelp/AcpiNames/AcpiSrc/AcpiXtract/Example - * configuration. All single threaded. - */ -#if (defined ACPI_BIN_APP) || \ - (defined ACPI_DUMP_APP) || \ - (defined ACPI_HELP_APP) || \ - (defined ACPI_NAMES_APP) || \ - (defined ACPI_SRC_APP) || \ - (defined ACPI_XTRACT_APP) || \ - (defined ACPI_EXAMPLE_APP) -#define ACPI_APPLICATION -#define ACPI_SINGLE_THREADED -#endif - /* AcpiHelp configuration. Error messages disabled. */ #ifdef ACPI_HELP_APP @@ -139,11 +135,16 @@ #define ACPI_REDUCED_HARDWARE 1 #endif -/* Linkable ACPICA library */ +/* Linkable ACPICA library. Two versions, one with full debug. */ #ifdef ACPI_LIBRARY #define ACPI_USE_LOCAL_CACHE -#define ACPI_FULL_DEBUG +#define ACPI_DEBUGGER 1 +#define ACPI_DISASSEMBLER 1 + +#ifdef _DEBUG +#define ACPI_DEBUG_OUTPUT +#endif #endif /* Common for all ACPICA applications */ @@ -218,6 +219,9 @@ #elif defined(__HAIKU__) #include "achaiku.h" +#elif defined(__QNX__) +#include "acqnx.h" + #else /* Unknown environment */ diff --git a/source/include/platform/acqnx.h b/source/include/platform/acqnx.h new file mode 100644 index 0000000000000..76252f8668d97 --- /dev/null +++ b/source/include/platform/acqnx.h @@ -0,0 +1,74 @@ +/****************************************************************************** + * + * Name: acqnx.h - OS specific defines, etc. + * + *****************************************************************************/ + +/* + * Copyright (C) 2000 - 2016, Intel Corp. + * All rights reserved. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions + * are met: + * 1. Redistributions of source code must retain the above copyright + * notice, this list of conditions, and the following disclaimer, + * without modification. + * 2. Redistributions in binary form must reproduce at minimum a disclaimer + * substantially similar to the "NO WARRANTY" disclaimer below + * ("Disclaimer") and any redistribution must be conditioned upon + * including a substantially similar Disclaimer requirement for further + * binary redistribution. + * 3. Neither the names of the above-listed copyright holders nor the names + * of any contributors may be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * Alternatively, this software may be distributed under the terms of the + * GNU General Public License ("GPL") version 2 as published by the Free + * Software Foundation. + * + * NO WARRANTY + * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS + * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT + * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTIBILITY AND FITNESS FOR + * A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT + * HOLDERS OR CONTRIBUTORS BE LIABLE FOR SPECIAL, EXEMPLARY, OR CONSEQUENTIAL + * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS + * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) + * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, + * STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING + * IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE + * POSSIBILITY OF SUCH DAMAGES. + */ + +#ifndef __ACQNX_H__ +#define __ACQNX_H__ + +/* QNX uses GCC */ + +#include "acgcc.h" + +#define ACPI_UINTPTR_T uintptr_t +#define ACPI_USE_LOCAL_CACHE +#define ACPI_CAST_PTHREAD_T(x) ((ACPI_THREAD_ID) ACPI_TO_INTEGER (x)) + +/* At present time (QNX 6.6) all supported architectures are 32 bits. */ +#define ACPI_MACHINE_WIDTH 32 + +#define COMPILER_DEPENDENT_INT64 int64_t +#define COMPILER_DEPENDENT_UINT64 uint64_t + +#include <ctype.h> +#include <stdint.h> +#include <sys/neutrino.h> + +#define ACPI_USE_STANDARD_HEADERS + +#define __cli() InterruptDisable(); +#define __sti() InterruptEnable(); +#define __cdecl + +#define ACPI_USE_SYSTEM_CLIBRARY +#define ACPI_USE_NATIVE_DIVIDE + +#endif /* __ACQNX_H__ */ |
