aboutsummaryrefslogtreecommitdiff
path: root/source/include
diff options
context:
space:
mode:
Diffstat (limited to 'source/include')
-rw-r--r--source/include/acapps.h10
-rw-r--r--source/include/acbuffer.h5
-rw-r--r--source/include/acconfig.h4
-rw-r--r--source/include/acdebug.h4
-rw-r--r--source/include/acdisasm.h4
-rw-r--r--source/include/acdispat.h18
-rw-r--r--source/include/acevents.h4
-rw-r--r--source/include/acexcep.h4
-rw-r--r--source/include/acglobal.h364
-rw-r--r--source/include/achware.h4
-rw-r--r--source/include/acinterp.h16
-rw-r--r--source/include/aclocal.h4
-rw-r--r--source/include/acmacros.h4
-rw-r--r--source/include/acnamesp.h4
-rw-r--r--source/include/acobject.h4
-rw-r--r--source/include/acoutput.h4
-rw-r--r--source/include/acparser.h4
-rw-r--r--source/include/acpiosxf.h4
-rw-r--r--source/include/acpixf.h8
-rw-r--r--source/include/acpredef.h18
-rw-r--r--source/include/acresrc.h4
-rw-r--r--source/include/acrestyp.h4
-rw-r--r--source/include/acstruct.h8
-rw-r--r--source/include/actables.h4
-rw-r--r--source/include/actbl.h4
-rw-r--r--source/include/actbl1.h6
-rw-r--r--source/include/actbl2.h6
-rw-r--r--source/include/actbl3.h6
-rw-r--r--source/include/actypes.h4
-rw-r--r--source/include/acutils.h5
-rw-r--r--source/include/amlcode.h5
-rw-r--r--source/include/amlresrc.h5
32 files changed, 332 insertions, 220 deletions
diff --git a/source/include/acapps.h b/source/include/acapps.h
index 6a5577d30ade..ad676cbc13e9 100644
--- a/source/include/acapps.h
+++ b/source/include/acapps.h
@@ -45,6 +45,8 @@
#define _ACAPPS
+#pragma pack(push) /* Set default struct packing */
+
#ifdef _MSC_VER /* disable some level-4 warnings */
#pragma warning(disable:4100) /* warning C4100: unreferenced formal parameter */
#endif
@@ -123,8 +125,7 @@ AdAmlDisassemble (
BOOLEAN OutToFile,
char *Filename,
char *Prefix,
- char **OutFilename,
- BOOLEAN GetAllTables);
+ char **OutFilename);
void
AdPrintStatistics (
@@ -141,8 +142,7 @@ AdDumpTables (
ACPI_STATUS
AdGetLocalTables (
- char *Filename,
- BOOLEAN GetAllTables);
+ void);
ACPI_STATUS
AdParseTable (
@@ -221,4 +221,6 @@ AdWriteTable (
char *OemTableId);
#endif
+#pragma pack(pop) /* Restore original struct packing */
+
#endif /* _ACAPPS */
diff --git a/source/include/acbuffer.h b/source/include/acbuffer.h
index a36a980aa954..8e3cb3d831be 100644
--- a/source/include/acbuffer.h
+++ b/source/include/acbuffer.h
@@ -44,6 +44,9 @@
#ifndef __ACBUFFER_H__
#define __ACBUFFER_H__
+
+#pragma pack(push) /* Set default struct packing */
+
/*
* Contains buffer structures for these predefined names:
* _FDE, _GRT, _GTM, _PLD, _SRT
@@ -243,4 +246,6 @@ typedef struct acpi_pld_info
#define ACPI_PLD_SET_HORIZ_OFFSET(dword,value) ACPI_SET_BITS (dword, 16, ACPI_16BIT_MASK, value) /* Offset 128+16=144, Len 16 */
+#pragma pack(pop) /* Restore original struct packing */
+
#endif /* ACBUFFER_H */
diff --git a/source/include/acconfig.h b/source/include/acconfig.h
index 4cad6f4b7edc..3327d191ed13 100644
--- a/source/include/acconfig.h
+++ b/source/include/acconfig.h
@@ -45,6 +45,8 @@
#define _ACCONFIG_H
+#pragma pack(push) /* Set default struct packing */
+
/******************************************************************************
*
* Configuration options
@@ -234,4 +236,6 @@
#define ACPI_DEBUGGER_EXECUTE_PROMPT '%'
+#pragma pack(pop) /* Restore original struct packing */
+
#endif /* _ACCONFIG_H */
diff --git a/source/include/acdebug.h b/source/include/acdebug.h
index f85ec01ac29a..59f8830e9ffb 100644
--- a/source/include/acdebug.h
+++ b/source/include/acdebug.h
@@ -45,6 +45,8 @@
#define __ACDEBUG_H__
+#pragma pack(push) /* Set default struct packing */
+
#define ACPI_DEBUG_BUFFER_SIZE 0x4000 /* 16K buffer for return objects */
typedef struct acpi_db_command_info
@@ -466,4 +468,6 @@ AcpiDbUint32ToHexString (
UINT32 Value,
char *Buffer);
+#pragma pack(pop) /* Restore original struct packing */
+
#endif /* __ACDEBUG_H__ */
diff --git a/source/include/acdisasm.h b/source/include/acdisasm.h
index a27c6bf6975b..00a469946da8 100644
--- a/source/include/acdisasm.h
+++ b/source/include/acdisasm.h
@@ -47,6 +47,8 @@
#include "amlresrc.h"
+#pragma pack(push) /* Set default struct packing */
+
#define BLOCK_NONE 0
#define BLOCK_PAREN 1
#define BLOCK_BRACE 2
@@ -929,4 +931,6 @@ AdDisassemblerHeader (
char *Filename);
+#pragma pack(pop) /* Restore original struct packing */
+
#endif /* __ACDISASM_H__ */
diff --git a/source/include/acdispat.h b/source/include/acdispat.h
index 607497bbb5bd..d20373d410f2 100644
--- a/source/include/acdispat.h
+++ b/source/include/acdispat.h
@@ -46,6 +46,8 @@
#define _ACDISPAT_H_
+#pragma pack(push) /* Set default struct packing */
+
#define NAMEOF_LOCAL_NTE "__L0"
#define NAMEOF_ARG_NTE "__A0"
@@ -173,13 +175,15 @@ AcpiDsInitFieldObjects (
/*
- * dsload - Parser/Interpreter interface, pass 1 namespace load callbacks
+ * dsload - Parser/Interpreter interface
*/
ACPI_STATUS
AcpiDsInitCallbacks (
ACPI_WALK_STATE *WalkState,
UINT32 PassNumber);
+/* dsload - pass 1 namespace load callbacks */
+
ACPI_STATUS
AcpiDsLoad1BeginOp (
ACPI_WALK_STATE *WalkState,
@@ -190,9 +194,8 @@ AcpiDsLoad1EndOp (
ACPI_WALK_STATE *WalkState);
-/*
- * dsload - Parser/Interpreter interface, pass 2 namespace load callbacks
- */
+/* dsload - pass 2 namespace load callbacks */
+
ACPI_STATUS
AcpiDsLoad2BeginOp (
ACPI_WALK_STATE *WalkState,
@@ -257,8 +260,9 @@ AcpiDsMethodDataInit (
* dsmethod - Parser/Interpreter interface - control method parsing
*/
ACPI_STATUS
-AcpiDsParseMethod (
- ACPI_NAMESPACE_NODE *Node);
+AcpiDsAutoSerializeMethod (
+ ACPI_NAMESPACE_NODE *Node,
+ ACPI_OPERAND_OBJECT *ObjDesc);
ACPI_STATUS
AcpiDsCallControlMethod (
@@ -460,4 +464,6 @@ AcpiDsResultPush (
ACPI_OPERAND_OBJECT *Object,
ACPI_WALK_STATE *WalkState);
+#pragma pack(pop) /* Restore original struct packing */
+
#endif /* _ACDISPAT_H_ */
diff --git a/source/include/acevents.h b/source/include/acevents.h
index 3db603534a6b..da998fb8ee95 100644
--- a/source/include/acevents.h
+++ b/source/include/acevents.h
@@ -45,6 +45,8 @@
#define __ACEVENTS_H__
+#pragma pack(push) /* Set default struct packing */
+
/*
* evevent
*/
@@ -356,4 +358,6 @@ void
AcpiEvTerminate (
void))
+#pragma pack(pop) /* Restore original struct packing */
+
#endif /* __ACEVENTS_H__ */
diff --git a/source/include/acexcep.h b/source/include/acexcep.h
index aab6941a3c7e..40ea039c4836 100644
--- a/source/include/acexcep.h
+++ b/source/include/acexcep.h
@@ -45,6 +45,8 @@
#define __ACEXCEP_H__
+#pragma pack(push) /* Set default struct packing */
+
/* This module contains all possible exception codes for ACPI_STATUS */
/*
@@ -345,4 +347,6 @@ static const ACPI_EXCEPTION_INFO AcpiGbl_ExceptionNames_Ctrl[] =
#endif /* EXCEPTION_TABLE */
+#pragma pack(pop) /* Restore original struct packing */
+
#endif /* __ACEXCEP_H__ */
diff --git a/source/include/acglobal.h b/source/include/acglobal.h
index 52e97477043d..701955e9f7a2 100644
--- a/source/include/acglobal.h
+++ b/source/include/acglobal.h
@@ -45,6 +45,8 @@
#define __ACGLOBAL_H__
+#pragma pack(push) /* Set default struct packing */
+
/*
* Ensure that the globals are actually defined and initialized only once.
*
@@ -52,11 +54,19 @@
* to simplify maintenance of the code.
*/
#ifdef DEFINE_ACPI_GLOBALS
-#define ACPI_EXTERN
-#define ACPI_INIT_GLOBAL(a,b) a=b
+#define ACPI_GLOBAL(type,name) \
+ extern type name; \
+ type name
+
+#define ACPI_INIT_GLOBAL(type,name,value) \
+ type name=value
+
#else
-#define ACPI_EXTERN extern
-#define ACPI_INIT_GLOBAL(a,b) a
+#define ACPI_GLOBAL(type,name) \
+ extern type name
+
+#define ACPI_INIT_GLOBAL(type,name,value) \
+ extern type name
#endif
@@ -84,33 +94,34 @@
* 5) Allow unresolved references (invalid target name) in package objects
* 6) Enable warning messages for behavior that is not ACPI spec compliant
*/
-UINT8 ACPI_INIT_GLOBAL (AcpiGbl_EnableInterpreterSlack, FALSE);
+ACPI_INIT_GLOBAL (UINT8, AcpiGbl_EnableInterpreterSlack, FALSE);
/*
- * Automatically serialize ALL control methods? Default is FALSE, meaning
- * to use the Serialized/NotSerialized method flags on a per method basis.
- * Only change this if the ASL code is poorly written and cannot handle
- * reentrancy even though methods are marked "NotSerialized".
+ * Automatically serialize all methods that create named objects? Default
+ * is TRUE, meaning that all NonSerialized methods are scanned once at
+ * table load time to determine those that create named objects. Methods
+ * that create named objects are marked Serialized in order to prevent
+ * possible run-time problems if they are entered by more than one thread.
*/
-UINT8 ACPI_INIT_GLOBAL (AcpiGbl_AllMethodsSerialized, FALSE);
+ACPI_INIT_GLOBAL (UINT8, AcpiGbl_AutoSerializeMethods, TRUE);
/*
* Create the predefined _OSI method in the namespace? Default is TRUE
* because ACPI CA is fully compatible with other ACPI implementations.
* Changing this will revert ACPI CA (and machine ASL) to pre-OSI behavior.
*/
-UINT8 ACPI_INIT_GLOBAL (AcpiGbl_CreateOsiMethod, TRUE);
+ACPI_INIT_GLOBAL (UINT8, AcpiGbl_CreateOsiMethod, TRUE);
/*
* Optionally use default values for the ACPI register widths. Set this to
* TRUE to use the defaults, if an FADT contains incorrect widths/lengths.
*/
-UINT8 ACPI_INIT_GLOBAL (AcpiGbl_UseDefaultRegisterWidths, TRUE);
+ACPI_INIT_GLOBAL (UINT8, AcpiGbl_UseDefaultRegisterWidths, TRUE);
/*
* Optionally enable output from the AML Debug Object.
*/
-UINT8 ACPI_INIT_GLOBAL (AcpiGbl_EnableAmlDebugObject, FALSE);
+ACPI_INIT_GLOBAL (UINT8, AcpiGbl_EnableAmlDebugObject, FALSE);
/*
* Optionally copy the entire DSDT to local memory (instead of simply
@@ -118,7 +129,7 @@ UINT8 ACPI_INIT_GLOBAL (AcpiGbl_EnableAmlDebugObject, FALSE);
* DSDT, creating the need for this option. Default is FALSE, do not copy
* the DSDT.
*/
-UINT8 ACPI_INIT_GLOBAL (AcpiGbl_CopyDsdtLocally, FALSE);
+ACPI_INIT_GLOBAL (UINT8, AcpiGbl_CopyDsdtLocally, FALSE);
/*
* Optionally ignore an XSDT if present and use the RSDT instead.
@@ -126,8 +137,7 @@ UINT8 ACPI_INIT_GLOBAL (AcpiGbl_CopyDsdtLocally, FALSE);
* of the RSDT, the XSDT has been found to be corrupt or ill-formed on
* some machines. Default behavior is to use the XSDT if present.
*/
-UINT8 ACPI_INIT_GLOBAL (AcpiGbl_DoNotUseXsdt, FALSE);
-
+ACPI_INIT_GLOBAL (UINT8, AcpiGbl_DoNotUseXsdt, FALSE);
/*
* Optionally use 32-bit FADT addresses if and when there is a conflict
@@ -137,7 +147,7 @@ UINT8 ACPI_INIT_GLOBAL (AcpiGbl_DoNotUseXsdt, FALSE);
* some machines have been found to have a corrupted non-zero 64-bit
* address. Default is FALSE, do not favor the 32-bit addresses.
*/
-UINT8 ACPI_INIT_GLOBAL (AcpiGbl_Use32BitFadtAddresses, FALSE);
+ACPI_INIT_GLOBAL (UINT8, AcpiGbl_Use32BitFadtAddresses, FALSE);
/*
* Optionally truncate I/O addresses to 16 bits. Provides compatibility
@@ -145,47 +155,28 @@ UINT8 ACPI_INIT_GLOBAL (AcpiGbl_Use32BitFadtAddresses, FALSE);
* this value is set to TRUE if any Windows OSI strings have been
* requested by the BIOS.
*/
-UINT8 ACPI_INIT_GLOBAL (AcpiGbl_TruncateIoAddresses, FALSE);
+ACPI_INIT_GLOBAL (UINT8, AcpiGbl_TruncateIoAddresses, FALSE);
/*
* Disable runtime checking and repair of values returned by control methods.
* Use only if the repair is causing a problem on a particular machine.
*/
-UINT8 ACPI_INIT_GLOBAL (AcpiGbl_DisableAutoRepair, FALSE);
+ACPI_INIT_GLOBAL (UINT8, AcpiGbl_DisableAutoRepair, FALSE);
/*
* Optionally do not load any SSDTs from the RSDT/XSDT during initialization.
* This can be useful for debugging ACPI problems on some machines.
*/
-UINT8 ACPI_INIT_GLOBAL (AcpiGbl_DisableSsdtTableLoad, FALSE);
+ACPI_INIT_GLOBAL (UINT8, AcpiGbl_DisableSsdtTableLoad, FALSE);
/*
* We keep track of the latest version of Windows that has been requested by
* the BIOS.
*/
-UINT8 ACPI_INIT_GLOBAL (AcpiGbl_OsiData, 0);
-
-
-/* AcpiGbl_FADT is a local copy of the FADT, converted to a common format. */
-
-ACPI_TABLE_FADT AcpiGbl_FADT;
-UINT32 AcpiCurrentGpeCount;
-UINT32 AcpiGbl_TraceFlags;
-ACPI_NAME AcpiGbl_TraceMethodName;
-BOOLEAN AcpiGbl_SystemAwakeAndRunning;
-
-/*
- * ACPI 5.0 introduces the concept of a "reduced hardware platform", meaning
- * that the ACPI hardware is no longer required. A flag in the FADT indicates
- * a reduced HW machine, and that flag is duplicated here for convenience.
- */
-BOOLEAN AcpiGbl_ReducedHardware;
+ACPI_INIT_GLOBAL (UINT8, AcpiGbl_OsiData, 0);
#endif /* DEFINE_ACPI_GLOBALS */
-/* Do not disassemble buffers to resource descriptors */
-
-ACPI_EXTERN UINT8 ACPI_INIT_GLOBAL (AcpiGbl_NoResourceDisassembly, FALSE);
/*****************************************************************************
*
@@ -194,37 +185,36 @@ ACPI_EXTERN UINT8 ACPI_INIT_GLOBAL (AcpiGbl_NoResourceDisassembly, FALSE);
****************************************************************************/
/*
- * AcpiGbl_RootTableList is the master list of ACPI tables that were
- * found in the RSDT/XSDT.
+ * Master list of all ACPI tables that were found in the RSDT/XSDT.
*/
-ACPI_EXTERN ACPI_TABLE_LIST AcpiGbl_RootTableList;
+ACPI_GLOBAL (ACPI_TABLE_LIST, AcpiGbl_RootTableList);
+
+/* DSDT information. Used to check for DSDT corruption */
+
+ACPI_GLOBAL (ACPI_TABLE_HEADER *, AcpiGbl_DSDT);
+ACPI_GLOBAL (ACPI_TABLE_HEADER, AcpiGbl_OriginalDsdtHeader);
#if (!ACPI_REDUCED_HARDWARE)
-ACPI_EXTERN ACPI_TABLE_FACS *AcpiGbl_FACS;
+ACPI_GLOBAL (ACPI_TABLE_FACS *, AcpiGbl_FACS);
#endif /* !ACPI_REDUCED_HARDWARE */
/* These addresses are calculated from the FADT Event Block addresses */
-ACPI_EXTERN ACPI_GENERIC_ADDRESS AcpiGbl_XPm1aStatus;
-ACPI_EXTERN ACPI_GENERIC_ADDRESS AcpiGbl_XPm1aEnable;
+ACPI_GLOBAL (ACPI_GENERIC_ADDRESS, AcpiGbl_XPm1aStatus);
+ACPI_GLOBAL (ACPI_GENERIC_ADDRESS, AcpiGbl_XPm1aEnable);
-ACPI_EXTERN ACPI_GENERIC_ADDRESS AcpiGbl_XPm1bStatus;
-ACPI_EXTERN ACPI_GENERIC_ADDRESS AcpiGbl_XPm1bEnable;
-
-/* DSDT information. Used to check for DSDT corruption */
-
-ACPI_EXTERN ACPI_TABLE_HEADER *AcpiGbl_DSDT;
-ACPI_EXTERN ACPI_TABLE_HEADER AcpiGbl_OriginalDsdtHeader;
+ACPI_GLOBAL (ACPI_GENERIC_ADDRESS, AcpiGbl_XPm1bStatus);
+ACPI_GLOBAL (ACPI_GENERIC_ADDRESS, AcpiGbl_XPm1bEnable);
/*
- * Handle both ACPI 1.0 and ACPI 2.0 Integer widths. The integer width is
+ * Handle both ACPI 1.0 and ACPI 2.0+ Integer widths. The integer width is
* determined by the revision of the DSDT: If the DSDT revision is less than
* 2, use only the lower 32 bits of the internal 64-bit Integer.
*/
-ACPI_EXTERN UINT8 AcpiGbl_IntegerBitWidth;
-ACPI_EXTERN UINT8 AcpiGbl_IntegerByteWidth;
-ACPI_EXTERN UINT8 AcpiGbl_IntegerNybbleWidth;
+ACPI_GLOBAL (UINT8, AcpiGbl_IntegerBitWidth);
+ACPI_GLOBAL (UINT8, AcpiGbl_IntegerByteWidth);
+ACPI_GLOBAL (UINT8, AcpiGbl_IntegerNybbleWidth);
/*****************************************************************************
@@ -238,36 +228,36 @@ ACPI_EXTERN UINT8 AcpiGbl_IntegerNybbleWidth;
* actual OS mutex handles, indexed by the local ACPI_MUTEX_HANDLEs.
* (The table maps local handles to the real OS handles)
*/
-ACPI_EXTERN ACPI_MUTEX_INFO AcpiGbl_MutexInfo[ACPI_NUM_MUTEX];
+ACPI_GLOBAL (ACPI_MUTEX_INFO, AcpiGbl_MutexInfo[ACPI_NUM_MUTEX]);
/*
* Global lock mutex is an actual AML mutex object
* Global lock semaphore works in conjunction with the actual global lock
* Global lock spinlock is used for "pending" handshake
*/
-ACPI_EXTERN ACPI_OPERAND_OBJECT *AcpiGbl_GlobalLockMutex;
-ACPI_EXTERN ACPI_SEMAPHORE AcpiGbl_GlobalLockSemaphore;
-ACPI_EXTERN ACPI_SPINLOCK AcpiGbl_GlobalLockPendingLock;
-ACPI_EXTERN UINT16 AcpiGbl_GlobalLockHandle;
-ACPI_EXTERN BOOLEAN AcpiGbl_GlobalLockAcquired;
-ACPI_EXTERN BOOLEAN AcpiGbl_GlobalLockPresent;
-ACPI_EXTERN BOOLEAN AcpiGbl_GlobalLockPending;
+ACPI_GLOBAL (ACPI_OPERAND_OBJECT *, AcpiGbl_GlobalLockMutex);
+ACPI_GLOBAL (ACPI_SEMAPHORE, AcpiGbl_GlobalLockSemaphore);
+ACPI_GLOBAL (ACPI_SPINLOCK, AcpiGbl_GlobalLockPendingLock);
+ACPI_GLOBAL (UINT16, AcpiGbl_GlobalLockHandle);
+ACPI_GLOBAL (BOOLEAN, AcpiGbl_GlobalLockAcquired);
+ACPI_GLOBAL (BOOLEAN, AcpiGbl_GlobalLockPresent);
+ACPI_GLOBAL (BOOLEAN, AcpiGbl_GlobalLockPending);
/*
* Spinlocks are used for interfaces that can be possibly called at
* interrupt level
*/
-ACPI_EXTERN ACPI_SPINLOCK AcpiGbl_GpeLock; /* For GPE data structs and registers */
-ACPI_EXTERN ACPI_SPINLOCK AcpiGbl_HardwareLock; /* For ACPI H/W except GPE registers */
-ACPI_EXTERN ACPI_SPINLOCK AcpiGbl_ReferenceCountLock;
+ACPI_GLOBAL (ACPI_SPINLOCK, AcpiGbl_GpeLock); /* For GPE data structs and registers */
+ACPI_GLOBAL (ACPI_SPINLOCK, AcpiGbl_HardwareLock); /* For ACPI H/W except GPE registers */
+ACPI_GLOBAL (ACPI_SPINLOCK, AcpiGbl_ReferenceCountLock);
/* Mutex for _OSI support */
-ACPI_EXTERN ACPI_MUTEX AcpiGbl_OsiMutex;
+ACPI_GLOBAL (ACPI_MUTEX, AcpiGbl_OsiMutex);
/* Reader/Writer lock is used for namespace walk and dynamic table unload */
-ACPI_EXTERN ACPI_RW_LOCK AcpiGbl_NamespaceRwLock;
+ACPI_GLOBAL (ACPI_RW_LOCK, AcpiGbl_NamespaceRwLock);
/*****************************************************************************
@@ -278,69 +268,69 @@ ACPI_EXTERN ACPI_RW_LOCK AcpiGbl_NamespaceRwLock;
/* Object caches */
-ACPI_EXTERN ACPI_CACHE_T *AcpiGbl_NamespaceCache;
-ACPI_EXTERN ACPI_CACHE_T *AcpiGbl_StateCache;
-ACPI_EXTERN ACPI_CACHE_T *AcpiGbl_PsNodeCache;
-ACPI_EXTERN ACPI_CACHE_T *AcpiGbl_PsNodeExtCache;
-ACPI_EXTERN ACPI_CACHE_T *AcpiGbl_OperandCache;
+ACPI_GLOBAL (ACPI_CACHE_T *, AcpiGbl_NamespaceCache);
+ACPI_GLOBAL (ACPI_CACHE_T *, AcpiGbl_StateCache);
+ACPI_GLOBAL (ACPI_CACHE_T *, AcpiGbl_PsNodeCache);
+ACPI_GLOBAL (ACPI_CACHE_T *, AcpiGbl_PsNodeExtCache);
+ACPI_GLOBAL (ACPI_CACHE_T *, AcpiGbl_OperandCache);
+
+/* System */
+
+ACPI_INIT_GLOBAL (UINT32, AcpiGbl_StartupFlags, 0);
+ACPI_INIT_GLOBAL (BOOLEAN, AcpiGbl_Shutdown, TRUE);
/* Global handlers */
-ACPI_EXTERN ACPI_GLOBAL_NOTIFY_HANDLER AcpiGbl_GlobalNotify[2];
-ACPI_EXTERN ACPI_EXCEPTION_HANDLER AcpiGbl_ExceptionHandler;
-ACPI_EXTERN ACPI_INIT_HANDLER AcpiGbl_InitHandler;
-ACPI_EXTERN ACPI_TABLE_HANDLER AcpiGbl_TableHandler;
-ACPI_EXTERN void *AcpiGbl_TableHandlerContext;
-ACPI_EXTERN ACPI_WALK_STATE *AcpiGbl_BreakpointWalk;
-ACPI_EXTERN ACPI_INTERFACE_HANDLER AcpiGbl_InterfaceHandler;
-ACPI_EXTERN ACPI_SCI_HANDLER_INFO *AcpiGbl_SciHandlerList;
+ACPI_GLOBAL (ACPI_GLOBAL_NOTIFY_HANDLER,AcpiGbl_GlobalNotify[2]);
+ACPI_GLOBAL (ACPI_EXCEPTION_HANDLER, AcpiGbl_ExceptionHandler);
+ACPI_GLOBAL (ACPI_INIT_HANDLER, AcpiGbl_InitHandler);
+ACPI_GLOBAL (ACPI_TABLE_HANDLER, AcpiGbl_TableHandler);
+ACPI_GLOBAL (void *, AcpiGbl_TableHandlerContext);
+ACPI_GLOBAL (ACPI_WALK_STATE *, AcpiGbl_BreakpointWalk);
+ACPI_GLOBAL (ACPI_INTERFACE_HANDLER, AcpiGbl_InterfaceHandler);
+ACPI_GLOBAL (ACPI_SCI_HANDLER_INFO *, AcpiGbl_SciHandlerList);
/* Owner ID support */
-ACPI_EXTERN UINT32 AcpiGbl_OwnerIdMask[ACPI_NUM_OWNERID_MASKS];
-ACPI_EXTERN UINT8 AcpiGbl_LastOwnerIdIndex;
-ACPI_EXTERN UINT8 AcpiGbl_NextOwnerIdOffset;
+ACPI_GLOBAL (UINT32, AcpiGbl_OwnerIdMask[ACPI_NUM_OWNERID_MASKS]);
+ACPI_GLOBAL (UINT8, AcpiGbl_LastOwnerIdIndex);
+ACPI_GLOBAL (UINT8, AcpiGbl_NextOwnerIdOffset);
/* Initialization sequencing */
-ACPI_EXTERN BOOLEAN AcpiGbl_RegMethodsExecuted;
+ACPI_GLOBAL (BOOLEAN, AcpiGbl_RegMethodsExecuted);
/* Misc */
-ACPI_EXTERN UINT32 AcpiGbl_OriginalMode;
-ACPI_EXTERN UINT32 AcpiGbl_RsdpOriginalLocation;
-ACPI_EXTERN UINT32 AcpiGbl_NsLookupCount;
-ACPI_EXTERN UINT32 AcpiGbl_PsFindCount;
-ACPI_EXTERN UINT16 AcpiGbl_Pm1EnableRegisterSave;
-ACPI_EXTERN UINT8 AcpiGbl_DebuggerConfiguration;
-ACPI_EXTERN BOOLEAN AcpiGbl_StepToNextCall;
-ACPI_EXTERN BOOLEAN AcpiGbl_AcpiHardwarePresent;
-ACPI_EXTERN BOOLEAN AcpiGbl_EventsInitialized;
-ACPI_EXTERN ACPI_INTERFACE_INFO *AcpiGbl_SupportedInterfaces;
-ACPI_EXTERN ACPI_ADDRESS_RANGE *AcpiGbl_AddressRangeList[ACPI_ADDRESS_RANGE_MAX];
+ACPI_GLOBAL (UINT32, AcpiGbl_OriginalMode);
+ACPI_GLOBAL (UINT32, AcpiGbl_RsdpOriginalLocation);
+ACPI_GLOBAL (UINT32, AcpiGbl_NsLookupCount);
+ACPI_GLOBAL (UINT32, AcpiGbl_PsFindCount);
+ACPI_GLOBAL (UINT16, AcpiGbl_Pm1EnableRegisterSave);
+ACPI_GLOBAL (UINT8, AcpiGbl_DebuggerConfiguration);
+ACPI_GLOBAL (BOOLEAN, AcpiGbl_StepToNextCall);
+ACPI_GLOBAL (BOOLEAN, AcpiGbl_AcpiHardwarePresent);
+ACPI_GLOBAL (BOOLEAN, AcpiGbl_EventsInitialized);
+ACPI_GLOBAL (ACPI_INTERFACE_INFO *, AcpiGbl_SupportedInterfaces);
+ACPI_GLOBAL (ACPI_ADDRESS_RANGE *, AcpiGbl_AddressRangeList[ACPI_ADDRESS_RANGE_MAX]);
-#ifndef DEFINE_ACPI_GLOBALS
+/* Other miscellaneous, declared and initialized in utglobal */
-/* Other miscellaneous */
-
-extern BOOLEAN AcpiGbl_Shutdown;
-extern UINT32 AcpiGbl_StartupFlags;
extern const char *AcpiGbl_SleepStateNames[ACPI_S_STATE_COUNT];
extern const char *AcpiGbl_LowestDstateNames[ACPI_NUM_SxW_METHODS];
extern const char *AcpiGbl_HighestDstateNames[ACPI_NUM_SxD_METHODS];
-extern const ACPI_OPCODE_INFO AcpiGbl_AmlOpInfo[AML_NUM_OPCODES];
extern const char *AcpiGbl_RegionTypes[ACPI_NUM_PREDEFINED_REGIONS];
-#endif
+extern const ACPI_OPCODE_INFO AcpiGbl_AmlOpInfo[AML_NUM_OPCODES];
#ifdef ACPI_DBG_TRACK_ALLOCATIONS
-/* Lists for tracking memory allocations */
+/* Lists for tracking memory allocations (debug only) */
-ACPI_EXTERN ACPI_MEMORY_LIST *AcpiGbl_GlobalList;
-ACPI_EXTERN ACPI_MEMORY_LIST *AcpiGbl_NsNodeList;
-ACPI_EXTERN BOOLEAN AcpiGbl_DisplayFinalMemStats;
-ACPI_EXTERN BOOLEAN AcpiGbl_DisableMemTracking;
+ACPI_GLOBAL (ACPI_MEMORY_LIST *, AcpiGbl_GlobalList);
+ACPI_GLOBAL (ACPI_MEMORY_LIST *, AcpiGbl_NsNodeList);
+ACPI_GLOBAL (BOOLEAN, AcpiGbl_DisplayFinalMemStats);
+ACPI_GLOBAL (BOOLEAN, AcpiGbl_DisableMemTracking);
#endif
@@ -356,22 +346,23 @@ ACPI_EXTERN BOOLEAN AcpiGbl_DisableMemTracking;
#define NUM_PREDEFINED_NAMES 9
#endif
-ACPI_EXTERN ACPI_NAMESPACE_NODE AcpiGbl_RootNodeStruct;
-ACPI_EXTERN ACPI_NAMESPACE_NODE *AcpiGbl_RootNode;
-ACPI_EXTERN ACPI_NAMESPACE_NODE *AcpiGbl_FadtGpeDevice;
-ACPI_EXTERN ACPI_OPERAND_OBJECT *AcpiGbl_ModuleCodeList;
+ACPI_GLOBAL (ACPI_NAMESPACE_NODE, AcpiGbl_RootNodeStruct);
+ACPI_GLOBAL (ACPI_NAMESPACE_NODE *, AcpiGbl_RootNode);
+ACPI_GLOBAL (ACPI_NAMESPACE_NODE *, AcpiGbl_FadtGpeDevice);
+ACPI_GLOBAL (ACPI_OPERAND_OBJECT *, AcpiGbl_ModuleCodeList);
extern const UINT8 AcpiGbl_NsProperties [ACPI_NUM_NS_TYPES];
extern const ACPI_PREDEFINED_NAMES AcpiGbl_PreDefinedNames [NUM_PREDEFINED_NAMES];
#ifdef ACPI_DEBUG_OUTPUT
-ACPI_EXTERN UINT32 AcpiGbl_CurrentNodeCount;
-ACPI_EXTERN UINT32 AcpiGbl_CurrentNodeSize;
-ACPI_EXTERN UINT32 AcpiGbl_MaxConcurrentNodeCount;
-ACPI_EXTERN ACPI_SIZE *AcpiGbl_EntryStackPointer;
-ACPI_EXTERN ACPI_SIZE *AcpiGbl_LowestStackPointer;
-ACPI_EXTERN UINT32 AcpiGbl_DeepestNesting;
+ACPI_GLOBAL (UINT32, AcpiGbl_CurrentNodeCount);
+ACPI_GLOBAL (UINT32, AcpiGbl_CurrentNodeSize);
+ACPI_GLOBAL (UINT32, AcpiGbl_MaxConcurrentNodeCount);
+ACPI_GLOBAL (ACPI_SIZE *, AcpiGbl_EntryStackPointer);
+ACPI_GLOBAL (ACPI_SIZE *, AcpiGbl_LowestStackPointer);
+ACPI_GLOBAL (UINT32, AcpiGbl_DeepestNesting);
+ACPI_INIT_GLOBAL (UINT32, AcpiGbl_NestingLevel, 0);
#endif
@@ -381,11 +372,11 @@ ACPI_EXTERN UINT32 AcpiGbl_DeepestNesting;
*
****************************************************************************/
-ACPI_EXTERN ACPI_THREAD_STATE *AcpiGbl_CurrentWalkList;
+ACPI_GLOBAL (ACPI_THREAD_STATE *, AcpiGbl_CurrentWalkList);
/* Control method single step flag */
-ACPI_EXTERN UINT8 AcpiGbl_CmSingleStep;
+ACPI_GLOBAL (UINT8, AcpiGbl_CmSingleStep);
/*****************************************************************************
@@ -394,9 +385,10 @@ ACPI_EXTERN UINT8 AcpiGbl_CmSingleStep;
*
****************************************************************************/
-extern ACPI_BIT_REGISTER_INFO AcpiGbl_BitRegisterInfo[ACPI_NUM_BITREG];
-ACPI_EXTERN UINT8 AcpiGbl_SleepTypeA;
-ACPI_EXTERN UINT8 AcpiGbl_SleepTypeB;
+extern ACPI_BIT_REGISTER_INFO AcpiGbl_BitRegisterInfo[ACPI_NUM_BITREG];
+
+ACPI_GLOBAL (UINT8, AcpiGbl_SleepTypeA);
+ACPI_GLOBAL (UINT8, AcpiGbl_SleepTypeB);
/*****************************************************************************
@@ -407,13 +399,14 @@ ACPI_EXTERN UINT8 AcpiGbl_SleepTypeB;
#if (!ACPI_REDUCED_HARDWARE)
-ACPI_EXTERN UINT8 AcpiGbl_AllGpesInitialized;
-ACPI_EXTERN ACPI_GPE_XRUPT_INFO *AcpiGbl_GpeXruptListHead;
-ACPI_EXTERN ACPI_GPE_BLOCK_INFO *AcpiGbl_GpeFadtBlocks[ACPI_MAX_GPE_BLOCKS];
-ACPI_EXTERN ACPI_GBL_EVENT_HANDLER AcpiGbl_GlobalEventHandler;
-ACPI_EXTERN void *AcpiGbl_GlobalEventHandlerContext;
-ACPI_EXTERN ACPI_FIXED_EVENT_HANDLER AcpiGbl_FixedEventHandlers[ACPI_NUM_FIXED_EVENTS];
-extern ACPI_FIXED_EVENT_INFO AcpiGbl_FixedEventInfo[ACPI_NUM_FIXED_EVENTS];
+ACPI_GLOBAL (UINT8, AcpiGbl_AllGpesInitialized);
+ACPI_GLOBAL (ACPI_GPE_XRUPT_INFO *, AcpiGbl_GpeXruptListHead);
+ACPI_GLOBAL (ACPI_GPE_BLOCK_INFO *, AcpiGbl_GpeFadtBlocks[ACPI_MAX_GPE_BLOCKS]);
+ACPI_GLOBAL (ACPI_GBL_EVENT_HANDLER, AcpiGbl_GlobalEventHandler);
+ACPI_GLOBAL (void *, AcpiGbl_GlobalEventHandlerContext);
+ACPI_GLOBAL (ACPI_FIXED_EVENT_HANDLER, AcpiGbl_FixedEventHandlers[ACPI_NUM_FIXED_EVENTS]);
+
+extern ACPI_FIXED_EVENT_INFO AcpiGbl_FixedEventInfo[ACPI_NUM_FIXED_EVENTS];
#endif /* !ACPI_REDUCED_HARDWARE */
@@ -423,23 +416,19 @@ extern ACPI_FIXED_EVENT_INFO AcpiGbl_FixedEventInfo[ACPI_NUM_FIXED_EV
*
****************************************************************************/
-/* Procedure nesting level for debug output */
-
-extern UINT32 AcpiGbl_NestingLevel;
-
/* Event counters */
-ACPI_EXTERN UINT32 AcpiMethodCount;
-ACPI_EXTERN UINT32 AcpiGpeCount;
-ACPI_EXTERN UINT32 AcpiSciCount;
-ACPI_EXTERN UINT32 AcpiFixedEventCount[ACPI_NUM_FIXED_EVENTS];
+ACPI_GLOBAL (UINT32, AcpiMethodCount);
+ACPI_GLOBAL (UINT32, AcpiGpeCount);
+ACPI_GLOBAL (UINT32, AcpiSciCount);
+ACPI_GLOBAL (UINT32, AcpiFixedEventCount[ACPI_NUM_FIXED_EVENTS]);
/* Support for dynamic control method tracing mechanism */
-ACPI_EXTERN UINT32 AcpiGbl_OriginalDbgLevel;
-ACPI_EXTERN UINT32 AcpiGbl_OriginalDbgLayer;
-ACPI_EXTERN UINT32 AcpiGbl_TraceDbgLevel;
-ACPI_EXTERN UINT32 AcpiGbl_TraceDbgLayer;
+ACPI_GLOBAL (UINT32, AcpiGbl_OriginalDbgLevel);
+ACPI_GLOBAL (UINT32, AcpiGbl_OriginalDbgLayer);
+ACPI_GLOBAL (UINT32, AcpiGbl_TraceDbgLevel);
+ACPI_GLOBAL (UINT32, AcpiGbl_TraceDbgLayer);
/*****************************************************************************
@@ -448,63 +437,64 @@ ACPI_EXTERN UINT32 AcpiGbl_TraceDbgLayer;
*
****************************************************************************/
-ACPI_EXTERN UINT8 AcpiGbl_DbOutputFlags;
+ACPI_GLOBAL (UINT8, AcpiGbl_DbOutputFlags);
#ifdef ACPI_DISASSEMBLER
-ACPI_EXTERN BOOLEAN ACPI_INIT_GLOBAL (AcpiGbl_IgnoreNoopOperator, FALSE);
+/* Do not disassemble buffers to resource descriptors */
-ACPI_EXTERN BOOLEAN AcpiGbl_DbOpt_disasm;
-ACPI_EXTERN BOOLEAN AcpiGbl_DbOpt_verbose;
-ACPI_EXTERN BOOLEAN AcpiGbl_NumExternalMethods;
-ACPI_EXTERN UINT32 AcpiGbl_ResolvedExternalMethods;
-ACPI_EXTERN ACPI_EXTERNAL_LIST *AcpiGbl_ExternalList;
-ACPI_EXTERN ACPI_EXTERNAL_FILE *AcpiGbl_ExternalFileList;
-#endif
+ACPI_INIT_GLOBAL (UINT8, AcpiGbl_NoResourceDisassembly, FALSE);
+ACPI_INIT_GLOBAL (BOOLEAN, AcpiGbl_IgnoreNoopOperator, FALSE);
+ACPI_GLOBAL (BOOLEAN, AcpiGbl_DbOpt_disasm);
+ACPI_GLOBAL (BOOLEAN, AcpiGbl_DbOpt_verbose);
+ACPI_GLOBAL (BOOLEAN, AcpiGbl_NumExternalMethods);
+ACPI_GLOBAL (UINT32, AcpiGbl_ResolvedExternalMethods);
+ACPI_GLOBAL (ACPI_EXTERNAL_LIST *, AcpiGbl_ExternalList);
+ACPI_GLOBAL (ACPI_EXTERNAL_FILE *, AcpiGbl_ExternalFileList);
+#endif
#ifdef ACPI_DEBUGGER
-extern BOOLEAN AcpiGbl_MethodExecuting;
-extern BOOLEAN AcpiGbl_AbortMethod;
-extern BOOLEAN AcpiGbl_DbTerminateThreads;
+ACPI_INIT_GLOBAL (BOOLEAN, AcpiGbl_DbTerminateThreads, FALSE);
+ACPI_INIT_GLOBAL (BOOLEAN, AcpiGbl_AbortMethod, FALSE);
+ACPI_INIT_GLOBAL (BOOLEAN, AcpiGbl_MethodExecuting, FALSE);
-ACPI_EXTERN BOOLEAN AcpiGbl_DbOpt_tables;
-ACPI_EXTERN BOOLEAN AcpiGbl_DbOpt_stats;
-ACPI_EXTERN BOOLEAN AcpiGbl_DbOpt_ini_methods;
-ACPI_EXTERN BOOLEAN AcpiGbl_DbOpt_NoRegionSupport;
-ACPI_EXTERN BOOLEAN AcpiGbl_DbOutputToFile;
-ACPI_EXTERN char *AcpiGbl_DbBuffer;
-ACPI_EXTERN char *AcpiGbl_DbFilename;
-ACPI_EXTERN UINT32 AcpiGbl_DbDebugLevel;
-ACPI_EXTERN UINT32 AcpiGbl_DbConsoleDebugLevel;
-ACPI_EXTERN ACPI_NAMESPACE_NODE *AcpiGbl_DbScopeNode;
+ACPI_GLOBAL (BOOLEAN, AcpiGbl_DbOpt_tables);
+ACPI_GLOBAL (BOOLEAN, AcpiGbl_DbOpt_stats);
+ACPI_GLOBAL (BOOLEAN, AcpiGbl_DbOpt_ini_methods);
+ACPI_GLOBAL (BOOLEAN, AcpiGbl_DbOpt_NoRegionSupport);
+ACPI_GLOBAL (BOOLEAN, AcpiGbl_DbOutputToFile);
+ACPI_GLOBAL (char *, AcpiGbl_DbBuffer);
+ACPI_GLOBAL (char *, AcpiGbl_DbFilename);
+ACPI_GLOBAL (UINT32, AcpiGbl_DbDebugLevel);
+ACPI_GLOBAL (UINT32, AcpiGbl_DbConsoleDebugLevel);
+ACPI_GLOBAL (ACPI_NAMESPACE_NODE *, AcpiGbl_DbScopeNode);
-ACPI_EXTERN char *AcpiGbl_DbArgs[ACPI_DEBUGGER_MAX_ARGS];
-ACPI_EXTERN ACPI_OBJECT_TYPE AcpiGbl_DbArgTypes[ACPI_DEBUGGER_MAX_ARGS];
+ACPI_GLOBAL (char *, AcpiGbl_DbArgs[ACPI_DEBUGGER_MAX_ARGS]);
+ACPI_GLOBAL (ACPI_OBJECT_TYPE, AcpiGbl_DbArgTypes[ACPI_DEBUGGER_MAX_ARGS]);
/* These buffers should all be the same size */
-ACPI_EXTERN char AcpiGbl_DbLineBuf[ACPI_DB_LINE_BUFFER_SIZE];
-ACPI_EXTERN char AcpiGbl_DbParsedBuf[ACPI_DB_LINE_BUFFER_SIZE];
-ACPI_EXTERN char AcpiGbl_DbScopeBuf[ACPI_DB_LINE_BUFFER_SIZE];
-ACPI_EXTERN char AcpiGbl_DbDebugFilename[ACPI_DB_LINE_BUFFER_SIZE];
+ACPI_GLOBAL (char, AcpiGbl_DbLineBuf[ACPI_DB_LINE_BUFFER_SIZE]);
+ACPI_GLOBAL (char, AcpiGbl_DbParsedBuf[ACPI_DB_LINE_BUFFER_SIZE]);
+ACPI_GLOBAL (char, AcpiGbl_DbScopeBuf[ACPI_DB_LINE_BUFFER_SIZE]);
+ACPI_GLOBAL (char, AcpiGbl_DbDebugFilename[ACPI_DB_LINE_BUFFER_SIZE]);
/*
* Statistic globals
*/
-ACPI_EXTERN UINT16 AcpiGbl_ObjTypeCount[ACPI_TYPE_NS_NODE_MAX+1];
-ACPI_EXTERN UINT16 AcpiGbl_NodeTypeCount[ACPI_TYPE_NS_NODE_MAX+1];
-ACPI_EXTERN UINT16 AcpiGbl_ObjTypeCountMisc;
-ACPI_EXTERN UINT16 AcpiGbl_NodeTypeCountMisc;
-ACPI_EXTERN UINT32 AcpiGbl_NumNodes;
-ACPI_EXTERN UINT32 AcpiGbl_NumObjects;
-
-
-ACPI_EXTERN UINT32 AcpiGbl_SizeOfParseTree;
-ACPI_EXTERN UINT32 AcpiGbl_SizeOfMethodTrees;
-ACPI_EXTERN UINT32 AcpiGbl_SizeOfNodeEntries;
-ACPI_EXTERN UINT32 AcpiGbl_SizeOfAcpiObjects;
+ACPI_GLOBAL (UINT16, AcpiGbl_ObjTypeCount[ACPI_TYPE_NS_NODE_MAX+1]);
+ACPI_GLOBAL (UINT16, AcpiGbl_NodeTypeCount[ACPI_TYPE_NS_NODE_MAX+1]);
+ACPI_GLOBAL (UINT16, AcpiGbl_ObjTypeCountMisc);
+ACPI_GLOBAL (UINT16, AcpiGbl_NodeTypeCountMisc);
+ACPI_GLOBAL (UINT32, AcpiGbl_NumNodes);
+ACPI_GLOBAL (UINT32, AcpiGbl_NumObjects);
+
+ACPI_GLOBAL (UINT32, AcpiGbl_SizeOfParseTree);
+ACPI_GLOBAL (UINT32, AcpiGbl_SizeOfMethodTrees);
+ACPI_GLOBAL (UINT32, AcpiGbl_SizeOfNodeEntries);
+ACPI_GLOBAL (UINT32, AcpiGbl_SizeOfAcpiObjects);
#endif /* ACPI_DEBUGGER */
@@ -517,7 +507,7 @@ ACPI_EXTERN UINT32 AcpiGbl_SizeOfAcpiObjects;
#ifdef ACPI_APPLICATION
-ACPI_FILE ACPI_INIT_GLOBAL (AcpiGbl_DebugFile, NULL);
+ACPI_INIT_GLOBAL (ACPI_FILE, AcpiGbl_DebugFile, NULL);
#endif /* ACPI_APPLICATION */
@@ -528,7 +518,9 @@ ACPI_FILE ACPI_INIT_GLOBAL (AcpiGbl_DebugFile, NULL);
*
****************************************************************************/
-extern const AH_PREDEFINED_NAME AslPredefinedInfo[];
+extern const AH_PREDEFINED_NAME AslPredefinedInfo[];
+
+#pragma pack(pop) /* Restore original struct packing */
#endif /* __ACGLOBAL_H__ */
diff --git a/source/include/achware.h b/source/include/achware.h
index 1b1331879983..81d1bbf30bc5 100644
--- a/source/include/achware.h
+++ b/source/include/achware.h
@@ -45,6 +45,8 @@
#define __ACHWARE_H__
+#pragma pack(push) /* Set default struct packing */
+
/* Values for the _SST predefined method */
#define ACPI_SST_INDICATOR_OFF 0
@@ -224,4 +226,6 @@ AcpiHwDerivePciId (
ACPI_HANDLE PciRegion);
+#pragma pack(pop) /* Restore original struct packing */
+
#endif /* __ACHWARE_H__ */
diff --git a/source/include/acinterp.h b/source/include/acinterp.h
index 59ade0272cb7..bcb306cff53e 100644
--- a/source/include/acinterp.h
+++ b/source/include/acinterp.h
@@ -45,6 +45,8 @@
#define __ACINTERP_H__
+#pragma pack(push) /* Set default struct packing */
+
#define ACPI_WALK_OPERANDS (&(WalkState->Operands [WalkState->NumOperands -1]))
/* Macros for tables used for debug output */
@@ -89,6 +91,10 @@ typedef const struct acpi_exdump_info
#define ACPI_EXD_PACKAGE 11
#define ACPI_EXD_FIELD 12
#define ACPI_EXD_REFERENCE 13
+#define ACPI_EXD_LIST 14 /* Operand object list */
+#define ACPI_EXD_HDLR_LIST 15 /* Address Handler list */
+#define ACPI_EXD_RGN_LIST 16 /* Region list */
+#define ACPI_EXD_NODE 17 /* Namespace Node */
/* restore default alignment */
@@ -612,14 +618,6 @@ void
AcpiExExitInterpreter (
void);
-void
-AcpiExReacquireInterpreter (
- void);
-
-void
-AcpiExRelinquishInterpreter (
- void);
-
BOOLEAN
AcpiExTruncateFor32bitTable (
ACPI_OPERAND_OBJECT *ObjDesc);
@@ -723,4 +721,6 @@ AcpiExDataTableSpaceHandler (
void *HandlerContext,
void *RegionContext);
+#pragma pack(pop) /* Restore original struct packing */
+
#endif /* __INTERP_H__ */
diff --git a/source/include/aclocal.h b/source/include/aclocal.h
index 8f02f6094742..3234066bf29f 100644
--- a/source/include/aclocal.h
+++ b/source/include/aclocal.h
@@ -45,6 +45,8 @@
#define __ACLOCAL_H__
+#pragma pack(push) /* Set default struct packing */
+
/* acpisrc:StructDefs -- for acpisrc conversion */
#define ACPI_SERIALIZED 0xFF
@@ -1349,4 +1351,6 @@ typedef struct ah_predefined_name
} AH_PREDEFINED_NAME;
+#pragma pack(pop) /* Restore original struct packing */
+
#endif /* __ACLOCAL_H__ */
diff --git a/source/include/acmacros.h b/source/include/acmacros.h
index 19a3e8e23542..1212d0516b9f 100644
--- a/source/include/acmacros.h
+++ b/source/include/acmacros.h
@@ -45,6 +45,8 @@
#define __ACMACROS_H__
+#pragma pack(push) /* Set default struct packing */
+
/*
* Extract data using a pointer. Any more than a byte and we
* get into potential aligment issues -- see the STORE macros below.
@@ -433,4 +435,6 @@
#define ACPI_IS_OCTAL_DIGIT(d) (((char)(d) >= '0') && ((char)(d) <= '7'))
+#pragma pack(pop) /* Restore original struct packing */
+
#endif /* ACMACROS_H */
diff --git a/source/include/acnamesp.h b/source/include/acnamesp.h
index 9fd3841c6c72..a9c7d2212f45 100644
--- a/source/include/acnamesp.h
+++ b/source/include/acnamesp.h
@@ -45,6 +45,8 @@
#define __ACNAMESP_H__
+#pragma pack(push) /* Set default struct packing */
+
/* To search the entire name space, pass this as SearchBase */
#define ACPI_NS_ALL ((ACPI_HANDLE)0)
@@ -535,4 +537,6 @@ void
AcpiNsTerminate (
void);
+#pragma pack(pop) /* Restore original struct packing */
+
#endif /* __ACNAMESP_H__ */
diff --git a/source/include/acobject.h b/source/include/acobject.h
index 654ec8283cfd..040f5b6277e1 100644
--- a/source/include/acobject.h
+++ b/source/include/acobject.h
@@ -44,6 +44,8 @@
#ifndef _ACOBJECT_H
#define _ACOBJECT_H
+#pragma pack(push) /* Set default struct packing */
+
/* acpisrc:StructDefs -- for acpisrc conversion */
@@ -581,6 +583,6 @@ typedef union acpi_descriptor
} ACPI_DESCRIPTOR;
-#pragma pack()
+#pragma pack(pop) /* Restore original struct packing */
#endif /* _ACOBJECT_H */
diff --git a/source/include/acoutput.h b/source/include/acoutput.h
index 8f054ae11929..ff42023e2d96 100644
--- a/source/include/acoutput.h
+++ b/source/include/acoutput.h
@@ -44,6 +44,8 @@
#ifndef __ACOUTPUT_H__
#define __ACOUTPUT_H__
+#pragma pack(push) /* Set default struct packing */
+
/*
* Debug levels and component IDs. These are used to control the
* granularity of the output of the ACPI_DEBUG_PRINT macro -- on a
@@ -464,4 +466,6 @@
#endif /* ACPI_DEBUG_OUTPUT */
+#pragma pack(pop) /* Restore original struct packing */
+
#endif /* __ACOUTPUT_H__ */
diff --git a/source/include/acparser.h b/source/include/acparser.h
index bddd3c114296..74389d2ef778 100644
--- a/source/include/acparser.h
+++ b/source/include/acparser.h
@@ -46,6 +46,8 @@
#define __ACPARSER_H__
+#pragma pack(push) /* Set default struct packing */
+
#define OP_HAS_RETURN_VALUE 1
/* Variable number of arguments. This field must be 32 bits */
@@ -353,4 +355,6 @@ AcpiPsShow (
ACPI_PARSE_OBJECT *op);
+#pragma pack(pop) /* Restore original struct packing */
+
#endif /* __ACPARSER_H__ */
diff --git a/source/include/acpiosxf.h b/source/include/acpiosxf.h
index ebbcb6bd6f61..a97921e169d8 100644
--- a/source/include/acpiosxf.h
+++ b/source/include/acpiosxf.h
@@ -50,6 +50,8 @@
#include "actypes.h"
+#pragma pack(push) /* Set default struct packing */
+
/* Types for AcpiOsExecute */
typedef enum
@@ -551,4 +553,6 @@ AcpiOsCloseDirectory (
#endif
+#pragma pack(pop) /* Restore original struct packing */
+
#endif /* __ACPIOSXF_H__ */
diff --git a/source/include/acpixf.h b/source/include/acpixf.h
index d168353d14b6..a88491f50396 100644
--- a/source/include/acpixf.h
+++ b/source/include/acpixf.h
@@ -47,13 +47,15 @@
/* Current ACPICA subsystem version in YYYYMMDD format */
-#define ACPI_CA_VERSION 0x20140114
+#define ACPI_CA_VERSION 0x20140214
#include "acconfig.h"
#include "actypes.h"
#include "actbl.h"
#include "acbuffer.h"
+#pragma pack(push) /* Set default struct packing */
+
/*
* Globals that are publically available
*/
@@ -70,7 +72,7 @@ extern UINT32 AcpiDbgLayer;
/* ACPICA runtime options */
-extern UINT8 AcpiGbl_AllMethodsSerialized;
+extern UINT8 AcpiGbl_AutoSerializeMethods;
extern UINT8 AcpiGbl_CopyDsdtLocally;
extern UINT8 AcpiGbl_CreateOsiMethod;
extern UINT8 AcpiGbl_DisableAutoRepair;
@@ -831,4 +833,6 @@ AcpiDebugPrintRaw (
...);
#endif
+#pragma pack(pop) /* Restore original struct packing */
+
#endif /* __ACXFACE_H__ */
diff --git a/source/include/acpredef.h b/source/include/acpredef.h
index 1de9888595c6..b8b75997edeb 100644
--- a/source/include/acpredef.h
+++ b/source/include/acpredef.h
@@ -45,11 +45,13 @@
#define __ACPREDEF_H__
+#pragma pack(push) /* Set default struct packing */
+
/******************************************************************************
*
* Return Package types
*
- * 1) PTYPE1 packages do not contain sub-packages.
+ * 1) PTYPE1 packages do not contain subpackages.
*
* ACPI_PTYPE1_FIXED: Fixed-length length, 1 or 2 object types:
* object type
@@ -64,8 +66,8 @@
* (Used for _PRW)
*
*
- * 2) PTYPE2 packages contain a Variable-length number of sub-packages. Each
- * of the different types describe the contents of each of the sub-packages.
+ * 2) PTYPE2 packages contain a Variable-length number of subpackages. Each
+ * of the different types describe the contents of each of the subpackages.
*
* ACPI_PTYPE2: Each subpackage contains 1 or 2 object types. Zero-length
* parent package is allowed:
@@ -554,7 +556,7 @@ const ACPI_PREDEFINED_INFO AcpiGbl_PredefinedMethods[] =
/*
* For _HPX, a single package is returned, containing a variable-length number
- * of sub-packages. Each sub-package contains a PCI record setting.
+ * of subpackages. Each subpackage contains a PCI record setting.
* There are several different type of record settings, of different
* lengths, but all elements of all settings are Integers.
*/
@@ -684,6 +686,12 @@ const ACPI_PREDEFINED_INFO AcpiGbl_PredefinedMethods[] =
METHOD_RETURNS (ACPI_RTYPE_PACKAGE)}}, /* Variable-length (Refs) */
PACKAGE_INFO (ACPI_PTYPE1_VAR, ACPI_RTYPE_REFERENCE, 0,0,0,0),
+ {{"_PRP", METHOD_0ARGS,
+ METHOD_RETURNS (ACPI_RTYPE_PACKAGE)}}, /* Variable-length (Pkgs) each: 1 Str, 1 Int/Str/Pkg */
+ PACKAGE_INFO (ACPI_PTYPE2, ACPI_RTYPE_STRING, 1,
+ ACPI_RTYPE_INTEGER | ACPI_RTYPE_STRING |
+ ACPI_RTYPE_PACKAGE | ACPI_RTYPE_REFERENCE, 1,0),
+
{{"_PRS", METHOD_0ARGS,
METHOD_RETURNS (ACPI_RTYPE_BUFFER)}},
@@ -1061,4 +1069,6 @@ static const ACPI_PREDEFINED_INFO AcpiGbl_ScopeNames[] = {
extern const ACPI_PREDEFINED_INFO AcpiGbl_ResourceNames[];
#endif
+#pragma pack(pop) /* Restore original struct packing */
+
#endif
diff --git a/source/include/acresrc.h b/source/include/acresrc.h
index f761d3f09957..5f658a63933b 100644
--- a/source/include/acresrc.h
+++ b/source/include/acresrc.h
@@ -49,6 +49,8 @@
#include "amlresrc.h"
+#pragma pack(push) /* Set default struct packing */
+
/*
* If possible, pack the following structures to byte alignment, since we
* don't care about performance for debug output. Two cases where we cannot
@@ -437,4 +439,6 @@ extern ACPI_RSDUMP_INFO AcpiRsDumpUartSerialBus[];
extern ACPI_RSDUMP_INFO AcpiRsDumpGeneralFlags[];
#endif
+#pragma pack(pop) /* Restore original struct packing */
+
#endif /* __ACRESRC_H__ */
diff --git a/source/include/acrestyp.h b/source/include/acrestyp.h
index b0412aa63cca..eaea4375db14 100644
--- a/source/include/acrestyp.h
+++ b/source/include/acrestyp.h
@@ -45,6 +45,8 @@
#define __ACRESTYP_H__
+#pragma pack(push) /* Set default struct packing */
+
/*
* Definitions for Resource Attributes
*/
@@ -697,4 +699,6 @@ typedef struct acpi_pci_routing_table
} ACPI_PCI_ROUTING_TABLE;
+#pragma pack(pop) /* Restore original struct packing */
+
#endif /* __ACRESTYP_H__ */
diff --git a/source/include/acstruct.h b/source/include/acstruct.h
index 5d2f4a06e8e0..c52db8f4e177 100644
--- a/source/include/acstruct.h
+++ b/source/include/acstruct.h
@@ -44,6 +44,9 @@
#ifndef __ACSTRUCT_H__
#define __ACSTRUCT_H__
+
+#pragma pack(push) /* Set default struct packing */
+
/* acpisrc:StructDefs -- for acpisrc conversion */
/*****************************************************************************
@@ -139,6 +142,9 @@ typedef struct acpi_init_walk_info
UINT32 TableIndex;
UINT32 ObjectCount;
UINT32 MethodCount;
+ UINT32 SerialMethodCount;
+ UINT32 NonSerialMethodCount;
+ UINT32 SerializedMethodCount;
UINT32 DeviceCount;
UINT32 OpRegionCount;
UINT32 FieldCount;
@@ -267,4 +273,6 @@ typedef struct acpi_walk_info
#define ACPI_DISPLAY_SHORT (UINT8) 2
+#pragma pack(pop) /* Restore original struct packing */
+
#endif
diff --git a/source/include/actables.h b/source/include/actables.h
index 4f006c1734b5..19f4e6d626ac 100644
--- a/source/include/actables.h
+++ b/source/include/actables.h
@@ -45,6 +45,8 @@
#define __ACTABLES_H__
+#pragma pack(push) /* Set default struct packing */
+
ACPI_STATUS
AcpiAllocateRootTable (
UINT32 InitialTableCount);
@@ -194,4 +196,6 @@ ACPI_STATUS
AcpiTbParseRootTable (
ACPI_PHYSICAL_ADDRESS RsdpAddress);
+#pragma pack(pop) /* Restore original struct packing */
+
#endif /* __ACTABLES_H__ */
diff --git a/source/include/actbl.h b/source/include/actbl.h
index 8f5917c96048..980529e02dea 100644
--- a/source/include/actbl.h
+++ b/source/include/actbl.h
@@ -45,6 +45,8 @@
#define __ACTBL_H__
+#pragma pack(push) /* Set default struct packing */
+
/*******************************************************************************
*
* Fundamental ACPI tables
@@ -440,4 +442,6 @@ typedef struct acpi_table_desc
#define ACPI_FADT_V3_SIZE (UINT32) (ACPI_FADT_OFFSET (SleepControl))
#define ACPI_FADT_V5_SIZE (UINT32) (sizeof (ACPI_TABLE_FADT))
+#pragma pack(pop) /* Restore original struct packing */
+
#endif /* __ACTBL_H__ */
diff --git a/source/include/actbl1.h b/source/include/actbl1.h
index ace4da91d878..bd2df958be99 100644
--- a/source/include/actbl1.h
+++ b/source/include/actbl1.h
@@ -45,6 +45,8 @@
#define __ACTBL1_H__
+#pragma pack(push) /* Set default struct packing */
+
/*******************************************************************************
*
* Additional ACPI Tables (1)
@@ -1141,8 +1143,6 @@ typedef struct acpi_srat_x2apic_cpu_affinity
#define ACPI_SRAT_CPU_ENABLED (1) /* 00: Use affinity structure */
-/* Reset to default packing */
-
-#pragma pack()
+#pragma pack(pop) /* Restore original struct packing */
#endif /* __ACTBL1_H__ */
diff --git a/source/include/actbl2.h b/source/include/actbl2.h
index ae46ad8d8124..514ecb0dc93e 100644
--- a/source/include/actbl2.h
+++ b/source/include/actbl2.h
@@ -45,6 +45,8 @@
#define __ACTBL2_H__
+#pragma pack(push) /* Set default struct packing */
+
/*******************************************************************************
*
* Additional ACPI Tables (2)
@@ -1416,8 +1418,6 @@ typedef struct acpi_table_wdrt
} ACPI_TABLE_WDRT;
-/* Reset to default packing */
-
-#pragma pack()
+#pragma pack(pop) /* Restore original struct packing */
#endif /* __ACTBL2_H__ */
diff --git a/source/include/actbl3.h b/source/include/actbl3.h
index ce69acd4549c..1afc341d3159 100644
--- a/source/include/actbl3.h
+++ b/source/include/actbl3.h
@@ -45,6 +45,8 @@
#define __ACTBL3_H__
+#pragma pack(push) /* Set default struct packing */
+
/*******************************************************************************
*
* Additional ACPI Tables (3)
@@ -732,8 +734,6 @@ typedef struct acpi_tpm2_control
} ACPI_TPM2_CONTROL;
-/* Reset to default packing */
-
-#pragma pack()
+#pragma pack(pop) /* Restore original struct packing */
#endif /* __ACTBL3_H__ */
diff --git a/source/include/actypes.h b/source/include/actypes.h
index 4a6e492fc95f..1fa6c696c599 100644
--- a/source/include/actypes.h
+++ b/source/include/actypes.h
@@ -44,6 +44,8 @@
#ifndef __ACTYPES_H__
#define __ACTYPES_H__
+#pragma pack(push) /* Set default struct packing */
+
/* acpisrc:StructDefs -- for acpisrc conversion */
/*
@@ -1315,4 +1317,6 @@ typedef struct acpi_memory_list
#define ACPI_OSI_WIN_8 0x0C
+#pragma pack(pop) /* Restore original struct packing */
+
#endif /* __ACTYPES_H__ */
diff --git a/source/include/acutils.h b/source/include/acutils.h
index c115c24fe4d9..355e5752bf7d 100644
--- a/source/include/acutils.h
+++ b/source/include/acutils.h
@@ -45,6 +45,8 @@
#define _ACUTILS_H
+#pragma pack(push) /* Set default struct packing */
+
extern const UINT8 AcpiGbl_ResourceAmlSizes[];
extern const UINT8 AcpiGbl_ResourceAmlSerialBusSizes[];
@@ -1099,4 +1101,7 @@ AcpiUtMethodError (
const char *Path,
ACPI_STATUS LookupStatus);
+
+#pragma pack(pop) /* Restore original struct packing */
+
#endif /* _ACUTILS_H */
diff --git a/source/include/amlcode.h b/source/include/amlcode.h
index bc8c0b0d3dd0..0695185e522a 100644
--- a/source/include/amlcode.h
+++ b/source/include/amlcode.h
@@ -46,6 +46,9 @@
#ifndef __AMLCODE_H__
#define __AMLCODE_H__
+#pragma pack(push) /* Set default struct packing */
+
+
/* primary opcodes */
#define AML_NULL_CHAR (UINT16) 0x00
@@ -509,4 +512,6 @@ typedef enum
#define AML_METHOD_SYNC_LEVEL 0xF0
+#pragma pack(pop) /* Restore original struct packing */
+
#endif /* __AMLCODE_H__ */
diff --git a/source/include/amlresrc.h b/source/include/amlresrc.h
index 23c4400a0dea..03b1317bf0d9 100644
--- a/source/include/amlresrc.h
+++ b/source/include/amlresrc.h
@@ -47,6 +47,8 @@
#define __AMLRESRC_H
+#pragma pack(push) /* Set default struct packing */
+
/*
* Resource descriptor tags, as defined in the ACPI specification.
* Used to symbolically reference fields within a descriptor.
@@ -574,4 +576,7 @@ typedef union aml_resource
} AML_RESOURCE;
+
+#pragma pack(pop) /* Restore original struct packing */
+
#endif