[PATCH] acpica: update to version 20140424 (LP: #1312351)

Colin King colin.king at canonical.com
Thu Apr 24 18:26:13 UTC 2014


From: Colin Ian King <colin.king at canonical.com>

For the specific ACPICA changes please refer to:

https://lists.acpica.org/pipermail/devel/2014-April/000649.html

The also adds a small shim wrapper in the fwts and fwtsiasl libraries
to access ACPI compiler error levels because of some restructuring
in ACPICA.

This patchset also dismisses 14 issues as found by Coverity Scan.

Signed-off-by: Colin Ian King <colin.king at canonical.com>
---
 src/Makefile.am                                    |   2 +-
 src/acpi/syntaxcheck/syntaxcheck.c                 |   5 +-
 src/acpica/source/common/adisasm.c                 |   1 +
 src/acpica/source/common/ahpredef.c                |   2 +
 src/acpica/source/common/dmtable.c                 |  34 ++
 src/acpica/source/common/dmtbdump.c                | 193 +++++---
 src/acpica/source/common/dmtbinfo.c                |  57 +++
 src/acpica/source/compiler/Makefile.am             |   1 +
 src/acpica/source/compiler/aslanalyze.c            |  48 ++
 src/acpica/source/compiler/aslcompiler.h           |  29 +-
 src/acpica/source/compiler/aslerror.c              | 159 +++----
 src/acpica/source/compiler/aslmessages.c           | 479 +++++++++++++++++++
 src/acpica/source/compiler/aslmessages.h           | 269 ++---------
 src/acpica/source/compiler/aslmethod.c             |  23 +-
 src/acpica/source/compiler/aslprepkg.c             |  12 +
 src/acpica/source/compiler/asltypes.h              |   2 +-
 src/acpica/source/compiler/dtcompiler.h            |  11 +-
 src/acpica/source/compiler/dttable.c               |  83 +++-
 src/acpica/source/compiler/dttemplate.h            |  27 ++
 src/acpica/source/compiler/dtutils.c               |   7 +-
 src/acpica/source/compiler/fwts_iasl_interface.c   |  18 +
 src/acpica/source/compiler/fwts_iasl_interface.h   |   3 +
 src/acpica/source/compiler/preprocess.h            |   2 +-
 src/acpica/source/compiler/prutils.c               |   2 +-
 src/acpica/source/components/debugger/dbcmds.c     |  27 +-
 src/acpica/source/components/debugger/dbinput.c    |   4 +-
 src/acpica/source/components/events/evgpe.c        |  12 +-
 src/acpica/source/components/events/evgpeblk.c     |  28 +-
 src/acpica/source/components/events/evgpeinit.c    |   8 +-
 src/acpica/source/components/events/evxfgpe.c      |   3 +-
 src/acpica/source/components/hardware/hwpci.c      |  13 +-
 src/acpica/source/components/resources/rscreate.c  |  12 +-
 src/acpica/source/components/tables/tbfadt.c       |  50 +-
 src/acpica/source/components/tables/tbutils.c      | 123 +----
 src/acpica/source/components/utilities/utglobal.c  |  30 +-
 src/acpica/source/components/utilities/utobject.c  |   2 +-
 src/acpica/source/components/utilities/utxferror.c |   4 +
 src/acpica/source/include/acdisasm.h               |   8 +
 src/acpica/source/include/acevents.h               |   5 +-
 src/acpica/source/include/acglobal.h               | 143 +-----
 src/acpica/source/include/aclocal.h                |   7 +-
 src/acpica/source/include/acnames.h                |   1 +
 src/acpica/source/include/acpixf.h                 | 518 ++++++++++++++++-----
 src/acpica/source/include/acpredef.h               |   4 +
 src/acpica/source/include/actbl1.h                 |   4 +-
 src/acpica/source/include/actbl2.h                 |  83 +++-
 src/acpica/source/include/actypes.h                |  35 +-
 src/acpica/source/include/platform/aclinux.h       |  33 ++
 .../source/os_specific/service_layers/osunixxf.c   |  23 +-
 src/acpica/source/tools/acpiexec/aehandlers.c      |   2 +-
 src/lib/include/fwts_iasl.h                        |   3 +
 src/lib/src/Makefile.am                            |   2 +-
 src/lib/src/fwts_iasl.c                            |   4 +
 53 files changed, 1799 insertions(+), 861 deletions(-)
 create mode 100755 src/acpica/source/compiler/aslmessages.c

diff --git a/src/Makefile.am b/src/Makefile.am
index 155cba1..ff44b58 100644
--- a/src/Makefile.am
+++ b/src/Makefile.am
@@ -15,7 +15,7 @@ AM_CPPFLAGS = \
 
 bin_PROGRAMS = fwts
 
-fwts_CPPFLAGS = $(AM_CPPFLAGS)
+fwts_CPPFLAGS = $(AM_CPPFLAGS) -DACPI_DEBUG_OUTPUT
 
 #
 #  fwts main + tests
diff --git a/src/acpi/syntaxcheck/syntaxcheck.c b/src/acpi/syntaxcheck/syntaxcheck.c
index 9234c33..5075cbf 100644
--- a/src/acpi/syntaxcheck/syntaxcheck.c
+++ b/src/acpi/syntaxcheck/syntaxcheck.c
@@ -27,8 +27,7 @@
 
 #include <json/json.h>
 
-#define ASL_EXCEPTIONS	/* so we can include AslErrorLevel in aslmessages.h */
-
+#define ASL_EXCEPTIONS
 #include "aslmessages.h"
 
 typedef struct {
@@ -277,7 +276,7 @@ static const char *syntaxcheck_error_level(uint32_t error_code)
 		return "Unknown";
 
 	/* AslErrorLevel strings are end-space padded, so strip off end spaces if any */
-	strncpy(buf, AslErrorLevel[error_level], sizeof(buf));
+	strncpy(buf, fwts_iasl_exception_level((uint8_t)error_level), sizeof(buf));
 	buf[sizeof(buf) -1] = '\0';
 	ptr = strchr(buf, ' ');
 	if (ptr)
diff --git a/src/acpica/source/common/adisasm.c b/src/acpica/source/common/adisasm.c
index 52afb31..df70001 100644
--- a/src/acpica/source/common/adisasm.c
+++ b/src/acpica/source/common/adisasm.c
@@ -429,6 +429,7 @@ AdAmlDisassemble (
         {
             fprintf (stderr, "Could not open output file %s\n", DisasmFilename);
             Status = AE_ERROR;
+            ACPI_FREE (DisasmFilename);
             goto Cleanup;
         }
 
diff --git a/src/acpica/source/common/ahpredef.c b/src/acpica/source/common/ahpredef.c
index 1bb6a8a..21038ab 100644
--- a/src/acpica/source/common/ahpredef.c
+++ b/src/acpica/source/common/ahpredef.c
@@ -244,6 +244,7 @@ const AH_PREDEFINED_NAME    AslPredefinedInfo[] =
     AH_PREDEF ("_LID",    "Lid Status", "Returns the open/closed status of the lid on a mobile system"),
     AH_PREDEF ("_LIN",    "Lines In Use", "Handshake lines, Resource Descriptor field"),
     AH_PREDEF ("_LL_",    "Low Level", "Interrupt polarity, Resource Descriptor field"),
+    AH_PREDEF ("_LPD",    "Low Power Dependencies", "Returns a list of dependencies for low power idle entry"),
     AH_PREDEF ("_MAF",    "Maximum Address Fixed", "Resource Descriptor field"),
     AH_PREDEF ("_MAT",    "Multiple APIC Table Entry", "Returns a list of MADT APIC structure entries"),
     AH_PREDEF ("_MAX",    "Maximum Base Address", "Resource Descriptor field"),
@@ -288,6 +289,7 @@ const AH_PREDEFINED_NAME    AslPredefinedInfo[] =
     AH_PREDEF ("_PR3",    "Power Resources for D3hot", "Returns a list of dependent power resources to enter state D3hot"),
     AH_PREDEF ("_PRE",    "Power Resources for Enumeration", "Returns a list of dependent power resources to enumerate devices on a bus"),
     AH_PREDEF ("_PRL",    "Power Source Redundancy List", "Returns a list of power source devices in the same redundancy grouping"),
+    AH_PREDEF ("_PRP",    "Device Properties", "Returns a list of device property information"),
     AH_PREDEF ("_PRS",    "Possible Resource Settings", "Returns a list of a device's possible resource settings"),
     AH_PREDEF ("_PRT",    "PCI Routing Table", "Returns a list of PCI interrupt mappings"),
     AH_PREDEF ("_PRW",    "Power Resources for Wake", "Returns a list of dependent power resources for waking"),
diff --git a/src/acpica/source/common/dmtable.c b/src/acpica/source/common/dmtable.c
index 35f142c..e2abd7a 100644
--- a/src/acpica/source/common/dmtable.c
+++ b/src/acpica/source/common/dmtable.c
@@ -313,6 +313,12 @@ static const char           *AcpiDmIvrsSubnames[] =
     "Unknown SubTable Type"         /* Reserved */
 };
 
+static const char           *AcpiDmLpitSubnames[] =
+{
+    "Native C-state Idle Structure",
+    "Simple I/O Idle Structure",
+    "Unknown SubTable Type"         /* Reserved */
+};
 
 #define ACPI_FADT_PM_RESERVED       9
 
@@ -376,6 +382,7 @@ ACPI_DMTABLE_DATA    AcpiDmTableData[] =
     {ACPI_SIG_HEST, NULL,                   AcpiDmDumpHest, DtCompileHest,  TemplateHest,   "Hardware Error Source Table"},
     {ACPI_SIG_HPET, AcpiDmTableInfoHpet,    NULL,           NULL,           TemplateHpet,   "High Precision Event Timer table"},
     {ACPI_SIG_IVRS, NULL,                   AcpiDmDumpIvrs, DtCompileIvrs,  TemplateIvrs,   "I/O Virtualization Reporting Structure"},
+    {ACPI_SIG_LPIT, NULL,                   AcpiDmDumpLpit, DtCompileLpit,  TemplateLpit,   "Low Power Idle Table"},
     {ACPI_SIG_MADT, NULL,                   AcpiDmDumpMadt, DtCompileMadt,  TemplateMadt,   "Multiple APIC Description Table (MADT)"},
     {ACPI_SIG_MCFG, NULL,                   AcpiDmDumpMcfg, DtCompileMcfg,  TemplateMcfg,   "Memory Mapped Configuration table"},
     {ACPI_SIG_MCHI, AcpiDmTableInfoMchi,    NULL,           NULL,           TemplateMchi,   "Management Controller Host Interface table"},
@@ -801,6 +808,7 @@ AcpiDmDumpTable (
         case ACPI_DMT_NAME4:
         case ACPI_DMT_SIG:
         case ACPI_DMT_SLIC:
+        case ACPI_DMT_LPIT:
 
             ByteLength = 4;
             break;
@@ -1304,6 +1312,32 @@ AcpiDmDumpTable (
             AcpiOsPrintf (UINT8_FORMAT, *Target, Name);
             break;
 
+        case ACPI_DMT_LPIT:
+
+            /* LPIT subtable types */
+
+            Temp8 = *Target;
+            switch (Temp8)
+            {
+            case ACPI_LPIT_TYPE_NATIVE_CSTATE:
+
+                Name = AcpiDmLpitSubnames[0];
+                break;
+
+            case ACPI_LPIT_TYPE_SIMPLE_IO:
+
+                Name = AcpiDmLpitSubnames[1];
+                break;
+
+            default:
+
+                Name = AcpiDmLpitSubnames[2];
+                break;
+            }
+
+            AcpiOsPrintf (UINT32_FORMAT, *Target, Name);
+            break;
+
         case ACPI_DMT_EXIT:
 
             return (AE_OK);
diff --git a/src/acpica/source/common/dmtbdump.c b/src/acpica/source/common/dmtbdump.c
index f2a6762..70e9d4e 100644
--- a/src/acpica/source/common/dmtbdump.c
+++ b/src/acpica/source/common/dmtbdump.c
@@ -491,12 +491,12 @@ AcpiDmDumpAsf (
     UINT8                   Type;
 
 
-    /* No main table, only sub-tables */
+    /* No main table, only subtables */
 
     SubTable = ACPI_ADD_PTR (ACPI_ASF_INFO, Table, Offset);
     while (Offset < Table->Length)
     {
-        /* Common sub-table header */
+        /* Common subtable header */
 
         Status = AcpiDmDumpTable (Table->Length, Offset, SubTable,
                     SubTable->Header.Length, AcpiDmTableInfoAsfHdr);
@@ -551,7 +551,7 @@ AcpiDmDumpAsf (
 
         default:
 
-            AcpiOsPrintf ("\n**** Unknown ASF sub-table type 0x%X\n", SubTable->Header.Type);
+            AcpiOsPrintf ("\n**** Unknown ASF subtable type 0x%X\n", SubTable->Header.Type);
             return;
         }
 
@@ -613,7 +613,7 @@ AcpiDmDumpAsf (
 
         AcpiOsPrintf ("\n");
 
-        /* Point to next sub-table */
+        /* Point to next subtable */
 
         if (!SubTable->Header.Length)
         {
@@ -658,7 +658,7 @@ AcpiDmDumpCpep (
         return;
     }
 
-    /* Sub-tables */
+    /* Subtables */
 
     SubTable = ACPI_ADD_PTR (ACPI_CPEP_POLLING, Table, Offset);
     while (Offset < Table->Length)
@@ -671,7 +671,7 @@ AcpiDmDumpCpep (
             return;
         }
 
-        /* Point to next sub-table */
+        /* Point to next subtable */
 
         Offset += SubTable->Header.Length;
         SubTable = ACPI_ADD_PTR (ACPI_CPEP_POLLING, SubTable,
@@ -710,7 +710,7 @@ AcpiDmDumpCsrt (
 
     /* The main table only contains the ACPI header, thus already handled */
 
-    /* Sub-tables (Resource Groups) */
+    /* Subtables (Resource Groups) */
 
     SubTable = ACPI_ADD_PTR (ACPI_CSRT_GROUP, Table, Offset);
     while (Offset < Table->Length)
@@ -774,7 +774,7 @@ AcpiDmDumpCsrt (
                         SubSubTable->Length);
         }
 
-        /* Point to next sub-table */
+        /* Point to next subtable */
 
         Offset += SubTable->Length;
         SubTable = ACPI_ADD_PTR (ACPI_CSRT_GROUP, SubTable,
@@ -818,7 +818,7 @@ AcpiDmDumpDbg2 (
         return;
     }
 
-    /* Sub-tables */
+    /* Subtables */
 
     SubTable = ACPI_ADD_PTR (ACPI_DBG2_DEVICE, Table, Offset);
     while (Offset < Table->Length)
@@ -887,7 +887,7 @@ AcpiDmDumpDbg2 (
                 Offset + SubTable->OemDataOffset, "OEM Data");
         }
 
-        /* Point to next sub-table */
+        /* Point to next subtable */
 
         Offset += SubTable->Length;
         SubTable = ACPI_ADD_PTR (ACPI_DBG2_DEVICE, SubTable,
@@ -933,12 +933,12 @@ AcpiDmDumpDmar (
         return;
     }
 
-    /* Sub-tables */
+    /* Subtables */
 
     SubTable = ACPI_ADD_PTR (ACPI_DMAR_HEADER, Table, Offset);
     while (Offset < Table->Length)
     {
-        /* Common sub-table header */
+        /* Common subtable header */
 
         AcpiOsPrintf ("\n");
         Status = AcpiDmDumpTable (Length, Offset, SubTable,
@@ -977,7 +977,7 @@ AcpiDmDumpDmar (
 
         default:
 
-            AcpiOsPrintf ("\n**** Unknown DMAR sub-table type 0x%X\n\n", SubTable->Type);
+            AcpiOsPrintf ("\n**** Unknown DMAR subtable type 0x%X\n\n", SubTable->Type);
             return;
         }
 
@@ -1028,7 +1028,7 @@ AcpiDmDumpDmar (
                 ScopeTable, ScopeTable->Length);
         }
 
-        /* Point to next sub-table */
+        /* Point to next subtable */
 
         Offset += SubTable->Length;
         SubTable = ACPI_ADD_PTR (ACPI_DMAR_HEADER, SubTable, SubTable->Length);
@@ -1067,7 +1067,7 @@ AcpiDmDumpEinj (
         return;
     }
 
-    /* Sub-tables */
+    /* Subtables */
 
     SubTable = ACPI_ADD_PTR (ACPI_WHEA_HEADER, Table, Offset);
     while (Offset < Table->Length)
@@ -1080,7 +1080,7 @@ AcpiDmDumpEinj (
             return;
         }
 
-        /* Point to next sub-table (each subtable is of fixed length) */
+        /* Point to next subtable (each subtable is of fixed length) */
 
         Offset += sizeof (ACPI_WHEA_HEADER);
         SubTable = ACPI_ADD_PTR (ACPI_WHEA_HEADER, SubTable,
@@ -1120,7 +1120,7 @@ AcpiDmDumpErst (
         return;
     }
 
-    /* Sub-tables */
+    /* Subtables */
 
     SubTable = ACPI_ADD_PTR (ACPI_WHEA_HEADER, Table, Offset);
     while (Offset < Table->Length)
@@ -1133,7 +1133,7 @@ AcpiDmDumpErst (
             return;
         }
 
-        /* Point to next sub-table (each subtable is of fixed length) */
+        /* Point to next subtable (each subtable is of fixed length) */
 
         Offset += sizeof (ACPI_WHEA_HEADER);
         SubTable = ACPI_ADD_PTR (ACPI_WHEA_HEADER, SubTable,
@@ -1168,12 +1168,12 @@ AcpiDmDumpFpdt (
 
     /* There is no main table (other than the standard ACPI header) */
 
-    /* Sub-tables */
+    /* Subtables */
 
     SubTable = ACPI_ADD_PTR (ACPI_FPDT_HEADER, Table, Offset);
     while (Offset < Table->Length)
     {
-        /* Common sub-table header */
+        /* Common subtable header */
 
         AcpiOsPrintf ("\n");
         Status = AcpiDmDumpTable (Length, Offset, SubTable,
@@ -1197,7 +1197,7 @@ AcpiDmDumpFpdt (
 
         default:
 
-            AcpiOsPrintf ("\n**** Unknown FPDT sub-table type 0x%X\n\n", SubTable->Type);
+            AcpiOsPrintf ("\n**** Unknown FPDT subtable type 0x%X\n\n", SubTable->Type);
 
             /* Attempt to continue */
 
@@ -1217,7 +1217,7 @@ AcpiDmDumpFpdt (
         }
 
 NextSubTable:
-        /* Point to next sub-table */
+        /* Point to next subtable */
 
         Offset += SubTable->Length;
         SubTable = ACPI_ADD_PTR (ACPI_FPDT_HEADER, SubTable, SubTable->Length);
@@ -1260,7 +1260,7 @@ AcpiDmDumpHest (
         return;
     }
 
-    /* Sub-tables */
+    /* Subtables */
 
     SubTable = ACPI_ADD_PTR (ACPI_HEST_HEADER, Table, Offset);
     while (Offset < Table->Length)
@@ -1318,7 +1318,7 @@ AcpiDmDumpHest (
 
             /* Cannot continue on unknown type - no length */
 
-            AcpiOsPrintf ("\n**** Unknown HEST sub-table type 0x%X\n", SubTable->Type);
+            AcpiOsPrintf ("\n**** Unknown HEST subtable type 0x%X\n", SubTable->Type);
             return;
         }
 
@@ -1356,7 +1356,7 @@ AcpiDmDumpHest (
             }
         }
 
-        /* Point to next sub-table */
+        /* Point to next subtable */
 
         SubTable = ACPI_ADD_PTR (ACPI_HEST_HEADER, SubTable, SubTableLength);
     }
@@ -1399,12 +1399,12 @@ AcpiDmDumpIvrs (
         return;
     }
 
-    /* Sub-tables */
+    /* Subtables */
 
     SubTable = ACPI_ADD_PTR (ACPI_IVRS_HEADER, Table, Offset);
     while (Offset < Table->Length)
     {
-        /* Common sub-table header */
+        /* Common subtable header */
 
         AcpiOsPrintf ("\n");
         Status = AcpiDmDumpTable (Table->Length, Offset, SubTable,
@@ -1430,7 +1430,7 @@ AcpiDmDumpIvrs (
 
         default:
 
-            AcpiOsPrintf ("\n**** Unknown IVRS sub-table type 0x%X\n",
+            AcpiOsPrintf ("\n**** Unknown IVRS subtable type 0x%X\n",
                 SubTable->Type);
 
             /* Attempt to continue */
@@ -1533,7 +1533,7 @@ AcpiDmDumpIvrs (
         }
 
 NextSubTable:
-        /* Point to next sub-table */
+        /* Point to next subtable */
 
         Offset += SubTable->Length;
         SubTable = ACPI_ADD_PTR (ACPI_IVRS_HEADER, SubTable, SubTable->Length);
@@ -1543,6 +1543,85 @@ NextSubTable:
 
 /*******************************************************************************
  *
+ * FUNCTION:    AcpiDmDumpLpit
+ *
+ * PARAMETERS:  Table               - A LPIT table
+ *
+ * RETURN:      None
+ *
+ * DESCRIPTION: Format the contents of a LPIT. This table type consists
+ *              of an open-ended number of subtables. Note: There are no
+ *              entries in the main table. An LPIT consists of the table
+ *              header and then subtables only.
+ *
+ ******************************************************************************/
+
+void
+AcpiDmDumpLpit (
+    ACPI_TABLE_HEADER       *Table)
+{
+    ACPI_STATUS             Status;
+    ACPI_LPIT_HEADER        *SubTable;
+    UINT32                  Length = Table->Length;
+    UINT32                  Offset = sizeof (ACPI_TABLE_LPIT);
+    ACPI_DMTABLE_INFO       *InfoTable;
+    UINT32                  SubTableLength;
+
+
+    /* Subtables */
+
+    SubTable = ACPI_ADD_PTR (ACPI_LPIT_HEADER, Table, Offset);
+    while (Offset < Table->Length)
+    {
+        /* Common subtable header */
+
+        Status = AcpiDmDumpTable (Length, Offset, SubTable,
+                    sizeof (ACPI_LPIT_HEADER), AcpiDmTableInfoLpitHdr);
+        if (ACPI_FAILURE (Status))
+        {
+            return;
+        }
+
+        switch (SubTable->Type)
+        {
+        case ACPI_LPIT_TYPE_NATIVE_CSTATE:
+
+            InfoTable = AcpiDmTableInfoLpit0;
+            SubTableLength = sizeof (ACPI_LPIT_NATIVE);
+            break;
+
+        case ACPI_LPIT_TYPE_SIMPLE_IO:
+
+            InfoTable = AcpiDmTableInfoLpit1;
+            SubTableLength = sizeof (ACPI_LPIT_IO);
+            break;
+
+        default:
+
+            /* Cannot continue on unknown type - no length */
+
+            AcpiOsPrintf ("\n**** Unknown LPIT subtable type 0x%X\n", SubTable->Type);
+            return;
+        }
+
+        Status = AcpiDmDumpTable (Length, Offset, SubTable,
+                    SubTableLength, InfoTable);
+        if (ACPI_FAILURE (Status))
+        {
+            return;
+        }
+        AcpiOsPrintf ("\n");
+
+        /* Point to next subtable */
+
+        Offset += SubTableLength;
+        SubTable = ACPI_ADD_PTR (ACPI_LPIT_HEADER, SubTable, SubTableLength);
+    }
+}
+
+
+/*******************************************************************************
+ *
  * FUNCTION:    AcpiDmDumpMadt
  *
  * PARAMETERS:  Table               - A MADT table
@@ -1573,12 +1652,12 @@ AcpiDmDumpMadt (
         return;
     }
 
-    /* Sub-tables */
+    /* Subtables */
 
     SubTable = ACPI_ADD_PTR (ACPI_SUBTABLE_HEADER, Table, Offset);
     while (Offset < Table->Length)
     {
-        /* Common sub-table header */
+        /* Common subtable header */
 
         AcpiOsPrintf ("\n");
         Status = AcpiDmDumpTable (Length, Offset, SubTable,
@@ -1657,7 +1736,7 @@ AcpiDmDumpMadt (
 
         default:
 
-            AcpiOsPrintf ("\n**** Unknown MADT sub-table type 0x%X\n\n", SubTable->Type);
+            AcpiOsPrintf ("\n**** Unknown MADT subtable type 0x%X\n\n", SubTable->Type);
 
             /* Attempt to continue */
 
@@ -1677,7 +1756,7 @@ AcpiDmDumpMadt (
         }
 
 NextSubTable:
-        /* Point to next sub-table */
+        /* Point to next subtable */
 
         Offset += SubTable->Length;
         SubTable = ACPI_ADD_PTR (ACPI_SUBTABLE_HEADER, SubTable, SubTable->Length);
@@ -1714,7 +1793,7 @@ AcpiDmDumpMcfg (
         return;
     }
 
-    /* Sub-tables */
+    /* Subtables */
 
     SubTable = ACPI_ADD_PTR (ACPI_MCFG_ALLOCATION, Table, Offset);
     while (Offset < Table->Length)
@@ -1734,7 +1813,7 @@ AcpiDmDumpMcfg (
             return;
         }
 
-        /* Point to next sub-table (each subtable is of fixed length) */
+        /* Point to next subtable (each subtable is of fixed length) */
 
         Offset += sizeof (ACPI_MCFG_ALLOCATION);
         SubTable = ACPI_ADD_PTR (ACPI_MCFG_ALLOCATION, SubTable,
@@ -1916,12 +1995,12 @@ AcpiDmDumpMsct (
         return;
     }
 
-    /* Sub-tables */
+    /* Subtables */
 
     SubTable = ACPI_ADD_PTR (ACPI_MSCT_PROXIMITY, Table, Offset);
     while (Offset < Table->Length)
     {
-        /* Common sub-table header */
+        /* Common subtable header */
 
         AcpiOsPrintf ("\n");
         Status = AcpiDmDumpTable (Table->Length, Offset, SubTable,
@@ -1931,7 +2010,7 @@ AcpiDmDumpMsct (
             return;
         }
 
-        /* Point to next sub-table */
+        /* Point to next subtable */
 
         Offset += sizeof (ACPI_MSCT_PROXIMITY);
         SubTable = ACPI_ADD_PTR (ACPI_MSCT_PROXIMITY, SubTable, sizeof (ACPI_MSCT_PROXIMITY));
@@ -1968,12 +2047,12 @@ AcpiDmDumpMtmr (
         return;
     }
 
-    /* Sub-tables */
+    /* Subtables */
 
     SubTable = ACPI_ADD_PTR (ACPI_MTMR_ENTRY, Table, Offset);
     while (Offset < Table->Length)
     {
-        /* Common sub-table header */
+        /* Common subtable header */
 
         AcpiOsPrintf ("\n");
         Status = AcpiDmDumpTable (Table->Length, Offset, SubTable,
@@ -1983,7 +2062,7 @@ AcpiDmDumpMtmr (
             return;
         }
 
-        /* Point to next sub-table */
+        /* Point to next subtable */
 
         Offset += sizeof (ACPI_MTMR_ENTRY);
         SubTable = ACPI_ADD_PTR (ACPI_MTMR_ENTRY, SubTable, sizeof (ACPI_MTMR_ENTRY));
@@ -2304,7 +2383,7 @@ AcpiDmDumpS3pt (
     SubTable = ACPI_ADD_PTR (ACPI_S3PT_HEADER, S3ptTable, Offset);
     while (Offset < S3ptTable->Length)
     {
-        /* Common sub-table header */
+        /* Common subtable header */
 
         AcpiOsPrintf ("\n");
         Status = AcpiDmDumpTable (S3ptTable->Length, Offset, SubTable,
@@ -2328,7 +2407,7 @@ AcpiDmDumpS3pt (
 
         default:
 
-            AcpiOsPrintf ("\n**** Unknown S3PT sub-table type 0x%X\n", SubTable->Type);
+            AcpiOsPrintf ("\n**** Unknown S3PT subtable type 0x%X\n", SubTable->Type);
 
             /* Attempt to continue */
 
@@ -2349,7 +2428,7 @@ AcpiDmDumpS3pt (
         }
 
 NextSubTable:
-        /* Point to next sub-table */
+        /* Point to next subtable */
 
         Offset += SubTable->Length;
         SubTable = ACPI_ADD_PTR (ACPI_S3PT_HEADER, SubTable, SubTable->Length);
@@ -2386,7 +2465,7 @@ AcpiDmDumpSlic (
     SubTable = ACPI_ADD_PTR (ACPI_SLIC_HEADER, Table, Offset);
     while (Offset < Table->Length)
     {
-        /* Common sub-table header */
+        /* Common subtable header */
 
         AcpiOsPrintf ("\n");
         Status = AcpiDmDumpTable (Table->Length, Offset, SubTable,
@@ -2410,7 +2489,7 @@ AcpiDmDumpSlic (
 
         default:
 
-            AcpiOsPrintf ("\n**** Unknown SLIC sub-table type 0x%X\n", SubTable->Type);
+            AcpiOsPrintf ("\n**** Unknown SLIC subtable type 0x%X\n", SubTable->Type);
 
             /* Attempt to continue */
 
@@ -2431,7 +2510,7 @@ AcpiDmDumpSlic (
         }
 
 NextSubTable:
-        /* Point to next sub-table */
+        /* Point to next subtable */
 
         Offset += SubTable->Length;
         SubTable = ACPI_ADD_PTR (ACPI_SLIC_HEADER, SubTable, SubTable->Length);
@@ -2547,12 +2626,12 @@ AcpiDmDumpSrat (
         return;
     }
 
-    /* Sub-tables */
+    /* Subtables */
 
     SubTable = ACPI_ADD_PTR (ACPI_SUBTABLE_HEADER, Table, Offset);
     while (Offset < Table->Length)
     {
-        /* Common sub-table header */
+        /* Common subtable header */
 
         AcpiOsPrintf ("\n");
         Status = AcpiDmDumpTable (Table->Length, Offset, SubTable,
@@ -2580,7 +2659,7 @@ AcpiDmDumpSrat (
             break;
 
         default:
-            AcpiOsPrintf ("\n**** Unknown SRAT sub-table type 0x%X\n", SubTable->Type);
+            AcpiOsPrintf ("\n**** Unknown SRAT subtable type 0x%X\n", SubTable->Type);
 
             /* Attempt to continue */
 
@@ -2601,7 +2680,7 @@ AcpiDmDumpSrat (
         }
 
 NextSubTable:
-        /* Point to next sub-table */
+        /* Point to next subtable */
 
         Offset += SubTable->Length;
         SubTable = ACPI_ADD_PTR (ACPI_SUBTABLE_HEADER, SubTable, SubTable->Length);
@@ -2638,12 +2717,12 @@ AcpiDmDumpVrtc (
         return;
     }
 
-    /* Sub-tables */
+    /* Subtables */
 
     SubTable = ACPI_ADD_PTR (ACPI_VRTC_ENTRY, Table, Offset);
     while (Offset < Table->Length)
     {
-        /* Common sub-table header */
+        /* Common subtable header */
 
         AcpiOsPrintf ("\n");
         Status = AcpiDmDumpTable (Table->Length, Offset, SubTable,
@@ -2653,7 +2732,7 @@ AcpiDmDumpVrtc (
             return;
         }
 
-        /* Point to next sub-table */
+        /* Point to next subtable */
 
         Offset += sizeof (ACPI_VRTC_ENTRY);
         SubTable = ACPI_ADD_PTR (ACPI_VRTC_ENTRY, SubTable, sizeof (ACPI_VRTC_ENTRY));
@@ -2690,12 +2769,12 @@ AcpiDmDumpWdat (
         return;
     }
 
-    /* Sub-tables */
+    /* Subtables */
 
     SubTable = ACPI_ADD_PTR (ACPI_WDAT_ENTRY, Table, Offset);
     while (Offset < Table->Length)
     {
-        /* Common sub-table header */
+        /* Common subtable header */
 
         AcpiOsPrintf ("\n");
         Status = AcpiDmDumpTable (Table->Length, Offset, SubTable,
@@ -2705,7 +2784,7 @@ AcpiDmDumpWdat (
             return;
         }
 
-        /* Point to next sub-table */
+        /* Point to next subtable */
 
         Offset += sizeof (ACPI_WDAT_ENTRY);
         SubTable = ACPI_ADD_PTR (ACPI_WDAT_ENTRY, SubTable, sizeof (ACPI_WDAT_ENTRY));
diff --git a/src/acpica/source/common/dmtbinfo.c b/src/acpica/source/common/dmtbinfo.c
index cd565a4..7a9520d 100644
--- a/src/acpica/source/common/dmtbinfo.c
+++ b/src/acpica/source/common/dmtbinfo.c
@@ -230,6 +230,9 @@
 #define ACPI_IVRS8A_OFFSET(f)           (UINT16) ACPI_OFFSET (ACPI_IVRS_DEVICE8A,f)
 #define ACPI_IVRS8B_OFFSET(f)           (UINT16) ACPI_OFFSET (ACPI_IVRS_DEVICE8B,f)
 #define ACPI_IVRS8C_OFFSET(f)           (UINT16) ACPI_OFFSET (ACPI_IVRS_DEVICE8C,f)
+#define ACPI_LPITH_OFFSET(f)            (UINT16) ACPI_OFFSET (ACPI_LPIT_HEADER,f)
+#define ACPI_LPIT0_OFFSET(f)            (UINT16) ACPI_OFFSET (ACPI_LPIT_NATIVE,f)
+#define ACPI_LPIT1_OFFSET(f)            (UINT16) ACPI_OFFSET (ACPI_LPIT_IO,f)
 #define ACPI_MADT0_OFFSET(f)            (UINT16) ACPI_OFFSET (ACPI_MADT_LOCAL_APIC,f)
 #define ACPI_MADT1_OFFSET(f)            (UINT16) ACPI_OFFSET (ACPI_MADT_IO_APIC,f)
 #define ACPI_MADT2_OFFSET(f)            (UINT16) ACPI_OFFSET (ACPI_MADT_INTERRUPT_OVERRIDE,f)
@@ -285,6 +288,7 @@
 #define ACPI_SRAT1_FLAG_OFFSET(f,o)     ACPI_FLAG_OFFSET (ACPI_SRAT_MEM_AFFINITY,f,o)
 #define ACPI_SRAT2_FLAG_OFFSET(f,o)     ACPI_FLAG_OFFSET (ACPI_SRAT_X2APIC_CPU_AFFINITY,f,o)
 #define ACPI_GTDT_FLAG_OFFSET(f,o)      ACPI_FLAG_OFFSET (ACPI_TABLE_GTDT,f,o)
+#define ACPI_LPITH_FLAG_OFFSET(f,o)     ACPI_FLAG_OFFSET (ACPI_LPIT_HEADER,f,o)
 #define ACPI_MADT_FLAG_OFFSET(f,o)      ACPI_FLAG_OFFSET (ACPI_TABLE_MADT,f,o)
 #define ACPI_MADT0_FLAG_OFFSET(f,o)     ACPI_FLAG_OFFSET (ACPI_MADT_LOCAL_APIC,f,o)
 #define ACPI_MADT2_FLAG_OFFSET(f,o)     ACPI_FLAG_OFFSET (ACPI_MADT_INTERRUPT_OVERRIDE,f,o)
@@ -1379,6 +1383,59 @@ ACPI_DMTABLE_INFO           AcpiDmTableInfoIvrs8c[] =
 
 /*******************************************************************************
  *
+ * LPIT - Low Power Idle Table
+ *
+ ******************************************************************************/
+
+/* Main table consists only of the standard ACPI table header */
+
+/* Common Subtable header (one per Subtable) */
+
+ACPI_DMTABLE_INFO           AcpiDmTableInfoLpitHdr[] =
+{
+    {ACPI_DMT_LPIT,     ACPI_LPITH_OFFSET (Type),                   "Subtable Type", 0},
+    {ACPI_DMT_UINT32,   ACPI_LPITH_OFFSET (Length),                 "Length", DT_LENGTH},
+    {ACPI_DMT_UINT16,   ACPI_LPITH_OFFSET (UniqueId),               "Unique ID", 0},
+    {ACPI_DMT_UINT16,   ACPI_LPITH_OFFSET (Reserved),               "Reserved", 0},
+    {ACPI_DMT_UINT32,   ACPI_LPITH_OFFSET (Flags),                  "Flags (decoded below)", DT_FLAG},
+    {ACPI_DMT_FLAG0,    ACPI_LPITH_FLAG_OFFSET (Flags, 0),          "State Disabled", 0},
+    {ACPI_DMT_FLAG1,    ACPI_LPITH_FLAG_OFFSET (Flags, 0),          "No Counter", 0},
+    ACPI_DMT_TERMINATOR
+};
+
+/* LPIT Subtables */
+
+/* 0: Native C-state */
+
+ACPI_DMTABLE_INFO           AcpiDmTableInfoLpit0[] =
+{
+    {ACPI_DMT_GAS,      ACPI_LPIT0_OFFSET (EntryTrigger),           "Entry Trigger", 0},
+    {ACPI_DMT_UINT32,   ACPI_LPIT0_OFFSET (Residency),              "Residency", 0},
+    {ACPI_DMT_UINT32,   ACPI_LPIT0_OFFSET (Latency),                "Latency", 0},
+    {ACPI_DMT_GAS,      ACPI_LPIT0_OFFSET (ResidencyCounter),       "Residency Counter", 0},
+    {ACPI_DMT_UINT64,   ACPI_LPIT0_OFFSET (CounterFrequency),       "Counter Frequency", 0},
+    ACPI_DMT_TERMINATOR
+};
+
+/* 1: Simple I/O */
+
+ACPI_DMTABLE_INFO           AcpiDmTableInfoLpit1[] =
+{
+    {ACPI_DMT_GAS,      ACPI_LPIT1_OFFSET (EntryTrigger),           "Entry Trigger", 0},
+    {ACPI_DMT_UINT32,   ACPI_LPIT1_OFFSET (TriggerAction),          "Trigger Action", 0},
+    {ACPI_DMT_UINT64,   ACPI_LPIT1_OFFSET (TriggerValue),           "Trigger Value", 0},
+    {ACPI_DMT_UINT64,   ACPI_LPIT1_OFFSET (TriggerMask),            "Trigger Mask", 0},
+    {ACPI_DMT_GAS,      ACPI_LPIT1_OFFSET (MinimumIdleState),       "Minimum Idle State", 0},
+    {ACPI_DMT_UINT32,   ACPI_LPIT1_OFFSET (Residency),              "Residency", 0},
+    {ACPI_DMT_UINT32,   ACPI_LPIT1_OFFSET (Latency),                "Latency", 0},
+    {ACPI_DMT_GAS,      ACPI_LPIT1_OFFSET (ResidencyCounter),       "Residency Counter", 0},
+    {ACPI_DMT_UINT64,   ACPI_LPIT1_OFFSET (CounterFrequency),       "Counter Frequency", 0},
+    ACPI_DMT_TERMINATOR
+};
+
+
+/*******************************************************************************
+ *
  * MADT - Multiple APIC Description Table and subtables
  *
  ******************************************************************************/
diff --git a/src/acpica/source/compiler/Makefile.am b/src/acpica/source/compiler/Makefile.am
index 1c215b2..d306e56 100644
--- a/src/acpica/source/compiler/Makefile.am
+++ b/src/acpica/source/compiler/Makefile.am
@@ -72,6 +72,7 @@ libfwtsiasl_la_SOURCES = 			\
 	aslload.c 				\
 	asllookup.c 				\
 	aslmap.c 				\
+	aslmessages.c				\
 	aslopcodes.c 				\
 	asloperands.c 				\
 	aslopt.c 				\
diff --git a/src/acpica/source/compiler/aslanalyze.c b/src/acpica/source/compiler/aslanalyze.c
index 16e28d3..8bfc9ac 100644
--- a/src/acpica/source/compiler/aslanalyze.c
+++ b/src/acpica/source/compiler/aslanalyze.c
@@ -641,3 +641,51 @@ ApCheckRegMethod (
 
     AslError (ASL_WARNING, ASL_MSG_NO_REGION, Op, NULL);
 }
+
+
+/*******************************************************************************
+ *
+ * FUNCTION:    ApFindNameInScope
+ *
+ * PARAMETERS:  Name                - Name to search for
+ *              Op                  - Current parse op
+ *
+ * RETURN:      TRUE if name found in the same scope as Op.
+ *
+ * DESCRIPTION: Determine if a name appears in the same scope as Op, as either
+ *              a Method() or a Name().
+ *
+ ******************************************************************************/
+
+BOOLEAN
+ApFindNameInScope (
+    char                    *Name,
+    ACPI_PARSE_OBJECT       *Op)
+{
+    ACPI_PARSE_OBJECT       *Next;
+    ACPI_PARSE_OBJECT       *Parent;
+
+
+    /* Get the start of the current scope */
+
+    Parent = Op->Asl.Parent;
+    Next = Parent->Asl.Child;
+
+    /* Search entire scope for a match to the name */
+
+    while (Next)
+    {
+        if ((Next->Asl.ParseOpcode == PARSEOP_METHOD) ||
+            (Next->Asl.ParseOpcode == PARSEOP_NAME))
+        {
+            if (ACPI_COMPARE_NAME (Name, Next->Asl.NameSeg))
+            {
+                return (TRUE);
+            }
+        }
+
+        Next = Next->Asl.Next;
+    }
+
+    return (FALSE);
+}
diff --git a/src/acpica/source/compiler/aslcompiler.h b/src/acpica/source/compiler/aslcompiler.h
index 49dc7fb..c7692ca 100644
--- a/src/acpica/source/compiler/aslcompiler.h
+++ b/src/acpica/source/compiler/aslcompiler.h
@@ -347,6 +347,11 @@ void
 ApCheckRegMethod (
     ACPI_PARSE_OBJECT       *Op);
 
+BOOLEAN
+ApFindNameInScope (
+    char                    *Name,
+    ACPI_PARSE_OBJECT       *Op);
+
 
 /*
  * aslerror - error handling/reporting
@@ -358,7 +363,7 @@ AslAbort (
 void
 AslError (
     UINT8                   Level,
-    UINT8                   MessageId,
+    UINT16                  MessageId,
     ACPI_PARSE_OBJECT       *Op,
     char                    *ExtraMessage);
 
@@ -369,7 +374,7 @@ AslDisableException (
 BOOLEAN
 AslIsExceptionDisabled (
     UINT8                   Level,
-    UINT8                   MessageId);
+    UINT16                  MessageId);
 
 void
 AslCoreSubsystemError (
@@ -385,7 +390,7 @@ AslCompilererror(
 void
 AslCommonError (
     UINT8                   Level,
-    UINT8                   MessageId,
+    UINT16                  MessageId,
     UINT32                  CurrentLineNumber,
     UINT32                  LogicalLineNumber,
     UINT32                  LogicalByteOffset,
@@ -396,7 +401,7 @@ AslCommonError (
 void
 AslCommonError2 (
     UINT8                   Level,
-    UINT8                   MessageId,
+    UINT16                  MessageId,
     UINT32                  LineNumber,
     UINT32                  Column,
     char                    *SourceLine,
@@ -511,6 +516,22 @@ OpcAmlConstantWalk (
 
 
 /*
+ * aslmessages - exception strings
+ */
+const char *
+AeDecodeMessageId (
+    UINT16                  MessageId);
+
+const char *
+AeDecodeExceptionLevel (
+    UINT8                   Level);
+
+UINT16
+AeBuildFullExceptionCode (
+    UINT8                   Level,
+    UINT16                  MessageId);
+
+/*
  * asloffset - generate C offset file for BIOS support
  */
 ACPI_STATUS
diff --git a/src/acpica/source/compiler/aslerror.c b/src/acpica/source/compiler/aslerror.c
index e096894..c2de70a 100644
--- a/src/acpica/source/compiler/aslerror.c
+++ b/src/acpica/source/compiler/aslerror.c
@@ -113,7 +113,6 @@
  *
  *****************************************************************************/
 
-#define ASL_EXCEPTIONS
 #include "aslcompiler.h"
 
 #define _COMPONENT          ACPI_COMPILER
@@ -276,7 +275,7 @@ AePrintException (
     int                     Actual;
     size_t                  RActual;
     UINT32                  MsgLength;
-    char                    *MainMessage;
+    const char              *MainMessage;
     char                    *ExtraMessage;
     UINT32                  SourceColumn;
     UINT32                  ErrorColumn;
@@ -471,109 +470,93 @@ AePrintException (
         }
     }
 
-    /* NULL message ID, just print the raw message */
+    /* If a NULL message ID, just print the raw message */
 
     if (Enode->MessageId == 0)
     {
         fprintf (OutputFile, "%s\n", Enode->Message);
+        return;
     }
-    else
-    {
-        /* Decode the message ID */
 
-        if (Gbl_VerboseErrors)
-        {
-            fprintf (OutputFile, "%s %4.4d -",
-                        AslErrorLevel[Enode->Level],
-                        Enode->MessageId + ((Enode->Level+1) * 1000));
-        }
-        else /* IDE case */
-        {
-            fprintf (OutputFile, "%s %4.4d:",
-                        AslErrorLevelIde[Enode->Level],
-                        Enode->MessageId + ((Enode->Level+1) * 1000));
-        }
+    /* Decode the message ID */
 
-        MainMessage = AslMessages[Enode->MessageId];
-        ExtraMessage = Enode->Message;
+    fprintf (OutputFile, "%s %4.4d -",
+        AeDecodeExceptionLevel (Enode->Level),
+        AeBuildFullExceptionCode (Enode->Level, Enode->MessageId));
 
-        if (Enode->LineNumber)
-        {
-            /* Main message: try to use string from AslMessages first */
+    MainMessage = AeDecodeMessageId (Enode->MessageId);
+    ExtraMessage = Enode->Message;
 
-            if (!MainMessage)
-            {
-                MainMessage = "";
-            }
+    /* If a NULL line number, just print the decoded message */
 
-            MsgLength = strlen (MainMessage);
-            if (MsgLength == 0)
-            {
-                /* Use the secondary/extra message as main message */
+    if (!Enode->LineNumber)
+    {
+        fprintf (OutputFile, " %s %s\n\n", MainMessage, ExtraMessage);
+        return;
+    }
 
-                MainMessage = Enode->Message;
-                if (!MainMessage)
-                {
-                    MainMessage = "";
-                }
+    MsgLength = strlen (MainMessage);
+    if (MsgLength == 0)
+    {
+        /* Use the secondary/extra message as main message */
 
-                MsgLength = strlen (MainMessage);
-                ExtraMessage = NULL;
-            }
+        MainMessage = Enode->Message;
+        if (!MainMessage)
+        {
+            MainMessage = "";
+        }
 
-            if (Gbl_VerboseErrors && !PrematureEOF)
-            {
-                if (Total >= 256)
-                {
-                    fprintf (OutputFile, "    %s",
-                        MainMessage);
-                }
-                else
-                {
-                    SourceColumn = Enode->Column + Enode->FilenameLength + 6 + 2;
-                    ErrorColumn = ASL_ERROR_LEVEL_LENGTH + 5 + 2 + 1;
+        MsgLength = strlen (MainMessage);
+        ExtraMessage = NULL;
+    }
 
-                    if ((MsgLength + ErrorColumn) < (SourceColumn - 1))
-                    {
-                        fprintf (OutputFile, "%*s%s",
-                            (int) ((SourceColumn - 1) - ErrorColumn),
-                            MainMessage, " ^ ");
-                    }
-                    else
-                    {
-                        fprintf (OutputFile, "%*s %s",
-                            (int) ((SourceColumn - ErrorColumn) + 1), "^",
-                            MainMessage);
-                    }
-                }
+    if (Gbl_VerboseErrors && !PrematureEOF)
+    {
+        if (Total >= 256)
+        {
+            fprintf (OutputFile, "    %s",
+                MainMessage);
+        }
+        else
+        {
+            SourceColumn = Enode->Column + Enode->FilenameLength + 6 + 2;
+            ErrorColumn = ASL_ERROR_LEVEL_LENGTH + 5 + 2 + 1;
+
+            if ((MsgLength + ErrorColumn) < (SourceColumn - 1))
+            {
+                fprintf (OutputFile, "%*s%s",
+                    (int) ((SourceColumn - 1) - ErrorColumn),
+                    MainMessage, " ^ ");
             }
             else
             {
-                fprintf (OutputFile, " %s", MainMessage);
+                fprintf (OutputFile, "%*s %s",
+                    (int) ((SourceColumn - ErrorColumn) + 1), "^",
+                    MainMessage);
             }
+        }
+    }
+    else
+    {
+        fprintf (OutputFile, " %s", MainMessage);
+    }
 
-            /* Print the extra info message if present */
+    /* Print the extra info message if present */
 
-            if (ExtraMessage)
-            {
-                fprintf (OutputFile, " (%s)", ExtraMessage);
-            }
+    if (ExtraMessage)
+    {
+        fprintf (OutputFile, " (%s)", ExtraMessage);
+    }
 
-            if (PrematureEOF)
-            {
-                fprintf (OutputFile, " and premature End-Of-File");
-            }
+    if (PrematureEOF)
+    {
+        fprintf (OutputFile, " and premature End-Of-File");
+    }
 
-            fprintf (OutputFile, "\n");
-            if (Gbl_VerboseErrors)
-            {
-                fprintf (OutputFile, "\n");
-            }
-        }
-        else
-        {
-            fprintf (OutputFile, " %s %s\n\n", MainMessage, ExtraMessage);
-        }
+    fprintf (OutputFile, "\n");
+    if (Gbl_VerboseErrors)
+    {
+        fprintf (OutputFile, "\n");
     }
 }
 
@@ -628,7 +611,7 @@ AePrintErrorLog (
 void
 AslCommonError2 (
     UINT8                   Level,
-    UINT8                   MessageId,
+    UINT16                  MessageId,
     UINT32                  LineNumber,
     UINT32                  Column,
     char                    *SourceLine,
@@ -714,7 +697,7 @@ AslCommonError2 (
 void
 AslCommonError (
     UINT8                   Level,
-    UINT8                   MessageId,
+    UINT16                  MessageId,
     UINT32                  CurrentLineNumber,
     UINT32                  LogicalLineNumber,
     UINT32                  LogicalByteOffset,
@@ -848,7 +831,7 @@ AslDisableException (
 BOOLEAN
 AslIsExceptionDisabled (
     UINT8                   Level,
-    UINT8                   MessageId)
+    UINT16                  MessageId)
 {
     UINT32                  EncodedMessageId;
     UINT32                  i;
@@ -873,7 +856,7 @@ AslIsExceptionDisabled (
          * Ignore this warning/remark if it has been disabled by
          * the user (-vw option)
          */
-        EncodedMessageId = MessageId + ((Level + 1) * 1000);
+        EncodedMessageId = AeBuildFullExceptionCode (Level, MessageId);
         for (i = 0; i < Gbl_DisabledMessagesIndex; i++)
         {
             /* Simple implementation via fixed array */
@@ -912,7 +895,7 @@ AslIsExceptionDisabled (
 void
 AslError (
     UINT8                   Level,
-    UINT8                   MessageId,
+    UINT16                  MessageId,
     ACPI_PARSE_OBJECT       *Op,
     char                    *ExtraMessage)
 {
diff --git a/src/acpica/source/compiler/aslmessages.c b/src/acpica/source/compiler/aslmessages.c
new file mode 100755
index 0000000..11b5d57
--- /dev/null
+++ b/src/acpica/source/compiler/aslmessages.c
@@ -0,0 +1,479 @@
+/******************************************************************************
+ *
+ * Module Name: aslmessages.c - Compiler error/warning message strings
+ *
+ *****************************************************************************/
+
+/******************************************************************************
+ *
+ * 1. Copyright Notice
+ *
+ * Some or all of this work - Copyright (c) 1999 - 2014, Intel Corp.
+ * All rights reserved.
+ *
+ * 2. License
+ *
+ * 2.1. This is your license from Intel Corp. under its intellectual property
+ * rights. You may have additional license terms from the party that provided
+ * you this software, covering your right to use that party's intellectual
+ * property rights.
+ *
+ * 2.2. Intel grants, free of charge, to any person ("Licensee") obtaining a
+ * copy of the source code appearing in this file ("Covered Code") an
+ * irrevocable, perpetual, worldwide license under Intel's copyrights in the
+ * base code distributed originally by Intel ("Original Intel Code") to copy,
+ * make derivatives, distribute, use and display any portion of the Covered
+ * Code in any form, with the right to sublicense such rights; and
+ *
+ * 2.3. Intel grants Licensee a non-exclusive and non-transferable patent
+ * license (with the right to sublicense), under only those claims of Intel
+ * patents that are infringed by the Original Intel Code, to make, use, sell,
+ * offer to sell, and import the Covered Code and derivative works thereof
+ * solely to the minimum extent necessary to exercise the above copyright
+ * license, and in no event shall the patent license extend to any additions
+ * to or modifications of the Original Intel Code. No other license or right
+ * is granted directly or by implication, estoppel or otherwise;
+ *
+ * The above copyright and patent license is granted only if the following
+ * conditions are met:
+ *
+ * 3. Conditions
+ *
+ * 3.1. Redistribution of Source with Rights to Further Distribute Source.
+ * Redistribution of source code of any substantial portion of the Covered
+ * Code or modification with rights to further distribute source must include
+ * the above Copyright Notice, the above License, this list of Conditions,
+ * and the following Disclaimer and Export Compliance provision. In addition,
+ * Licensee must cause all Covered Code to which Licensee contributes to
+ * contain a file documenting the changes Licensee made to create that Covered
+ * Code and the date of any change. Licensee must include in that file the
+ * documentation of any changes made by any predecessor Licensee. Licensee
+ * must include a prominent statement that the modification is derived,
+ * directly or indirectly, from Original Intel Code.
+ *
+ * 3.2. Redistribution of Source with no Rights to Further Distribute Source.
+ * Redistribution of source code of any substantial portion of the Covered
+ * Code or modification without rights to further distribute source must
+ * include the following Disclaimer and Export Compliance provision in the
+ * documentation and/or other materials provided with distribution. In
+ * addition, Licensee may not authorize further sublicense of source of any
+ * portion of the Covered Code, and must include terms to the effect that the
+ * license from Licensee to its licensee is limited to the intellectual
+ * property embodied in the software Licensee provides to its licensee, and
+ * not to intellectual property embodied in modifications its licensee may
+ * make.
+ *
+ * 3.3. Redistribution of Executable. Redistribution in executable form of any
+ * substantial portion of the Covered Code or modification must reproduce the
+ * above Copyright Notice, and the following Disclaimer and Export Compliance
+ * provision in the documentation and/or other materials provided with the
+ * distribution.
+ *
+ * 3.4. Intel retains all right, title, and interest in and to the Original
+ * Intel Code.
+ *
+ * 3.5. Neither the name Intel nor any other trademark owned or controlled by
+ * Intel shall be used in advertising or otherwise to promote the sale, use or
+ * other dealings in products derived from or relating to the Covered Code
+ * without prior written authorization from Intel.
+ *
+ * 4. Disclaimer and Export Compliance
+ *
+ * 4.1. INTEL MAKES NO WARRANTY OF ANY KIND REGARDING ANY SOFTWARE PROVIDED
+ * HERE. ANY SOFTWARE ORIGINATING FROM INTEL OR DERIVED FROM INTEL SOFTWARE
+ * IS PROVIDED "AS IS," AND INTEL WILL NOT PROVIDE ANY SUPPORT, ASSISTANCE,
+ * INSTALLATION, TRAINING OR OTHER SERVICES. INTEL WILL NOT PROVIDE ANY
+ * UPDATES, ENHANCEMENTS OR EXTENSIONS. INTEL SPECIFICALLY DISCLAIMS ANY
+ * IMPLIED WARRANTIES OF MERCHANTABILITY, NONINFRINGEMENT AND FITNESS FOR A
+ * PARTICULAR PURPOSE.
+ *
+ * 4.2. IN NO EVENT SHALL INTEL HAVE ANY LIABILITY TO LICENSEE, ITS LICENSEES
+ * OR ANY OTHER THIRD PARTY, FOR ANY LOST PROFITS, LOST DATA, LOSS OF USE OR
+ * COSTS OF PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES, OR FOR ANY INDIRECT,
+ * SPECIAL OR CONSEQUENTIAL DAMAGES ARISING OUT OF THIS AGREEMENT, UNDER ANY
+ * CAUSE OF ACTION OR THEORY OF LIABILITY, AND IRRESPECTIVE OF WHETHER INTEL
+ * HAS ADVANCE NOTICE OF THE POSSIBILITY OF SUCH DAMAGES. THESE LIMITATIONS
+ * SHALL APPLY NOTWITHSTANDING THE FAILURE OF THE ESSENTIAL PURPOSE OF ANY
+ * LIMITED REMEDY.
+ *
+ * 4.3. Licensee shall not export, either directly or indirectly, any of this
+ * software or system incorporating such software without first obtaining any
+ * required license or other approval from the U. S. Department of Commerce or
+ * any other agency or department of the United States Government. In the
+ * event Licensee exports any such software from the United States or
+ * re-exports any such software from a foreign destination, Licensee shall
+ * ensure that the distribution and export/re-export of the software is in
+ * compliance with all laws, regulations, orders, or other restrictions of the
+ * U.S. Export Administration Regulations. Licensee agrees that neither it nor
+ * any of its subsidiaries will export/re-export any technical data, process,
+ * software, or service, directly or indirectly, to any country for which the
+ * United States government or any agency thereof requires an export license,
+ * other governmental approval, or letter of assurance, without first obtaining
+ * such license, approval or letter.
+ *
+ *****************************************************************************/
+
+#include "aslcompiler.h"
+
+#define _COMPONENT          ACPI_COMPILER
+        ACPI_MODULE_NAME    ("aslmessages")
+
+
+/*
+ * Strings for message reporting levels, must match error
+ * type string tables in aslmessages.c
+ */
+const char              *AslErrorLevel [ASL_NUM_REPORT_LEVELS] = {
+    "Optimize",
+    "Remark  ",
+    "Warning ",
+    "Warning ",
+    "Warning ",
+    "Error   "
+};
+
+/* All lowercase versions for IDEs */
+
+const char              *AslErrorLevelIde [ASL_NUM_REPORT_LEVELS] = {
+    "optimize",
+    "remark  ",
+    "warning ",
+    "warning ",
+    "warning ",
+    "error   "
+};
+
+
+/*
+ * Actual message strings for each compiler message ID. There are currently
+ * three distinct blocks of error messages (so that they can be expanded
+ * individually):
+ *      Main ASL compiler
+ *      Data Table compiler
+ *      Preprocessor
+ *
+ * NOTE1: These tables must match the enum list of message IDs in the file
+ * aslmessages.h exactly.
+ *
+ * NOTE2: With the introduction of the -vw option to disable specific messages,
+ * new messages should only be added to the end of this list, so that values
+ * for existing messages are not disturbed.
+ */
+
+/* ASL compiler */
+
+const char                      *AslCompilerMsgs [] =
+{
+/*    The zeroth message is reserved */    "",
+/*    ASL_MSG_ALIGNMENT */                  "Must be a multiple of alignment/granularity value",
+/*    ASL_MSG_ALPHANUMERIC_STRING */        "String must be entirely alphanumeric",
+/*    ASL_MSG_AML_NOT_IMPLEMENTED */        "Opcode is not implemented in compiler AML code generator",
+/*    ASL_MSG_ARG_COUNT_HI */               "Too many arguments",
+/*    ASL_MSG_ARG_COUNT_LO */               "Too few arguments",
+/*    ASL_MSG_ARG_INIT */                   "Method argument is not initialized",
+/*    ASL_MSG_BACKWARDS_OFFSET */           "Invalid backwards offset",
+/*    ASL_MSG_BUFFER_LENGTH */              "Effective AML buffer length is zero",
+/*    ASL_MSG_CLOSE */                      "Could not close file",
+/*    ASL_MSG_COMPILER_INTERNAL */          "Internal compiler error",
+/*    ASL_MSG_COMPILER_RESERVED */          "Use of compiler reserved name",
+/*    ASL_MSG_CONNECTION_MISSING */         "A Connection operator is required for this field SpaceId",
+/*    ASL_MSG_CONNECTION_INVALID */         "Invalid OpRegion SpaceId for use of Connection operator",
+/*    ASL_MSG_CONSTANT_EVALUATION */        "Could not evaluate constant expression",
+/*    ASL_MSG_CONSTANT_FOLDED */            "Constant expression evaluated and reduced",
+/*    ASL_MSG_CORE_EXCEPTION */             "From ACPICA Subsystem",
+/*    ASL_MSG_DEBUG_FILE_OPEN */            "Could not open debug file",
+/*    ASL_MSG_DEBUG_FILENAME */             "Could not create debug filename",
+/*    ASL_MSG_DEPENDENT_NESTING */          "Dependent function macros cannot be nested",
+/*    ASL_MSG_DMA_CHANNEL */                "Invalid DMA channel (must be 0-7)",
+/*    ASL_MSG_DMA_LIST */                   "Too many DMA channels (8 max)",
+/*    ASL_MSG_DUPLICATE_CASE */             "Case value already specified",
+/*    ASL_MSG_DUPLICATE_ITEM */             "Duplicate value in list",
+/*    ASL_MSG_EARLY_EOF */                  "Premature end-of-file reached",
+/*    ASL_MSG_ENCODING_LENGTH */            "Package length too long to encode",
+/*    ASL_MSG_EX_INTERRUPT_LIST */          "Too many interrupts (255 max)",
+/*    ASL_MSG_EX_INTERRUPT_LIST_MIN */      "Too few interrupts (1 minimum required)",
+/*    ASL_MSG_EX_INTERRUPT_NUMBER */        "Invalid interrupt number (must be 32 bits)",
+/*    ASL_MSG_FIELD_ACCESS_WIDTH */         "Access width is greater than region size",
+/*    ASL_MSG_FIELD_UNIT_ACCESS_WIDTH */    "Access width of Field Unit extends beyond region limit",
+/*    ASL_MSG_FIELD_UNIT_OFFSET */          "Field Unit extends beyond region limit",
+/*    ASL_MSG_GPE_NAME_CONFLICT */          "Name conflicts with a previous GPE method",
+/*    ASL_MSG_HID_LENGTH */                 "_HID string must be exactly 7 or 8 characters",
+/*    ASL_MSG_HID_PREFIX */                 "_HID prefix must be all uppercase or decimal digits",
+/*    ASL_MSG_HID_SUFFIX */                 "_HID suffix must be all hex digits",
+/*    ASL_MSG_INCLUDE_FILE_OPEN */          "Could not open include file",
+/*    ASL_MSG_INPUT_FILE_OPEN */            "Could not open input file",
+/*    ASL_MSG_INTEGER_LENGTH */             "64-bit integer in 32-bit table, truncating (DSDT version < 2)",
+/*    ASL_MSG_INTEGER_OPTIMIZATION */       "Integer optimized to single-byte AML opcode",
+/*    ASL_MSG_INTERRUPT_LIST */             "Too many interrupts (16 max)",
+/*    ASL_MSG_INTERRUPT_NUMBER */           "Invalid interrupt number (must be 0-15)",
+/*    ASL_MSG_INVALID_ACCESS_SIZE */        "Invalid AccessSize (Maximum is 4 - QWord access)",
+/*    ASL_MSG_INVALID_ADDR_FLAGS */         "Invalid combination of Length and Min/Max fixed flags",
+/*    ASL_MSG_INVALID_CONSTANT_OP */        "Invalid operator in constant expression (not type 3/4/5)",
+/*    ASL_MSG_INVALID_EISAID */             "EISAID string must be of the form \"UUUXXXX\" (3 uppercase, 4 hex digits)",
+/*    ASL_MSG_INVALID_ESCAPE */             "Invalid or unknown escape sequence",
+/*    ASL_MSG_INVALID_GRAN_FIXED */         "Granularity must be zero for fixed Min/Max",
+/*    ASL_MSG_INVALID_GRANULARITY */        "Granularity must be zero or a power of two minus one",
+/*    ASL_MSG_INVALID_LENGTH */             "Length is larger than Min/Max window",
+/*    ASL_MSG_INVALID_LENGTH_FIXED */       "Length is not equal to fixed Min/Max window",
+/*    ASL_MSG_INVALID_MIN_MAX */            "Address Min is greater than Address Max",
+/*    ASL_MSG_INVALID_OPERAND */            "Invalid operand",
+/*    ASL_MSG_INVALID_PERFORMANCE */        "Invalid performance/robustness value",
+/*    ASL_MSG_INVALID_PRIORITY */           "Invalid priority value",
+/*    ASL_MSG_INVALID_STRING */             "Invalid Hex/Octal Escape - Non-ASCII or NULL",
+/*    ASL_MSG_INVALID_TARGET */             "Target operand not allowed in constant expression",
+/*    ASL_MSG_INVALID_TIME */               "Time parameter too long (255 max)",
+/*    ASL_MSG_INVALID_TYPE */               "Invalid type",
+/*    ASL_MSG_INVALID_UUID */               "UUID string must be of the form \"aabbccdd-eeff-gghh-iijj-kkllmmnnoopp\"",
+/*    ASL_MSG_ISA_ADDRESS */                "Maximum 10-bit ISA address (0x3FF)",
+/*    ASL_MSG_LEADING_ASTERISK */           "Invalid leading asterisk",
+/*    ASL_MSG_LIST_LENGTH_LONG */           "Initializer list longer than declared package length",
+/*    ASL_MSG_LIST_LENGTH_SHORT */          "Initializer list shorter than declared package length",
+/*    ASL_MSG_LISTING_FILE_OPEN */          "Could not open listing file",
+/*    ASL_MSG_LISTING_FILENAME */           "Could not create listing filename",
+/*    ASL_MSG_LOCAL_INIT */                 "Method local variable is not initialized",
+/*    ASL_MSG_LOCAL_OUTSIDE_METHOD */       "Local or Arg used outside a control method",
+/*    ASL_MSG_LONG_LINE */                  "Splitting long input line",
+/*    ASL_MSG_MEMORY_ALLOCATION */          "Memory allocation failure",
+/*    ASL_MSG_MISSING_ENDDEPENDENT */       "Missing EndDependentFn() macro in dependent resource list",
+/*    ASL_MSG_MISSING_STARTDEPENDENT */     "Missing StartDependentFn() macro in dependent resource list",
+/*    ASL_MSG_MULTIPLE_DEFAULT */           "More than one Default statement within Switch construct",
+/*    ASL_MSG_MULTIPLE_TYPES */             "Multiple types",
+/*    ASL_MSG_NAME_EXISTS */                "Name already exists in scope",
+/*    ASL_MSG_NAME_OPTIMIZATION */          "NamePath optimized",
+/*    ASL_MSG_NAMED_OBJECT_IN_WHILE */      "Creating a named object in a While loop",
+/*    ASL_MSG_NESTED_COMMENT */             "Nested comment found",
+/*    ASL_MSG_NO_CASES */                   "No Case statements under Switch",
+/*    ASL_MSG_NO_REGION */                  "_REG has no corresponding Operation Region",
+/*    ASL_MSG_NO_RETVAL */                  "Called method returns no value",
+/*    ASL_MSG_NO_WHILE */                   "No enclosing While statement",
+/*    ASL_MSG_NON_ASCII */                  "Invalid characters found in file",
+/*    ASL_MSG_NON_ZERO */                   "Operand evaluates to zero",
+/*    ASL_MSG_NOT_EXIST */                  "Object does not exist",
+/*    ASL_MSG_NOT_FOUND */                  "Object not found or not accessible from scope",
+/*    ASL_MSG_NOT_METHOD */                 "Not a control method, cannot invoke",
+/*    ASL_MSG_NOT_PARAMETER */              "Not a parameter, used as local only",
+/*    ASL_MSG_NOT_REACHABLE */              "Object is not accessible from this scope",
+/*    ASL_MSG_NOT_REFERENCED */             "Object is not referenced",
+/*    ASL_MSG_NULL_DESCRIPTOR */            "Min/Max/Length/Gran are all zero, but no resource tag",
+/*    ASL_MSG_NULL_STRING */                "Invalid zero-length (null) string",
+/*    ASL_MSG_OPEN */                       "Could not open file",
+/*    ASL_MSG_OUTPUT_FILE_OPEN */           "Could not open output AML file",
+/*    ASL_MSG_OUTPUT_FILENAME */            "Could not create output filename",
+/*    ASL_MSG_PACKAGE_LENGTH */             "Effective AML package length is zero",
+/*    ASL_MSG_PREPROCESSOR_FILENAME */      "Could not create preprocessor filename",
+/*    ASL_MSG_READ */                       "Could not read file",
+/*    ASL_MSG_RECURSION */                  "Recursive method call",
+/*    ASL_MSG_REGION_BUFFER_ACCESS */       "Host Operation Region requires BufferAcc access",
+/*    ASL_MSG_REGION_BYTE_ACCESS */         "Host Operation Region requires ByteAcc access",
+/*    ASL_MSG_RESERVED_ARG_COUNT_HI */      "Reserved method has too many arguments",
+/*    ASL_MSG_RESERVED_ARG_COUNT_LO */      "Reserved method has too few arguments",
+/*    ASL_MSG_RESERVED_METHOD */            "Reserved name must be a control method",
+/*    ASL_MSG_RESERVED_NO_RETURN_VAL */     "Reserved method should not return a value",
+/*    ASL_MSG_RESERVED_OPERAND_TYPE */      "Invalid object type for reserved name",
+/*    ASL_MSG_RESERVED_PACKAGE_LENGTH */    "Invalid package length for reserved name",
+/*    ASL_MSG_RESERVED_RETURN_VALUE */      "Reserved method must return a value",
+/*    ASL_MSG_RESERVED_USE */               "Invalid use of reserved name",
+/*    ASL_MSG_RESERVED_WORD */              "Use of reserved name",
+/*    ASL_MSG_RESOURCE_FIELD */             "Resource field name cannot be used as a target",
+/*    ASL_MSG_RESOURCE_INDEX */             "Missing ResourceSourceIndex (required)",
+/*    ASL_MSG_RESOURCE_LIST */              "Too many resource items (internal error)",
+/*    ASL_MSG_RESOURCE_SOURCE */            "Missing ResourceSource string (required)",
+/*    ASL_MSG_RESULT_NOT_USED */            "Result is not used, operator has no effect",
+/*    ASL_MSG_RETURN_TYPES */               "Not all control paths return a value",
+/*    ASL_MSG_SCOPE_FWD_REF */              "Forward references from Scope operator not allowed",
+/*    ASL_MSG_SCOPE_TYPE */                 "Existing object has invalid type for Scope operator",
+/*    ASL_MSG_SEEK */                       "Could not seek file",
+/*    ASL_MSG_SERIALIZED */                 "Control Method marked Serialized",
+/*    ASL_MSG_SERIALIZED_REQUIRED */        "Control Method should be made Serialized",
+/*    ASL_MSG_SINGLE_NAME_OPTIMIZATION */   "NamePath optimized to NameSeg (uses run-time search path)",
+/*    ASL_MSG_SOME_NO_RETVAL */             "Called method may not always return a value",
+/*    ASL_MSG_STRING_LENGTH */              "String literal too long",
+/*    ASL_MSG_SWITCH_TYPE */                "Switch expression is not a static Integer/Buffer/String data type, defaulting to Integer",
+/*    ASL_MSG_SYNC_LEVEL */                 "SyncLevel must be in the range 0-15",
+/*    ASL_MSG_SYNTAX */                     "",
+/*    ASL_MSG_TABLE_SIGNATURE */            "Invalid Table Signature",
+/*    ASL_MSG_TAG_LARGER */                 "ResourceTag larger than Field",
+/*    ASL_MSG_TAG_SMALLER */                "ResourceTag smaller than Field",
+/*    ASL_MSG_TIMEOUT */                    "Result is not used, possible operator timeout will be missed",
+/*    ASL_MSG_TOO_MANY_TEMPS */             "Method requires too many temporary variables (_T_x)",
+/*    ASL_MSG_TRUNCATION */                 "64-bit return value will be truncated to 32 bits (DSDT version < 2)",
+/*    ASL_MSG_UNKNOWN_RESERVED_NAME */      "Unknown reserved name",
+/*    ASL_MSG_UNREACHABLE_CODE */           "Statement is unreachable",
+/*    ASL_MSG_UNSUPPORTED */                "Unsupported feature",
+/*    ASL_MSG_UPPER_CASE */                 "Non-hex letters must be upper case",
+/*    ASL_MSG_VENDOR_LIST */                "Too many vendor data bytes (7 max)",
+/*    ASL_MSG_WRITE */                      "Could not write file",
+/*    ASL_MSG_RANGE */                      "Constant out of range",
+/*    ASL_MSG_BUFFER_ALLOCATION */          "Could not allocate line buffer",
+/*    ASL_MSG_MISSING_DEPENDENCY */         "Missing dependency"
+};
+
+/* Table compiler */
+
+const char                      *AslTableCompilerMsgs [] =
+{
+/*    ASL_MSG_BUFFER_ELEMENT */             "Invalid element in buffer initializer list",
+/*    ASL_MSG_DIVIDE_BY_ZERO */             "Expression contains divide-by-zero",
+/*    ASL_MSG_FLAG_VALUE */                 "Flag value is too large",
+/*    ASL_MSG_INTEGER_SIZE */               "Integer too large for target",
+/*    ASL_MSG_INVALID_EXPRESSION */         "Invalid expression",
+/*    ASL_MSG_INVALID_FIELD_NAME */         "Invalid Field Name",
+/*    ASL_MSG_INVALID_HEX_INTEGER */        "Invalid hex integer constant",
+/*    ASL_MSG_OEM_TABLE */                  "OEM table - unknown contents",
+/*    ASL_MSG_RESERVED_VALUE */             "Reserved field",
+/*    ASL_MSG_UNKNOWN_LABEL */              "Label is undefined",
+/*    ASL_MSG_UNKNOWN_SUBTABLE */           "Unknown subtable type",
+/*    ASL_MSG_UNKNOWN_TABLE */              "Unknown ACPI table signature",
+/*    ASL_MSG_ZERO_VALUE */                 "Value must be non-zero"
+};
+
+/* Preprocessor */
+
+const char                      *AslPreprocessorMsgs [] =
+{
+/*    ASL_MSG_DIRECTIVE_SYNTAX */           "Invalid directive syntax",
+/*    ASL_MSG_ENDIF_MISMATCH */             "Mismatched #endif",
+/*    ASL_MSG_ERROR_DIRECTIVE */            "#error",
+/*    ASL_MSG_EXISTING_NAME */              "Name is already defined",
+/*    ASL_MSG_INVALID_INVOCATION */         "Invalid macro invocation",
+/*    ASL_MSG_MACRO_SYNTAX */               "Invalid macro syntax",
+/*    ASL_MSG_TOO_MANY_ARGUMENTS */         "Too many macro arguments",
+/*    ASL_MSG_UNKNOWN_DIRECTIVE */          "Unknown directive",
+/*    ASL_MSG_UNKNOWN_PRAGMA */             "Unknown pragma",
+/*    ASL_MSG_WARNING_DIRECTIVE */          "#warning"
+};
+
+
+/*******************************************************************************
+ *
+ * FUNCTION:    AeDecodeMessageId
+ *
+ * PARAMETERS:  MessageId               - ASL message ID (exception code) to be
+ *                                        formatted. Possibly fully encoded.
+ *
+ * RETURN:      A string containing the exception message text.
+ *
+ * DESCRIPTION: This function validates and translates an ASL message ID into
+ *              an ASCII string.
+ *
+ ******************************************************************************/
+
+const char *
+AeDecodeMessageId (
+    UINT16                  MessageId)
+{
+    UINT32                  Index;
+    const char              **MessageTable;
+
+
+    /* Main ASL Compiler messages */
+
+    if (MessageId <= ASL_MSG_MAIN_COMPILER_END)
+    {
+        MessageTable = AslCompilerMsgs;
+        Index = MessageId;
+
+        if (Index >= ACPI_ARRAY_LENGTH (AslCompilerMsgs))
+        {
+            return ("[Unknown ASL Compiler exception ID]");
+        }
+    }
+
+    /* Data Table Compiler messages */
+
+    else if (MessageId <= ASL_MSG_TABLE_COMPILER_END)
+    {
+        MessageTable = AslTableCompilerMsgs;
+        Index = MessageId - ASL_MSG_TABLE_COMPILER;
+
+        if (Index >= ACPI_ARRAY_LENGTH (AslTableCompilerMsgs))
+        {
+            return ("[Unknown Table Compiler exception ID]");
+        }
+    }
+
+    /* Preprocessor messages */
+
+    else if (MessageId <= ASL_MSG_PREPROCESSOR_END)
+    {
+        MessageTable = AslPreprocessorMsgs;
+        Index = MessageId - ASL_MSG_PREPROCESSOR;
+
+        if (Index >= ACPI_ARRAY_LENGTH (AslPreprocessorMsgs))
+        {
+            return ("[Unknown Preprocesor exception ID]");
+        }
+    }
+
+    /* Everything else is unknown */
+
+    else
+    {
+        return ("[Unknown exception/component ID]");
+    }
+
+    return (MessageTable[Index]);
+}
+
+
+/*******************************************************************************
+ *
+ * FUNCTION:    AeDecodeExceptionLevel
+ *
+ * PARAMETERS:  Level               - The ASL error level to be decoded
+ *
+ * RETURN:      A string containing the error level text
+ *
+ * DESCRIPTION: This function validates and translates an ASL error level into
+ *              an ASCII string.
+ *
+ ******************************************************************************/
+
+const char *
+AeDecodeExceptionLevel (
+    UINT8                   Level)
+{
+    /* Range check on Level */
+
+    if (Level >= ACPI_ARRAY_LENGTH (AslErrorLevel))
+    {
+        return ("Unknown exception level");
+    }
+
+    /* Differentiate the string type to be used (IDE is all lower case) */
+
+    if (Gbl_VerboseErrors)
+    {
+        return (AslErrorLevel[Level]);
+    }
+
+    return (AslErrorLevelIde[Level]);
+}
+
+
+/*******************************************************************************
+ *
+ * FUNCTION:    AeBuildFullExceptionCode
+ *
+ * PARAMETERS:  Level               - ASL error level
+ *              MessageId           - ASL exception code to be formatted
+ *
+ * RETURN:      Fully encoded exception code
+ *
+ * DESCRIPTION: Build the full exception code from the error level and the
+ *              actual message ID.
+ *
+ ******************************************************************************/
+
+UINT16
+AeBuildFullExceptionCode (
+    UINT8                   Level,
+    UINT16                  MessageId)
+{
+
+    /*
+     * Error level is in the thousands slot (error/warning/remark, etc.)
+     * Error codes are 0 - 999
+     */
+    return (((Level + 1) * 1000) + MessageId);
+}
diff --git a/src/acpica/source/compiler/aslmessages.h b/src/acpica/source/compiler/aslmessages.h
index c544eac..5743075 100644
--- a/src/acpica/source/compiler/aslmessages.h
+++ b/src/acpica/source/compiler/aslmessages.h
@@ -113,11 +113,12 @@
  *
  *****************************************************************************/
 
-
 #ifndef __ASLMESSAGES_H
 #define __ASLMESSAGES_H
 
 
+/* These values must match error type string tables in aslmessages.c */
+
 typedef enum
 {
     ASL_OPTIMIZATION = 0,
@@ -130,43 +131,41 @@ typedef enum
 
 } ASL_MESSAGE_TYPES;
 
-#ifdef ASL_EXCEPTIONS
 
-/* Strings for message reporting levels, must match values above */
+#define ASL_ERROR_LEVEL_LENGTH          8 /* Length of strings for types above */
 
-const char              *AslErrorLevel [ASL_NUM_REPORT_LEVELS] = {
-    "Optimize",
-    "Remark  ",
-    "Warning ",
-    "Warning ",
-    "Warning ",
-    "Error   "
-};
+/*
+ * Exception code blocks, 0 - 999
+ * Available for new exception blocks: 600 - 999
+ */
+#define ASL_MSG_MAIN_COMPILER           0       /* 0 - 299 */
+#define ASL_MSG_MAIN_COMPILER_END       299
 
-/* All lowercase versions for IDEs */
+#define ASL_MSG_TABLE_COMPILER          300     /* 300 - 499 */
+#define ASL_MSG_TABLE_COMPILER_END      499
 
-const char              *AslErrorLevelIde [ASL_NUM_REPORT_LEVELS] = {
-    "optimize",
-    "remark  ",
-    "warning ",
-    "warning ",
-    "warning ",
-    "error   "
-};
+#define ASL_MSG_PREPROCESSOR            500     /* 500 - 599 */
+#define ASL_MSG_PREPROCESSOR_END        599
 
-#define ASL_ERROR_LEVEL_LENGTH          8       /* Length of strings above */
-#endif
 
 /*
- * Values for all compiler messages.
+ * Values (message IDs) for all compiler messages. There are currently
+ * three distinct blocks of error messages (so that they can be expanded
+ * individually):
+ *      Main ASL compiler
+ *      Data Table compiler
+ *      Preprocessor
+ *
+ * NOTE1: This list must match the tables of message strings in the file
+ * aslmessages.c exactly.
  *
- * NOTE: With the introduction of the -vw option to disable specific messages,
- * new messages should only be added to the end of this list, so that values
- * for existing messages are not disturbed.
+ * NOTE2: With the introduction of the -vw option to disable specific
+ * messages, new messages should only be added to the end of these
+ * lists, so that values for existing messages are not disturbed.
  */
 typedef enum
 {
-    ASL_MSG_RESERVED = 0,
+    ASL_MSG_RESERVED = ASL_MSG_MAIN_COMPILER,
 
     ASL_MSG_ALIGNMENT,
     ASL_MSG_ALPHANUMERIC_STRING,
@@ -308,23 +307,11 @@ typedef enum
     ASL_MSG_WRITE,
     ASL_MSG_RANGE,
     ASL_MSG_BUFFER_ALLOCATION,
+    ASL_MSG_MISSING_DEPENDENCY,
 
-    /* These messages are used by the Preprocessor only */
+    /* These messages are used by the Data Table compiler only */
 
-    ASL_MSG_DIRECTIVE_SYNTAX,
-    ASL_MSG_ENDIF_MISMATCH,
-    ASL_MSG_ERROR_DIRECTIVE,
-    ASL_MSG_EXISTING_NAME,
-    ASL_MSG_INVALID_INVOCATION,
-    ASL_MSG_MACRO_SYNTAX,
-    ASL_MSG_TOO_MANY_ARGUMENTS,
-    ASL_MSG_UNKNOWN_DIRECTIVE,
-    ASL_MSG_UNKNOWN_PRAGMA,
-    ASL_MSG_WARNING_DIRECTIVE,
-
-    /* These messages are used by the data table compiler only */
-
-    ASL_MSG_BUFFER_ELEMENT,
+    ASL_MSG_BUFFER_ELEMENT = ASL_MSG_TABLE_COMPILER,
     ASL_MSG_DIVIDE_BY_ZERO,
     ASL_MSG_FLAG_VALUE,
     ASL_MSG_INTEGER_SIZE,
@@ -336,194 +323,22 @@ typedef enum
     ASL_MSG_UNKNOWN_LABEL,
     ASL_MSG_UNKNOWN_SUBTABLE,
     ASL_MSG_UNKNOWN_TABLE,
-    ASL_MSG_ZERO_VALUE
-
-} ASL_MESSAGE_IDS;
+    ASL_MSG_ZERO_VALUE,
 
+    /* These messages are used by the Preprocessor only */
 
-#ifdef ASL_EXCEPTIONS
-
-/*
- * Actual message strings for each compiler message.
- *
- * NOTE: With the introduction of the -vw option to disable specific messages,
- * new messages should only be added to the end of this list, so that values
- * for existing messages are not disturbed.
- */
-char                        *AslMessages [] =
-{
-/*    The zeroth message is reserved */    "",
-/*    ASL_MSG_ALIGNMENT */                  "Must be a multiple of alignment/granularity value",
-/*    ASL_MSG_ALPHANUMERIC_STRING */        "String must be entirely alphanumeric",
-/*    ASL_MSG_AML_NOT_IMPLEMENTED */        "Opcode is not implemented in compiler AML code generator",
-/*    ASL_MSG_ARG_COUNT_HI */               "Too many arguments",
-/*    ASL_MSG_ARG_COUNT_LO */               "Too few arguments",
-/*    ASL_MSG_ARG_INIT */                   "Method argument is not initialized",
-/*    ASL_MSG_BACKWARDS_OFFSET */           "Invalid backwards offset",
-/*    ASL_MSG_BUFFER_LENGTH */              "Effective AML buffer length is zero",
-/*    ASL_MSG_CLOSE */                      "Could not close file",
-/*    ASL_MSG_COMPILER_INTERNAL */          "Internal compiler error",
-/*    ASL_MSG_COMPILER_RESERVED */          "Use of compiler reserved name",
-/*    ASL_MSG_CONNECTION_MISSING */         "A Connection operator is required for this field SpaceId",
-/*    ASL_MSG_CONNECTION_INVALID */         "Invalid OpRegion SpaceId for use of Connection operator",
-/*    ASL_MSG_CONSTANT_EVALUATION */        "Could not evaluate constant expression",
-/*    ASL_MSG_CONSTANT_FOLDED */            "Constant expression evaluated and reduced",
-/*    ASL_MSG_CORE_EXCEPTION */             "From ACPICA Subsystem",
-/*    ASL_MSG_DEBUG_FILE_OPEN */            "Could not open debug file",
-/*    ASL_MSG_DEBUG_FILENAME */             "Could not create debug filename",
-/*    ASL_MSG_DEPENDENT_NESTING */          "Dependent function macros cannot be nested",\
-/*    ASL_MSG_DMA_CHANNEL */                "Invalid DMA channel (must be 0-7)",
-/*    ASL_MSG_DMA_LIST */                   "Too many DMA channels (8 max)",
-/*    ASL_MSG_DUPLICATE_CASE */             "Case value already specified",
-/*    ASL_MSG_DUPLICATE_ITEM */             "Duplicate value in list",
-/*    ASL_MSG_EARLY_EOF */                  "Premature end-of-file reached",
-/*    ASL_MSG_ENCODING_LENGTH */            "Package length too long to encode",
-/*    ASL_MSG_EX_INTERRUPT_LIST */          "Too many interrupts (255 max)",
-/*    ASL_MSG_EX_INTERRUPT_LIST_MIN */      "Too few interrupts (1 minimum required)",
-/*    ASL_MSG_EX_INTERRUPT_NUMBER */        "Invalid interrupt number (must be 32 bits)",
-/*    ASL_MSG_FIELD_ACCESS_WIDTH */         "Access width is greater than region size",
-/*    ASL_MSG_FIELD_UNIT_ACCESS_WIDTH */    "Access width of Field Unit extends beyond region limit",
-/*    ASL_MSG_FIELD_UNIT_OFFSET */          "Field Unit extends beyond region limit",
-/*    ASL_MSG_GPE_NAME_CONFLICT */          "Name conflicts with a previous GPE method",
-/*    ASL_MSG_HID_LENGTH */                 "_HID string must be exactly 7 or 8 characters",
-/*    ASL_MSG_HID_PREFIX */                 "_HID prefix must be all uppercase or decimal digits",
-/*    ASL_MSG_HID_SUFFIX */                 "_HID suffix must be all hex digits",
-/*    ASL_MSG_INCLUDE_FILE_OPEN */          "Could not open include file",
-/*    ASL_MSG_INPUT_FILE_OPEN */            "Could not open input file",
-/*    ASL_MSG_INTEGER_LENGTH */             "64-bit integer in 32-bit table, truncating (DSDT version < 2)",
-/*    ASL_MSG_INTEGER_OPTIMIZATION */       "Integer optimized to single-byte AML opcode",
-/*    ASL_MSG_INTERRUPT_LIST */             "Too many interrupts (16 max)",
-/*    ASL_MSG_INTERRUPT_NUMBER */           "Invalid interrupt number (must be 0-15)",
-/*    ASL_MSG_INVALID_ACCESS_SIZE */        "Invalid AccessSize (Maximum is 4 - QWord access)",
-/*    ASL_MSG_INVALID_ADDR_FLAGS */         "Invalid combination of Length and Min/Max fixed flags",
-/*    ASL_MSG_INVALID_CONSTANT_OP */        "Invalid operator in constant expression (not type 3/4/5)",
-/*    ASL_MSG_INVALID_EISAID */             "EISAID string must be of the form \"UUUXXXX\" (3 uppercase, 4 hex digits)",
-/*    ASL_MSG_INVALID_ESCAPE */             "Invalid or unknown escape sequence",
-/*    ASL_MSG_INVALID_GRAN_FIXED */         "Granularity must be zero for fixed Min/Max",
-/*    ASL_MSG_INVALID_GRANULARITY */        "Granularity must be zero or a power of two minus one",
-/*    ASL_MSG_INVALID_LENGTH */             "Length is larger than Min/Max window",
-/*    ASL_MSG_INVALID_LENGTH_FIXED */       "Length is not equal to fixed Min/Max window",
-/*    ASL_MSG_INVALID_MIN_MAX */            "Address Min is greater than Address Max",
-/*    ASL_MSG_INVALID_OPERAND */            "Invalid operand",
-/*    ASL_MSG_INVALID_PERFORMANCE */        "Invalid performance/robustness value",
-/*    ASL_MSG_INVALID_PRIORITY */           "Invalid priority value",
-/*    ASL_MSG_INVALID_STRING */             "Invalid Hex/Octal Escape - Non-ASCII or NULL",
-/*    ASL_MSG_INVALID_TARGET */             "Target operand not allowed in constant expression",
-/*    ASL_MSG_INVALID_TIME */               "Time parameter too long (255 max)",
-/*    ASL_MSG_INVALID_TYPE */               "Invalid type",
-/*    ASL_MSG_INVALID_UUID */               "UUID string must be of the form \"aabbccdd-eeff-gghh-iijj-kkllmmnnoopp\"",
-/*    ASL_MSG_ISA_ADDRESS */                "Maximum 10-bit ISA address (0x3FF)",
-/*    ASL_MSG_LEADING_ASTERISK */           "Invalid leading asterisk",
-/*    ASL_MSG_LIST_LENGTH_LONG */           "Initializer list longer than declared package length",
-/*    ASL_MSG_LIST_LENGTH_SHORT */          "Initializer list shorter than declared package length",
-/*    ASL_MSG_LISTING_FILE_OPEN */          "Could not open listing file",
-/*    ASL_MSG_LISTING_FILENAME */           "Could not create listing filename",
-/*    ASL_MSG_LOCAL_INIT */                 "Method local variable is not initialized",
-/*    ASL_MSG_LOCAL_OUTSIDE_METHOD */       "Local or Arg used outside a control method",
-/*    ASL_MSG_LONG_LINE */                  "Splitting long input line",
-/*    ASL_MSG_MEMORY_ALLOCATION */          "Memory allocation failure",
-/*    ASL_MSG_MISSING_ENDDEPENDENT */       "Missing EndDependentFn() macro in dependent resource list",
-/*    ASL_MSG_MISSING_STARTDEPENDENT */     "Missing StartDependentFn() macro in dependent resource list",
-/*    ASL_MSG_MULTIPLE_DEFAULT */           "More than one Default statement within Switch construct",
-/*    ASL_MSG_MULTIPLE_TYPES */             "Multiple types",
-/*    ASL_MSG_NAME_EXISTS */                "Name already exists in scope",
-/*    ASL_MSG_NAME_OPTIMIZATION */          "NamePath optimized",
-/*    ASL_MSG_NAMED_OBJECT_IN_WHILE */      "Creating a named object in a While loop",
-/*    ASL_MSG_NESTED_COMMENT */             "Nested comment found",
-/*    ASL_MSG_NO_CASES */                   "No Case statements under Switch",
-/*    ASL_MSG_NO_REGION */                  "_REG has no corresponding Operation Region",
-/*    ASL_MSG_NO_RETVAL */                  "Called method returns no value",
-/*    ASL_MSG_NO_WHILE */                   "No enclosing While statement",
-/*    ASL_MSG_NON_ASCII */                  "Invalid characters found in file",
-/*    ASL_MSG_NON_ZERO */                   "Operand evaluates to zero",
-/*    ASL_MSG_NOT_EXIST */                  "Object does not exist",
-/*    ASL_MSG_NOT_FOUND */                  "Object not found or not accessible from scope",
-/*    ASL_MSG_NOT_METHOD */                 "Not a control method, cannot invoke",
-/*    ASL_MSG_NOT_PARAMETER */              "Not a parameter, used as local only",
-/*    ASL_MSG_NOT_REACHABLE */              "Object is not accessible from this scope",
-/*    ASL_MSG_NOT_REFERENCED */             "Object is not referenced",
-/*    ASL_MSG_NULL_DESCRIPTOR */            "Min/Max/Length/Gran are all zero, but no resource tag",
-/*    ASL_MSG_NULL_STRING */                "Invalid zero-length (null) string",
-/*    ASL_MSG_OPEN */                       "Could not open file",
-/*    ASL_MSG_OUTPUT_FILE_OPEN */           "Could not open output AML file",
-/*    ASL_MSG_OUTPUT_FILENAME */            "Could not create output filename",
-/*    ASL_MSG_PACKAGE_LENGTH */             "Effective AML package length is zero",
-/*    ASL_MSG_PREPROCESSOR_FILENAME */      "Could not create preprocessor filename",
-/*    ASL_MSG_READ */                       "Could not read file",
-/*    ASL_MSG_RECURSION */                  "Recursive method call",
-/*    ASL_MSG_REGION_BUFFER_ACCESS */       "Host Operation Region requires BufferAcc access",
-/*    ASL_MSG_REGION_BYTE_ACCESS */         "Host Operation Region requires ByteAcc access",
-/*    ASL_MSG_RESERVED_ARG_COUNT_HI */      "Reserved method has too many arguments",
-/*    ASL_MSG_RESERVED_ARG_COUNT_LO */      "Reserved method has too few arguments",
-/*    ASL_MSG_RESERVED_METHOD */            "Reserved name must be a control method",
-/*    ASL_MSG_RESERVED_NO_RETURN_VAL */     "Reserved method should not return a value",
-/*    ASL_MSG_RESERVED_OPERAND_TYPE */      "Invalid object type for reserved name",
-/*    ASL_MSG_RESERVED_PACKAGE_LENGTH */    "Invalid package length for reserved name",
-/*    ASL_MSG_RESERVED_RETURN_VALUE */      "Reserved method must return a value",
-/*    ASL_MSG_RESERVED_USE */               "Invalid use of reserved name",
-/*    ASL_MSG_RESERVED_WORD */              "Use of reserved name",
-/*    ASL_MSG_RESOURCE_FIELD */             "Resource field name cannot be used as a target",
-/*    ASL_MSG_RESOURCE_INDEX */             "Missing ResourceSourceIndex (required)",
-/*    ASL_MSG_RESOURCE_LIST */              "Too many resource items (internal error)",
-/*    ASL_MSG_RESOURCE_SOURCE */            "Missing ResourceSource string (required)",
-/*    ASL_MSG_RESULT_NOT_USED */            "Result is not used, operator has no effect",
-/*    ASL_MSG_RETURN_TYPES */               "Not all control paths return a value",
-/*    ASL_MSG_SCOPE_FWD_REF */              "Forward references from Scope operator not allowed",
-/*    ASL_MSG_SCOPE_TYPE */                 "Existing object has invalid type for Scope operator",
-/*    ASL_MSG_SEEK */                       "Could not seek file",
-/*    ASL_MSG_SERIALIZED */                 "Control Method marked Serialized",
-/*    ASL_MSG_SERIALIZED_REQUIRED */        "Control Method should be made Serialized",
-/*    ASL_MSG_SINGLE_NAME_OPTIMIZATION */   "NamePath optimized to NameSeg (uses run-time search path)",
-/*    ASL_MSG_SOME_NO_RETVAL */             "Called method may not always return a value",
-/*    ASL_MSG_STRING_LENGTH */              "String literal too long",
-/*    ASL_MSG_SWITCH_TYPE */                "Switch expression is not a static Integer/Buffer/String data type, defaulting to Integer",
-/*    ASL_MSG_SYNC_LEVEL */                 "SyncLevel must be in the range 0-15",
-/*    ASL_MSG_SYNTAX */                     "",
-/*    ASL_MSG_TABLE_SIGNATURE */            "Invalid Table Signature",
-/*    ASL_MSG_TAG_LARGER */                 "ResourceTag larger than Field",
-/*    ASL_MSG_TAG_SMALLER */                "ResourceTag smaller than Field",
-/*    ASL_MSG_TIMEOUT */                    "Result is not used, possible operator timeout will be missed",
-/*    ASL_MSG_TOO_MANY_TEMPS */             "Method requires too many temporary variables (_T_x)",
-/*    ASL_MSG_TRUNCATION */                 "64-bit return value will be truncated to 32 bits (DSDT version < 2)",
-/*    ASL_MSG_UNKNOWN_RESERVED_NAME */      "Unknown reserved name",
-/*    ASL_MSG_UNREACHABLE_CODE */           "Statement is unreachable",
-/*    ASL_MSG_UNSUPPORTED */                "Unsupported feature",
-/*    ASL_MSG_UPPER_CASE */                 "Non-hex letters must be upper case",
-/*    ASL_MSG_VENDOR_LIST */                "Too many vendor data bytes (7 max)",
-/*    ASL_MSG_WRITE */                      "Could not write file",
-/*    ASL_MSG_RANGE */                      "Constant out of range",
-/*    ASL_MSG_BUFFER_ALLOCATION */          "Could not allocate line buffer",
-
-/* Preprocessor */
-
-/*    ASL_MSG_DIRECTIVE_SYNTAX */           "Invalid directive syntax",
-/*    ASL_MSG_ENDIF_MISMATCH */             "Mismatched #endif",
-/*    ASL_MSG_ERROR_DIRECTIVE */            "#error",
-/*    ASL_MSG_EXISTING_NAME */              "Name is already defined",
-/*    ASL_MSG_INVALID_INVOCATION */         "Invalid macro invocation",
-/*    ASL_MSG_MACRO_SYNTAX */               "Invalid macro syntax",
-/*    ASL_MSG_TOO_MANY_ARGUMENTS */         "Too many macro arguments",
-/*    ASL_MSG_UNKNOWN_DIRECTIVE */          "Unknown directive",
-/*    ASL_MSG_UNKNOWN_PRAGMA */             "Unknown pragma",
-/*    ASL_MSG_WARNING_DIRECTIVE */          "#warning",
-
-/* Table compiler */
+    ASL_MSG_DIRECTIVE_SYNTAX = ASL_MSG_PREPROCESSOR,
+    ASL_MSG_ENDIF_MISMATCH,
+    ASL_MSG_ERROR_DIRECTIVE,
+    ASL_MSG_EXISTING_NAME,
+    ASL_MSG_INVALID_INVOCATION,
+    ASL_MSG_MACRO_SYNTAX,
+    ASL_MSG_TOO_MANY_ARGUMENTS,
+    ASL_MSG_UNKNOWN_DIRECTIVE,
+    ASL_MSG_UNKNOWN_PRAGMA,
+    ASL_MSG_WARNING_DIRECTIVE,
 
-/*    ASL_MSG_BUFFER_ELEMENT */             "Invalid element in buffer initializer list",
-/*    ASL_MSG_DIVIDE_BY_ZERO */             "Expression contains divide-by-zero",
-/*    ASL_MSG_FLAG_VALUE */                 "Flag value is too large",
-/*    ASL_MSG_INTEGER_SIZE */               "Integer too large for target",
-/*    ASL_MSG_INVALID_EXPRESSION */         "Invalid expression",
-/*    ASL_MSG_INVALID_FIELD_NAME */         "Invalid Field Name",
-/*    ASL_MSG_INVALID_HEX_INTEGER */        "Invalid hex integer constant",
-/*    ASL_MSG_OEM_TABLE */                  "OEM table - unknown contents",
-/*    ASL_MSG_RESERVED_VALUE */             "Reserved field",
-/*    ASL_MSG_UNKNOWN_LABEL */              "Label is undefined",
-/*    ASL_MSG_UNKNOWN_SUBTABLE */           "Unknown subtable type",
-/*    ASL_MSG_UNKNOWN_TABLE */              "Unknown ACPI table signature",
-/*    ASL_MSG_ZERO_VALUE */                 "Value must be non-zero"
-};
+} ASL_MESSAGE_IDS;
 
-#endif  /* ASL_EXCEPTIONS */
 
 #endif  /* __ASLMESSAGES_H */
diff --git a/src/acpica/source/compiler/aslmethod.c b/src/acpica/source/compiler/aslmethod.c
index a30acb4..7aca8f6 100644
--- a/src/acpica/source/compiler/aslmethod.c
+++ b/src/acpica/source/compiler/aslmethod.c
@@ -180,7 +180,18 @@ MtMethodAnalysisWalkBegin (
 
         WalkInfo->MethodStack = MethodInfo;
 
-        /* Get the name node, ignored here */
+        /* Special handling for _PRP, must have a _HID also */
+
+        if (!ACPI_STRCMP (METHOD_NAME__PRP, Op->Asl.NameSeg))
+        {
+            if (!ApFindNameInScope (METHOD_NAME__HID, Op))
+            {
+                AslError (ASL_WARNING, ASL_MSG_MISSING_DEPENDENCY, Op,
+                    "_PRP requires _HID in same scope");
+            }
+        }
+
+        /* Get the name node */
 
         Next = Op->Asl.Child;
 
@@ -484,6 +495,16 @@ MtMethodAnalysisWalkBegin (
                 AnCheckId (Next, ASL_TYPE_CID);
             }
         }
+
+        else if (!ACPI_STRCMP (METHOD_NAME__PRP, Op->Asl.NameSeg))
+        {
+            if (!ApFindNameInScope (METHOD_NAME__HID, Op))
+            {
+                AslError (ASL_WARNING, ASL_MSG_MISSING_DEPENDENCY, Op,
+                    "_PRP requires _HID in same scope");
+            }
+        }
+
         break;
 
     default:
diff --git a/src/acpica/source/compiler/aslprepkg.c b/src/acpica/source/compiler/aslprepkg.c
index afcbd48..2de5559 100644
--- a/src/acpica/source/compiler/aslprepkg.c
+++ b/src/acpica/source/compiler/aslprepkg.c
@@ -539,6 +539,12 @@ ApCheckPackageList (
                     Count, ExpectedCount);
                 break;
             }
+            if (Count > ExpectedCount)
+            {
+                ApPackageTooLarge (PredefinedName, SubPackageOp,
+                    Count, ExpectedCount);
+                break;
+            }
 
             ApCheckPackageElements (PredefinedName, Op,
                 Package->RetInfo.ObjectType1, Package->RetInfo.Count1,
@@ -575,6 +581,12 @@ ApCheckPackageList (
                     Count, ExpectedCount);
                 break;
             }
+            if (Count > ExpectedCount)
+            {
+                ApPackageTooLarge (PredefinedName, SubPackageOp,
+                    Count, ExpectedCount);
+                break;
+            }
 
             /* Check each object/type combination */
 
diff --git a/src/acpica/source/compiler/asltypes.h b/src/acpica/source/compiler/asltypes.h
index fcfb945..7e06d0b 100644
--- a/src/acpica/source/compiler/asltypes.h
+++ b/src/acpica/source/compiler/asltypes.h
@@ -268,7 +268,7 @@ typedef struct asl_error_msg
     char                        *Filename;
     char                        *SourceLine;
     UINT32                      FilenameLength;
-    UINT8                       MessageId;
+    UINT16                      MessageId;
     UINT8                       Level;
 
 } ASL_ERROR_MSG;
diff --git a/src/acpica/source/compiler/dtcompiler.h b/src/acpica/source/compiler/dtcompiler.h
index cc1b73f..313650a 100644
--- a/src/acpica/source/compiler/dtcompiler.h
+++ b/src/acpica/source/compiler/dtcompiler.h
@@ -393,20 +393,20 @@ DtWalkTableTree (
 void
 DtError (
     UINT8                   Level,
-    UINT8                   MessageId,
+    UINT16                  MessageId,
     DT_FIELD                *FieldObject,
     char                    *ExtraMessage);
 
 void
 DtNameError (
     UINT8                   Level,
-    UINT8                   MessageId,
+    UINT16                  MessageId,
     DT_FIELD                *FieldObject,
     char                    *ExtraMessage);
 
 void
 DtFatal (
-    UINT8                   MessageId,
+    UINT16                  MessageId,
     DT_FIELD                *FieldObject,
     char                    *ExtraMessage);
 
@@ -500,6 +500,10 @@ DtCompileIvrs (
     void                    **PFieldList);
 
 ACPI_STATUS
+DtCompileLpit (
+    void                    **PFieldList);
+
+ACPI_STATUS
 DtCompileMadt (
     void                    **PFieldList);
 
@@ -591,6 +595,7 @@ extern const unsigned char  TemplateGtdt[];
 extern const unsigned char  TemplateHest[];
 extern const unsigned char  TemplateHpet[];
 extern const unsigned char  TemplateIvrs[];
+extern const unsigned char  TemplateLpit[];
 extern const unsigned char  TemplateMadt[];
 extern const unsigned char  TemplateMcfg[];
 extern const unsigned char  TemplateMchi[];
diff --git a/src/acpica/source/compiler/dttable.c b/src/acpica/source/compiler/dttable.c
index 58aa9f1..5e310d6 100644
--- a/src/acpica/source/compiler/dttable.c
+++ b/src/acpica/source/compiler/dttable.c
@@ -526,7 +526,7 @@ DtCompileCsrt (
     UINT32                  GroupLength;
 
 
-    /* Sub-tables (Resource Groups) */
+    /* Subtables (Resource Groups) */
 
     while (*PFieldList)
     {
@@ -1376,6 +1376,87 @@ DtCompileIvrs (
 
 /******************************************************************************
  *
+ * FUNCTION:    DtCompileLpit
+ *
+ * PARAMETERS:  List                - Current field list pointer
+ *
+ * RETURN:      Status
+ *
+ * DESCRIPTION: Compile LPIT.
+ *
+ *****************************************************************************/
+
+ACPI_STATUS
+DtCompileLpit (
+    void                    **List)
+{
+    ACPI_STATUS             Status;
+    DT_SUBTABLE             *Subtable;
+    DT_SUBTABLE             *ParentTable;
+    DT_FIELD                **PFieldList = (DT_FIELD **) List;
+    DT_FIELD                *SubtableStart;
+    ACPI_DMTABLE_INFO       *InfoTable;
+    ACPI_LPIT_HEADER        *LpitHeader;
+
+
+    /* Note: Main table consists only of the standard ACPI table header */
+
+    while (*PFieldList)
+    {
+        SubtableStart = *PFieldList;
+
+        /* LPIT Subtable header */
+
+        Status = DtCompileTable (PFieldList, AcpiDmTableInfoLpitHdr,
+                    &Subtable, TRUE);
+        if (ACPI_FAILURE (Status))
+        {
+            return (Status);
+        }
+
+        ParentTable = DtPeekSubtable ();
+        DtInsertSubtable (ParentTable, Subtable);
+        DtPushSubtable (Subtable);
+
+        LpitHeader = ACPI_CAST_PTR (ACPI_LPIT_HEADER, Subtable->Buffer);
+
+        switch (LpitHeader->Type)
+        {
+        case ACPI_LPIT_TYPE_NATIVE_CSTATE:
+
+            InfoTable = AcpiDmTableInfoLpit0;
+            break;
+
+        case ACPI_LPIT_TYPE_SIMPLE_IO:
+
+            InfoTable = AcpiDmTableInfoLpit1;
+            break;
+
+        default:
+
+            DtFatal (ASL_MSG_UNKNOWN_SUBTABLE, SubtableStart, "LPIT");
+            return (AE_ERROR);
+        }
+
+        /* LPIT Subtable */
+
+        Status = DtCompileTable (PFieldList, InfoTable, &Subtable, TRUE);
+        if (ACPI_FAILURE (Status))
+        {
+            return (Status);
+        }
+
+        ParentTable = DtPeekSubtable ();
+        DtInsertSubtable (ParentTable, Subtable);
+        DtPopSubtable ();
+    }
+
+    return (AE_OK);
+}
+
+
+/******************************************************************************
+ *
  * FUNCTION:    DtCompileMadt
  *
  * PARAMETERS:  List                - Current field list pointer
diff --git a/src/acpica/source/compiler/dttemplate.h b/src/acpica/source/compiler/dttemplate.h
index a1fe9ca..681d3e5 100644
--- a/src/acpica/source/compiler/dttemplate.h
+++ b/src/acpica/source/compiler/dttemplate.h
@@ -620,6 +620,33 @@ const unsigned char TemplateIvrs[] =
     0x00,0x00,0x00,0x00                       /* 000000B8    "...."     */
 };
 
+const unsigned char TemplateLpit[] =
+{
+    0x4C,0x50,0x49,0x54,0xB4,0x00,0x00,0x00,  /* 00000000    "LPIT...." */
+    0x01,0x20,0x49,0x4E,0x54,0x45,0x4C,0x20,  /* 00000008    ". INTEL " */
+    0x54,0x45,0x4D,0x50,0x4C,0x41,0x54,0x45,  /* 00000010    "TEMPLATE" */
+    0x01,0x00,0x00,0x00,0x49,0x4E,0x54,0x4C,  /* 00000018    "....INTL" */
+    0x25,0x03,0x14,0x20,0x00,0x00,0x00,0x00,  /* 00000020    "%.. ...." */
+    0x38,0x00,0x00,0x00,0x00,0x00,0x00,0x00,  /* 00000028    "8......." */
+    0x00,0x00,0x00,0x00,0x7F,0x01,0x02,0x00,  /* 00000030    "........" */
+    0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,  /* 00000038    "........" */
+    0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,  /* 00000040    "........" */
+    0x00,0x20,0x00,0x03,0x00,0x00,0x00,0x00,  /* 00000048    ". ......" */
+    0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,  /* 00000050    "........" */
+    0x00,0x00,0x00,0x00,0x01,0x00,0x00,0x00,  /* 00000058    "........" */
+    0x58,0x00,0x00,0x00,0x01,0x00,0x00,0x00,  /* 00000060    "X......." */
+    0x00,0x00,0x00,0x00,0x01,0x10,0x00,0x02,  /* 00000068    "........" */
+    0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,  /* 00000070    "........" */
+    0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,  /* 00000078    "........" */
+    0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,  /* 00000080    "........" */
+    0x00,0x00,0x00,0x00,0x01,0x10,0x00,0x02,  /* 00000088    "........" */
+    0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,  /* 00000090    "........" */
+    0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,  /* 00000098    "........" */
+    0x00,0x08,0x00,0x01,0x00,0x00,0x00,0x00,  /* 000000A0    "........" */
+    0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,  /* 000000A8    "........" */
+    0x00,0x00,0x00,0x00                       /* 000000B0    "...."     */
+};
+
 /* MADT with ACPI 5.0 subtables */
 
 const unsigned char TemplateMadt[] =
diff --git a/src/acpica/source/compiler/dtutils.c b/src/acpica/source/compiler/dtutils.c
index 62ca4a3..d3cedf1 100644
--- a/src/acpica/source/compiler/dtutils.c
+++ b/src/acpica/source/compiler/dtutils.c
@@ -149,7 +149,7 @@ DtSum (
 void
 DtError (
     UINT8                   Level,
-    UINT8                   MessageId,
+    UINT16                  MessageId,
     DT_FIELD                *FieldObject,
     char                    *ExtraMessage)
 {
@@ -196,7 +196,7 @@ DtError (
 void
 DtNameError (
     UINT8                   Level,
-    UINT8                   MessageId,
+    UINT16                  MessageId,
     DT_FIELD                *FieldObject,
     char                    *ExtraMessage)
 {
@@ -249,7 +249,7 @@ DtNameError (
 
 void
 DtFatal (
-    UINT8                   MessageId,
+    UINT16                  MessageId,
     DT_FIELD                *FieldObject,
     char                    *ExtraMessage)
 {
@@ -605,6 +605,7 @@ DtGetFieldLength (
     case ACPI_DMT_NAME4:
     case ACPI_DMT_SLIC:
     case ACPI_DMT_SIG:
+    case ACPI_DMT_LPIT:
 
         ByteLength = 4;
         break;
diff --git a/src/acpica/source/compiler/fwts_iasl_interface.c b/src/acpica/source/compiler/fwts_iasl_interface.c
index 180dadd..fd69e6b 100644
--- a/src/acpica/source/compiler/fwts_iasl_interface.c
+++ b/src/acpica/source/compiler/fwts_iasl_interface.c
@@ -21,6 +21,7 @@
 
 #include <unistd.h>
 #include <stdbool.h>
+#include <stdint.h>
 #include <sys/types.h>
 #include <sys/wait.h>
 
@@ -201,3 +202,20 @@ int fwts_iasl_assemble_aml(const char *source, char **stdout_output, char **stde
 
 	return ret;
 }
+
+/*
+ *  fwts_iasl_exception_level__()
+ *	shim wrapper for AeDecodeExceptionLevel level decoding
+ */
+const char *fwts_iasl_exception_level__(uint8_t level)
+{
+	const char *str;
+
+	bool tmp = Gbl_VerboseErrors;
+
+	Gbl_VerboseErrors = true;
+	str = AeDecodeExceptionLevel((UINT8)level);
+	Gbl_VerboseErrors = tmp;
+
+	return str;
+}
diff --git a/src/acpica/source/compiler/fwts_iasl_interface.h b/src/acpica/source/compiler/fwts_iasl_interface.h
index 71675d3..29f3287 100644
--- a/src/acpica/source/compiler/fwts_iasl_interface.h
+++ b/src/acpica/source/compiler/fwts_iasl_interface.h
@@ -20,7 +20,10 @@
 #ifndef __FWTS_IASL_INTERFACE__
 #define __FWTS_IASL_INTERFACE__
 
+#include <stdint.h>
+
 int fwts_iasl_disassemble_aml(const char *aml, const char *outputfile);
 int fwts_iasl_assemble_aml(const char *source, char **stdout_output, char **stderr_output);
+const char *fwts_iasl_exception_level__(uint8_t level);
 
 #endif
diff --git a/src/acpica/source/compiler/preprocess.h b/src/acpica/source/compiler/preprocess.h
index eac2078..b5a57f5 100644
--- a/src/acpica/source/compiler/preprocess.h
+++ b/src/acpica/source/compiler/preprocess.h
@@ -329,7 +329,7 @@ PrGetNextToken (
 void
 PrError (
     UINT8                   Level,
-    UINT8                   MessageId,
+    UINT16                  MessageId,
     UINT32                  Column);
 
 void
diff --git a/src/acpica/source/compiler/prutils.c b/src/acpica/source/compiler/prutils.c
index c7b977e..198bbfc 100644
--- a/src/acpica/source/compiler/prutils.c
+++ b/src/acpica/source/compiler/prutils.c
@@ -221,7 +221,7 @@ PrGetNextToken (
 void
 PrError (
     UINT8                   Level,
-    UINT8                   MessageId,
+    UINT16                  MessageId,
     UINT32                  Column)
 {
 #if 0
diff --git a/src/acpica/source/components/debugger/dbcmds.c b/src/acpica/source/components/debugger/dbcmds.c
index d74f61c..6d70e03 100644
--- a/src/acpica/source/components/debugger/dbcmds.c
+++ b/src/acpica/source/components/debugger/dbcmds.c
@@ -411,7 +411,7 @@ AcpiDbDisplayTableInfo (
 
     /* Header */
 
-    AcpiOsPrintf ("Idx ID Status    Type            Sig  Address  Len   Header\n");
+    AcpiOsPrintf ("Idx ID    Status Type              TableHeader (Sig, Address, Length)\n");
 
     /* Walk the entire root table list */
 
@@ -438,22 +438,22 @@ AcpiDbDisplayTableInfo (
         {
         case ACPI_TABLE_ORIGIN_EXTERNAL_VIRTUAL:
 
-            AcpiOsPrintf ("External virtual  ");
+            AcpiOsPrintf ("External/virtual  ");
             break;
 
         case ACPI_TABLE_ORIGIN_INTERNAL_PHYSICAL:
 
-            AcpiOsPrintf ("Internal physical ");
+            AcpiOsPrintf ("Internal/physical ");
             break;
 
         case ACPI_TABLE_ORIGIN_INTERNAL_VIRTUAL:
 
-            AcpiOsPrintf ("Internal virtual  ");
+            AcpiOsPrintf ("Internal/virtual  ");
             break;
 
         default:
 
-            AcpiOsPrintf ("INVALID   ");
+            AcpiOsPrintf ("INVALID TYPE      ");
             break;
         }
 
@@ -1259,14 +1259,25 @@ AcpiDbGenerateGpe (
     char                    *GpeArg,
     char                    *BlockArg)
 {
-    UINT32                  BlockNumber;
+    UINT32                  BlockNumber = 0;
     UINT32                  GpeNumber;
     ACPI_GPE_EVENT_INFO     *GpeEventInfo;
 
 
-    GpeNumber   = ACPI_STRTOUL (GpeArg, NULL, 0);
-    BlockNumber = ACPI_STRTOUL (BlockArg, NULL, 0);
+    GpeNumber = ACPI_STRTOUL (GpeArg, NULL, 0);
 
+    /*
+     * If no block arg, or block arg == 0 or 1, use the FADT-defined
+     * GPE blocks.
+     */
+    if (BlockArg)
+    {
+        BlockNumber = ACPI_STRTOUL (BlockArg, NULL, 0);
+        if (BlockNumber == 1)
+        {
+            BlockNumber = 0;
+        }
+    }
 
     GpeEventInfo = AcpiEvGetGpeEventInfo (ACPI_TO_POINTER (BlockNumber),
         GpeNumber);
diff --git a/src/acpica/source/components/debugger/dbinput.c b/src/acpica/source/components/debugger/dbinput.c
index fde510b..c84bf8a 100644
--- a/src/acpica/source/components/debugger/dbinput.c
+++ b/src/acpica/source/components/debugger/dbinput.c
@@ -253,7 +253,7 @@ static const ACPI_DB_COMMAND_INFO   AcpiGbl_DbCommands[] =
     {"EXIT",         0},
     {"FIND",         1},
     {"GO",           0},
-    {"GPE",          2},
+    {"GPE",          1},
     {"GPES",         0},
     {"HANDLERS",     0},
     {"HELP",         0},
@@ -377,7 +377,7 @@ static const ACPI_DB_COMMAND_HELP   AcpiGbl_DbCommandHelp[] =
 
     {0, "\nHardware Related Commands:",         "\n"},
     {1, "  Event <F|G> <Value>",               "Generate AcpiEvent (Fixed/GPE)\n"},
-    {1, "  Gpe <GpeNum> <GpeBlock>",           "Simulate a GPE\n"},
+    {1, "  Gpe <GpeNum> [GpeBlockDevice]",     "Simulate a GPE\n"},
     {1, "  Gpes",                              "Display info on all GPEs\n"},
     {1, "  Sci",                               "Generate an SCI\n"},
     {1, "  Sleep [SleepState]",                "Simulate sleep/wake sequence(s) (0-5)\n"},
diff --git a/src/acpica/source/components/events/evgpe.c b/src/acpica/source/components/events/evgpe.c
index d27fd80..bb955ac 100644
--- a/src/acpica/source/components/events/evgpe.c
+++ b/src/acpica/source/components/events/evgpe.c
@@ -504,7 +504,7 @@ AcpiEvGpeDetect (
                   GpeRegisterInfo->EnableForWake))
             {
                 ACPI_DEBUG_PRINT ((ACPI_DB_INTERRUPTS,
-                    "Ignore disabled registers for GPE%02X-GPE%02X: "
+                    "Ignore disabled registers for GPE %02X-%02X: "
                     "RunEnable=%02X, WakeEnable=%02X\n",
                     GpeRegisterInfo->BaseGpeNumber,
                     GpeRegisterInfo->BaseGpeNumber + (ACPI_GPE_REGISTER_WIDTH - 1),
@@ -530,7 +530,7 @@ AcpiEvGpeDetect (
             }
 
             ACPI_DEBUG_PRINT ((ACPI_DB_INTERRUPTS,
-                "Read registers for GPE%02X-GPE%02X: Status=%02X, Enable=%02X, "
+                "Read registers for GPE %02X-%02X: Status=%02X, Enable=%02X, "
                 "RunEnable=%02X, WakeEnable=%02X\n",
                 GpeRegisterInfo->BaseGpeNumber,
                 GpeRegisterInfo->BaseGpeNumber + (ACPI_GPE_REGISTER_WIDTH - 1),
@@ -843,7 +843,7 @@ AcpiEvGpeDispatch (
         if (ACPI_FAILURE (Status))
         {
             ACPI_EXCEPTION ((AE_INFO, Status,
-                "Unable to clear GPE%02X", GpeNumber));
+                "Unable to clear GPE %02X", GpeNumber));
             return_UINT32 (ACPI_INTERRUPT_NOT_HANDLED);
         }
     }
@@ -861,7 +861,7 @@ AcpiEvGpeDispatch (
     if (ACPI_FAILURE (Status))
     {
         ACPI_EXCEPTION ((AE_INFO, Status,
-            "Unable to disable GPE%02X", GpeNumber));
+            "Unable to disable GPE %02X", GpeNumber));
         return_UINT32 (ACPI_INTERRUPT_NOT_HANDLED);
     }
 
@@ -901,7 +901,7 @@ AcpiEvGpeDispatch (
         if (ACPI_FAILURE (Status))
         {
             ACPI_EXCEPTION ((AE_INFO, Status,
-                "Unable to queue handler for GPE%02X - event disabled",
+                "Unable to queue handler for GPE %02X - event disabled",
                 GpeNumber));
         }
         break;
@@ -913,7 +913,7 @@ AcpiEvGpeDispatch (
          * a GPE to be enabled if it has no handler or method.
          */
         ACPI_ERROR ((AE_INFO,
-            "No handler or method for GPE%02X, disabling event",
+            "No handler or method for GPE %02X, disabling event",
             GpeNumber));
         break;
     }
diff --git a/src/acpica/source/components/events/evgpeblk.c b/src/acpica/source/components/events/evgpeblk.c
index f1a5b1b..4de91c1 100644
--- a/src/acpica/source/components/events/evgpeblk.c
+++ b/src/acpica/source/components/events/evgpeblk.c
@@ -354,17 +354,17 @@ AcpiEvCreateGpeInfoBlocks (
     {
         /* Init the RegisterInfo for this GPE register (8 GPEs) */
 
-        ThisRegister->BaseGpeNumber = (UINT8) (GpeBlock->BlockBaseNumber +
-                                             (i * ACPI_GPE_REGISTER_WIDTH));
+        ThisRegister->BaseGpeNumber = (UINT16)
+            (GpeBlock->BlockBaseNumber + (i * ACPI_GPE_REGISTER_WIDTH));
 
         ThisRegister->StatusAddress.Address =
-            GpeBlock->BlockAddress.Address + i;
+            GpeBlock->Address + i;
 
         ThisRegister->EnableAddress.Address =
-            GpeBlock->BlockAddress.Address + i + GpeBlock->RegisterCount;
+            GpeBlock->Address + i + GpeBlock->RegisterCount;
 
-        ThisRegister->StatusAddress.SpaceId   = GpeBlock->BlockAddress.SpaceId;
-        ThisRegister->EnableAddress.SpaceId   = GpeBlock->BlockAddress.SpaceId;
+        ThisRegister->StatusAddress.SpaceId   = GpeBlock->SpaceId;
+        ThisRegister->EnableAddress.SpaceId   = GpeBlock->SpaceId;
         ThisRegister->StatusAddress.BitWidth  = ACPI_GPE_REGISTER_WIDTH;
         ThisRegister->EnableAddress.BitWidth  = ACPI_GPE_REGISTER_WIDTH;
         ThisRegister->StatusAddress.BitOffset = 0;
@@ -437,9 +437,10 @@ ErrorExit:
 ACPI_STATUS
 AcpiEvCreateGpeBlock (
     ACPI_NAMESPACE_NODE     *GpeDevice,
-    ACPI_GENERIC_ADDRESS    *GpeBlockAddress,
+    UINT64                  Address,
+    UINT8                   SpaceId,
     UINT32                  RegisterCount,
-    UINT8                   GpeBlockBaseNumber,
+    UINT16                  GpeBlockBaseNumber,
     UINT32                  InterruptNumber,
     ACPI_GPE_BLOCK_INFO     **ReturnGpeBlock)
 {
@@ -466,15 +467,14 @@ AcpiEvCreateGpeBlock (
 
     /* Initialize the new GPE block */
 
+    GpeBlock->Address = Address;
+    GpeBlock->SpaceId = SpaceId;
     GpeBlock->Node = GpeDevice;
     GpeBlock->GpeCount = (UINT16) (RegisterCount * ACPI_GPE_REGISTER_WIDTH);
     GpeBlock->Initialized = FALSE;
     GpeBlock->RegisterCount = RegisterCount;
     GpeBlock->BlockBaseNumber = GpeBlockBaseNumber;
 
-    ACPI_MEMCPY (&GpeBlock->BlockAddress, GpeBlockAddress,
-        sizeof (ACPI_GENERIC_ADDRESS));
-
     /*
      * Create the RegisterInfo and EventInfo sub-structures
      * Note: disables and clears all GPEs in the block
@@ -517,11 +517,11 @@ AcpiEvCreateGpeBlock (
     }
 
     ACPI_DEBUG_PRINT_RAW ((ACPI_DB_INIT,
-        "    Initialized GPE %02X to %02X [%4.4s] %u regs on interrupt 0x%X\n",
+        "    Initialized GPE %02X to %02X [%4.4s] %u regs on interrupt 0x%X%s\n",
         (UINT32) GpeBlock->BlockBaseNumber,
         (UINT32) (GpeBlock->BlockBaseNumber + (GpeBlock->GpeCount - 1)),
-        GpeDevice->Name.Ascii, GpeBlock->RegisterCount,
-        InterruptNumber));
+        GpeDevice->Name.Ascii, GpeBlock->RegisterCount, InterruptNumber,
+        InterruptNumber == AcpiGbl_FADT.SciInterrupt ? " (SCI)" : ""));
 
     /* Update global count of currently available GPEs */
 
diff --git a/src/acpica/source/components/events/evgpeinit.c b/src/acpica/source/components/events/evgpeinit.c
index 6bf32ff..2e2e6b3 100644
--- a/src/acpica/source/components/events/evgpeinit.c
+++ b/src/acpica/source/components/events/evgpeinit.c
@@ -211,7 +211,9 @@ AcpiEvGpeInitialize (
         /* Install GPE Block 0 */
 
         Status = AcpiEvCreateGpeBlock (AcpiGbl_FadtGpeDevice,
-                    &AcpiGbl_FADT.XGpe0Block, RegisterCount0, 0,
+                    AcpiGbl_FADT.XGpe0Block.Address,
+                    AcpiGbl_FADT.XGpe0Block.SpaceId,
+                    RegisterCount0, 0,
                     AcpiGbl_FADT.SciInterrupt, &AcpiGbl_GpeFadtBlocks[0]);
 
         if (ACPI_FAILURE (Status))
@@ -249,7 +251,9 @@ AcpiEvGpeInitialize (
             /* Install GPE Block 1 */
 
             Status = AcpiEvCreateGpeBlock (AcpiGbl_FadtGpeDevice,
-                        &AcpiGbl_FADT.XGpe1Block, RegisterCount1,
+                        AcpiGbl_FADT.XGpe1Block.Address,
+                        AcpiGbl_FADT.XGpe1Block.SpaceId,
+                        RegisterCount1,
                         AcpiGbl_FADT.Gpe1Base,
                         AcpiGbl_FADT.SciInterrupt, &AcpiGbl_GpeFadtBlocks[1]);
 
diff --git a/src/acpica/source/components/events/evxfgpe.c b/src/acpica/source/components/events/evxfgpe.c
index 8ab1ed1..e180bd3 100644
--- a/src/acpica/source/components/events/evxfgpe.c
+++ b/src/acpica/source/components/events/evxfgpe.c
@@ -881,7 +881,8 @@ AcpiInstallGpeBlock (
      * For user-installed GPE Block Devices, the GpeBlockBaseNumber
      * is always zero
      */
-    Status = AcpiEvCreateGpeBlock (Node, GpeBlockAddress, RegisterCount,
+    Status = AcpiEvCreateGpeBlock (Node, GpeBlockAddress->Address,
+                GpeBlockAddress->SpaceId, RegisterCount,
                 0, InterruptNumber, &GpeBlock);
     if (ACPI_FAILURE (Status))
     {
diff --git a/src/acpica/source/components/hardware/hwpci.c b/src/acpica/source/components/hardware/hwpci.c
index 42b5f59..24b7c01 100644
--- a/src/acpica/source/components/hardware/hwpci.c
+++ b/src/acpica/source/components/hardware/hwpci.c
@@ -233,11 +233,12 @@ AcpiHwDerivePciId (
         /* Walk the list, updating the PCI device/function/bus numbers */
 
         Status = AcpiHwProcessPciList (PciId, ListHead);
-    }
 
-    /* Always delete the list */
+        /* Delete the list */
+
+        AcpiHwDeletePciList (ListHead);
+    }
 
-    AcpiHwDeletePciList (ListHead);
     return_ACPI_STATUS (Status);
 }
 
@@ -285,6 +286,9 @@ AcpiHwBuildPciList (
         Status = AcpiGetParent (CurrentDevice, &ParentDevice);
         if (ACPI_FAILURE (Status))
         {
+            /* Must delete the list before exit */
+
+            AcpiHwDeletePciList (*ReturnListHead);
             return (Status);
         }
 
@@ -299,6 +303,9 @@ AcpiHwBuildPciList (
         ListElement = ACPI_ALLOCATE (sizeof (ACPI_PCI_DEVICE));
         if (!ListElement)
         {
+            /* Must delete the list before exit */
+
+            AcpiHwDeletePciList (*ReturnListHead);
             return (AE_NO_MEMORY);
         }
 
diff --git a/src/acpica/source/components/resources/rscreate.c b/src/acpica/source/components/resources/rscreate.c
index 7c23893..03298f4 100644
--- a/src/acpica/source/components/resources/rscreate.c
+++ b/src/acpica/source/components/resources/rscreate.c
@@ -149,6 +149,10 @@ AcpiBufferToResource (
     void                    *Resource;
     void                    *CurrentResourcePtr;
 
+
+    ACPI_FUNCTION_TRACE (AcpiBufferToResource);
+
+
     /*
      * Note: we allow AE_AML_NO_RESOURCE_END_TAG, since an end tag
      * is not required here.
@@ -164,7 +168,7 @@ AcpiBufferToResource (
     }
     if (ACPI_FAILURE (Status))
     {
-        return (Status);
+        return_ACPI_STATUS (Status);
     }
 
     /* Allocate a buffer for the converted resource */
@@ -173,7 +177,7 @@ AcpiBufferToResource (
     CurrentResourcePtr = Resource;
     if (!Resource)
     {
-        return (AE_NO_MEMORY);
+        return_ACPI_STATUS (AE_NO_MEMORY);
     }
 
     /* Perform the AML-to-Resource conversion */
@@ -193,9 +197,11 @@ AcpiBufferToResource (
         *ResourcePtr = Resource;
     }
 
-    return (Status);
+    return_ACPI_STATUS (Status);
 }
 
+ACPI_EXPORT_SYMBOL (AcpiBufferToResource)
+
 
 /*******************************************************************************
  *
diff --git a/src/acpica/source/components/tables/tbfadt.c b/src/acpica/source/components/tables/tbfadt.c
index 9809274..8cb69a9 100644
--- a/src/acpica/source/components/tables/tbfadt.c
+++ b/src/acpica/source/components/tables/tbfadt.c
@@ -130,7 +130,8 @@ AcpiTbInitGenericAddress (
     UINT8                   SpaceId,
     UINT8                   ByteWidth,
     UINT64                  Address,
-    char                    *RegisterName);
+    char                    *RegisterName,
+    UINT8                   Flags);
 
 static void
 AcpiTbConvertFadt (
@@ -156,13 +157,14 @@ typedef struct acpi_fadt_info
     UINT16                  Address32;
     UINT16                  Length;
     UINT8                   DefaultLength;
-    UINT8                   Type;
+    UINT8                   Flags;
 
 } ACPI_FADT_INFO;
 
 #define ACPI_FADT_OPTIONAL          0
 #define ACPI_FADT_REQUIRED          1
 #define ACPI_FADT_SEPARATE_LENGTH   2
+#define ACPI_FADT_GPE_REGISTER      4
 
 static ACPI_FADT_INFO     FadtInfoTable[] =
 {
@@ -213,14 +215,14 @@ static ACPI_FADT_INFO     FadtInfoTable[] =
         ACPI_FADT_OFFSET (Gpe0Block),
         ACPI_FADT_OFFSET (Gpe0BlockLength),
         0,
-        ACPI_FADT_SEPARATE_LENGTH},
+        ACPI_FADT_SEPARATE_LENGTH | ACPI_FADT_GPE_REGISTER},
 
     {"Gpe1Block",
         ACPI_FADT_OFFSET (XGpe1Block),
         ACPI_FADT_OFFSET (Gpe1Block),
         ACPI_FADT_OFFSET (Gpe1BlockLength),
         0,
-        ACPI_FADT_SEPARATE_LENGTH}
+        ACPI_FADT_SEPARATE_LENGTH | ACPI_FADT_GPE_REGISTER}
 };
 
 #define ACPI_FADT_INFO_ENTRIES \
@@ -284,21 +286,31 @@ AcpiTbInitGenericAddress (
     UINT8                   SpaceId,
     UINT8                   ByteWidth,
     UINT64                  Address,
-    char                    *RegisterName)
+    char                    *RegisterName,
+    UINT8                   Flags)
 {
     UINT8                   BitWidth;
 
 
-    /* Bit width field in the GAS is only one byte long, 255 max */
-
+    /*
+     * Bit width field in the GAS is only one byte long, 255 max.
+     * Check for BitWidth overflow in GAS.
+     */
     BitWidth = (UINT8) (ByteWidth * 8);
-
-    if (ByteWidth > 31) /* (31*8)=248 */
+    if (ByteWidth > 31)     /* (31*8)=248, (32*8)=256 */
     {
-        ACPI_ERROR ((AE_INFO,
-            "%s - 32-bit FADT register is too long (%u bytes, %u bits) "
-            "to convert to GAS struct - 255 bits max, truncating",
-            RegisterName, ByteWidth, (ByteWidth * 8)));
+        /*
+         * No error for GPE blocks, because we do not use the BitWidth
+         * for GPEs, the legacy length (ByteWidth) is used instead to
+         * allow for a large number of GPEs.
+         */
+        if (!(Flags & ACPI_FADT_GPE_REGISTER))
+        {
+            ACPI_ERROR ((AE_INFO,
+                "%s - 32-bit FADT register is too long (%u bytes, %u bits) "
+                "to convert to GAS struct - 255 bits max, truncating",
+                RegisterName, ByteWidth, (ByteWidth * 8)));
+        }
 
         BitWidth = 255;
     }
@@ -564,6 +576,7 @@ AcpiTbConvertFadt (
     ACPI_GENERIC_ADDRESS    *Address64;
     UINT32                  Address32;
     UINT8                   Length;
+    UINT8                   Flags;
     UINT32                  i;
 
 
@@ -628,6 +641,7 @@ AcpiTbConvertFadt (
             &AcpiGbl_FADT, FadtInfoTable[i].Length);
 
         Name = FadtInfoTable[i].Name;
+        Flags = FadtInfoTable[i].Flags;
 
         /*
          * Expand the ACPI 1.0 32-bit addresses to the ACPI 2.0 64-bit "X"
@@ -664,7 +678,7 @@ AcpiTbConvertFadt (
                     ACPI_ADR_SPACE_SYSTEM_IO,
                     *ACPI_ADD_PTR (UINT8, &AcpiGbl_FADT,
                         FadtInfoTable[i].Length),
-                    (UINT64) Address32, Name);
+                    (UINT64) Address32, Name, Flags);
             }
             else if (Address64->Address != (UINT64) Address32)
             {
@@ -685,7 +699,7 @@ AcpiTbConvertFadt (
                         ACPI_ADR_SPACE_SYSTEM_IO,
                         *ACPI_ADD_PTR (UINT8, &AcpiGbl_FADT,
                             FadtInfoTable[i].Length),
-                        (UINT64) Address32, Name);
+                        (UINT64) Address32, Name, Flags);
                 }
             }
         }
@@ -706,7 +720,7 @@ AcpiTbConvertFadt (
                 Name, ACPI_MUL_8 (Length), Address64->BitWidth));
         }
 
-        if (FadtInfoTable[i].Type & ACPI_FADT_REQUIRED)
+        if (FadtInfoTable[i].Flags & ACPI_FADT_REQUIRED)
         {
             /*
              * Field is required (PM1aEvent, PM1aControl).
@@ -720,7 +734,7 @@ AcpiTbConvertFadt (
                     Name, ACPI_FORMAT_UINT64 (Address64->Address), Length));
             }
         }
-        else if (FadtInfoTable[i].Type & ACPI_FADT_SEPARATE_LENGTH)
+        else if (FadtInfoTable[i].Flags & ACPI_FADT_SEPARATE_LENGTH)
         {
             /*
              * Field is optional (PM2Control, GPE0, GPE1) AND has its own
@@ -827,7 +841,7 @@ AcpiTbSetupFadtRegisters (
                 Source64->SpaceId, Pm1RegisterByteWidth,
                 Source64->Address +
                     (FadtPmInfoTable[i].RegisterNum * Pm1RegisterByteWidth),
-                "PmRegisters");
+                "PmRegisters", 0);
         }
     }
 }
diff --git a/src/acpica/source/components/tables/tbutils.c b/src/acpica/source/components/tables/tbutils.c
index 73cf76e..7cac46a 100644
--- a/src/acpica/source/components/tables/tbutils.c
+++ b/src/acpica/source/components/tables/tbutils.c
@@ -125,10 +125,6 @@
 
 /* Local prototypes */
 
-static ACPI_STATUS
-AcpiTbValidateXsdt (
-    ACPI_PHYSICAL_ADDRESS   Address);
-
 static ACPI_PHYSICAL_ADDRESS
 AcpiTbGetRootTableEntry (
     UINT8                   *TableEntry,
@@ -348,92 +344,6 @@ AcpiTbGetRootTableEntry (
 
 /*******************************************************************************
  *
- * FUNCTION:    AcpiTbValidateXsdt
- *
- * PARAMETERS:  Address             - Physical address of the XSDT (from RSDP)
- *
- * RETURN:      Status. AE_OK if the table appears to be valid.
- *
- * DESCRIPTION: Validate an XSDT to ensure that it is of minimum size and does
- *              not contain any NULL entries. A problem that is seen in the
- *              field is that the XSDT exists, but is actually useless because
- *              of one or more (or all) NULL entries.
- *
- ******************************************************************************/
-
-static ACPI_STATUS
-AcpiTbValidateXsdt (
-    ACPI_PHYSICAL_ADDRESS   XsdtAddress)
-{
-    ACPI_TABLE_HEADER       *Table;
-    UINT8                   *NextEntry;
-    ACPI_PHYSICAL_ADDRESS   Address;
-    UINT32                  Length;
-    UINT32                  EntryCount;
-    ACPI_STATUS             Status;
-    UINT32                  i;
-
-
-    /* Get the XSDT length */
-
-    Table = AcpiOsMapMemory (XsdtAddress, sizeof (ACPI_TABLE_HEADER));
-    if (!Table)
-    {
-        return (AE_NO_MEMORY);
-    }
-
-    Length = Table->Length;
-    AcpiOsUnmapMemory (Table, sizeof (ACPI_TABLE_HEADER));
-
-    /*
-     * Minimum XSDT length is the size of the standard ACPI header
-     * plus one physical address entry
-     */
-    if (Length < (sizeof (ACPI_TABLE_HEADER) + ACPI_XSDT_ENTRY_SIZE))
-    {
-        return (AE_INVALID_TABLE_LENGTH);
-    }
-
-    /* Map the entire XSDT */
-
-    Table = AcpiOsMapMemory (XsdtAddress, Length);
-    if (!Table)
-    {
-        return (AE_NO_MEMORY);
-    }
-
-    /* Get the number of entries and pointer to first entry */
-
-    Status = AE_OK;
-    NextEntry = ACPI_ADD_PTR (UINT8, Table, sizeof (ACPI_TABLE_HEADER));
-    EntryCount = (UINT32) ((Table->Length - sizeof (ACPI_TABLE_HEADER)) /
-        ACPI_XSDT_ENTRY_SIZE);
-
-    /* Validate each entry (physical address) within the XSDT */
-
-    for (i = 0; i < EntryCount; i++)
-    {
-        Address = AcpiTbGetRootTableEntry (NextEntry, ACPI_XSDT_ENTRY_SIZE);
-        if (!Address)
-        {
-            /* Detected a NULL entry, XSDT is invalid */
-
-            Status = AE_NULL_ENTRY;
-            break;
-        }
-
-        NextEntry += ACPI_XSDT_ENTRY_SIZE;
-    }
-
-    /* Unmap table */
-
-    AcpiOsUnmapMemory (Table, Length);
-    return (Status);
-}
-
-
-/*******************************************************************************
- *
  * FUNCTION:    AcpiTbParseRootTable
  *
  * PARAMETERS:  Rsdp                    - Pointer to the RSDP
@@ -507,25 +417,6 @@ AcpiTbParseRootTable (
      */
     AcpiOsUnmapMemory (Rsdp, sizeof (ACPI_TABLE_RSDP));
 
-    /*
-     * If it is present and used, validate the XSDT for access/size
-     * and ensure that all table entries are at least non-NULL
-     */
-    if (TableEntrySize == ACPI_XSDT_ENTRY_SIZE)
-    {
-        Status = AcpiTbValidateXsdt (Address);
-        if (ACPI_FAILURE (Status))
-        {
-            ACPI_BIOS_WARNING ((AE_INFO, "XSDT is invalid (%s), using RSDT",
-                AcpiFormatException (Status)));
-
-            /* Fall back to the RSDT */
-
-            Address = (ACPI_PHYSICAL_ADDRESS) Rsdp->RsdtPhysicalAddress;
-            TableEntrySize = ACPI_RSDT_ENTRY_SIZE;
-        }
-    }
-
     /* Map the RSDT/XSDT table header to get the full table length */
 
     Table = AcpiOsMapMemory (Address, sizeof (ACPI_TABLE_HEADER));
@@ -584,8 +475,16 @@ AcpiTbParseRootTable (
     {
         /* Get the table physical address (32-bit for RSDT, 64-bit for XSDT) */
 
-        Status = AcpiTbInstallStandardTable (
-            AcpiTbGetRootTableEntry (TableEntry, TableEntrySize),
+        Address = AcpiTbGetRootTableEntry (TableEntry, TableEntrySize);
+
+        /* Skip NULL entries in RSDT/XSDT */
+
+        if (!Address)
+        {
+            goto NextTable;
+        }
+
+        Status = AcpiTbInstallStandardTable (Address,
             ACPI_TABLE_ORIGIN_INTERNAL_PHYSICAL, FALSE, TRUE, &TableIndex);
 
         if (ACPI_SUCCESS (Status) &&
@@ -595,6 +494,8 @@ AcpiTbParseRootTable (
             AcpiTbParseFadt (TableIndex);
         }
 
+NextTable:
+
         TableEntry += TableEntrySize;
     }
 
diff --git a/src/acpica/source/components/utilities/utglobal.c b/src/acpica/source/components/utilities/utglobal.c
index 77294c4..a24abfc 100644
--- a/src/acpica/source/components/utilities/utglobal.c
+++ b/src/acpica/source/components/utilities/utglobal.c
@@ -130,31 +130,6 @@
  *
  ******************************************************************************/
 
-/* Debug output control masks */
-
-#ifdef ACPI_DEBUG_OUTPUT
-UINT32                      AcpiDbgLevel = ACPI_DEBUG_DEFAULT;
-#else
-UINT32                      AcpiDbgLevel = ACPI_NORMAL_DEFAULT;
-#endif
-
-UINT32                      AcpiDbgLayer = ACPI_COMPONENT_DEFAULT;
-
-/* AcpiGbl_FADT is a local copy of the FADT, converted to a common format. */
-
-ACPI_TABLE_FADT             AcpiGbl_FADT;
-UINT32                      AcpiGbl_TraceFlags;
-ACPI_NAME                   AcpiGbl_TraceMethodName;
-BOOLEAN                     AcpiGbl_SystemAwakeAndRunning;
-UINT32                      AcpiCurrentGpeCount;
-
-/*
- * 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;
-
 /* Various state name strings */
 
 const char                  *AcpiGbl_SleepStateNames[ACPI_S_STATE_COUNT] =
@@ -382,7 +357,6 @@ AcpiUtInitGlobals (
     AcpiGbl_AcpiHardwarePresent         = TRUE;
     AcpiGbl_LastOwnerIdIndex            = 0;
     AcpiGbl_NextOwnerIdOffset           = 0;
-    AcpiGbl_TraceMethodName             = 0;
     AcpiGbl_TraceDbgLevel               = 0;
     AcpiGbl_TraceDbgLayer               = 0;
     AcpiGbl_DebuggerConfiguration       = DEBUGGER_THREADING;
@@ -423,9 +397,7 @@ AcpiUtInitGlobals (
     AcpiGbl_DisableMemTracking          = FALSE;
 #endif
 
-#ifdef ACPI_DEBUGGER
-    AcpiGbl_DbTerminateThreads          = FALSE;
-#endif
+    ACPI_DEBUGGER_EXEC (AcpiGbl_DbTerminateThreads = FALSE);
 
     return_ACPI_STATUS (AE_OK);
 }
diff --git a/src/acpica/source/components/utilities/utobject.c b/src/acpica/source/components/utilities/utobject.c
index c32782b..0fdef14 100644
--- a/src/acpica/source/components/utilities/utobject.c
+++ b/src/acpica/source/components/utilities/utobject.c
@@ -472,7 +472,7 @@ AcpiUtValidInternalObject (
     default:
 
         ACPI_DEBUG_PRINT ((ACPI_DB_EXEC,
-                "%p is not not an ACPI operand obj [%s]\n",
+                "%p is not an ACPI operand obj [%s]\n",
                 Object, AcpiUtGetDescriptorName (Object)));
         break;
     }
diff --git a/src/acpica/source/components/utilities/utxferror.c b/src/acpica/source/components/utilities/utxferror.c
index af396c6..081bfd9 100644
--- a/src/acpica/source/components/utilities/utxferror.c
+++ b/src/acpica/source/components/utilities/utxferror.c
@@ -128,6 +128,8 @@
  * tools/applications.
  */
 
+#ifndef ACPI_NO_ERROR_MESSAGES /* Entire module */
+
 /*******************************************************************************
  *
  * FUNCTION:    AcpiError
@@ -362,3 +364,5 @@ AcpiBiosWarning (
 }
 
 ACPI_EXPORT_SYMBOL (AcpiBiosWarning)
+
+#endif /* ACPI_NO_ERROR_MESSAGES */
diff --git a/src/acpica/source/include/acdisasm.h b/src/acpica/source/include/acdisasm.h
index df8d2e7..049a95c 100644
--- a/src/acpica/source/include/acdisasm.h
+++ b/src/acpica/source/include/acdisasm.h
@@ -218,6 +218,7 @@ typedef enum
     ACPI_DMT_HESTNTFY,
     ACPI_DMT_HESTNTYP,
     ACPI_DMT_IVRS,
+    ACPI_DMT_LPIT,
     ACPI_DMT_MADT,
     ACPI_DMT_PCCT,
     ACPI_DMT_PMTT,
@@ -355,6 +356,9 @@ extern ACPI_DMTABLE_INFO        AcpiDmTableInfoHest9[];
 extern ACPI_DMTABLE_INFO        AcpiDmTableInfoHestNotify[];
 extern ACPI_DMTABLE_INFO        AcpiDmTableInfoHestBank[];
 extern ACPI_DMTABLE_INFO        AcpiDmTableInfoHpet[];
+extern ACPI_DMTABLE_INFO        AcpiDmTableInfoLpitHdr[];
+extern ACPI_DMTABLE_INFO        AcpiDmTableInfoLpit0[];
+extern ACPI_DMTABLE_INFO        AcpiDmTableInfoLpit1[];
 extern ACPI_DMTABLE_INFO        AcpiDmTableInfoIvrs[];
 extern ACPI_DMTABLE_INFO        AcpiDmTableInfoIvrs0[];
 extern ACPI_DMTABLE_INFO        AcpiDmTableInfoIvrs1[];
@@ -521,6 +525,10 @@ AcpiDmDumpIvrs (
     ACPI_TABLE_HEADER       *Table);
 
 void
+AcpiDmDumpLpit (
+    ACPI_TABLE_HEADER       *Table);
+
+void
 AcpiDmDumpMadt (
     ACPI_TABLE_HEADER       *Table);
 
diff --git a/src/acpica/source/include/acevents.h b/src/acpica/source/include/acevents.h
index 731defb..8ca726c 100644
--- a/src/acpica/source/include/acevents.h
+++ b/src/acpica/source/include/acevents.h
@@ -216,9 +216,10 @@ AcpiEvFinishGpe (
 ACPI_STATUS
 AcpiEvCreateGpeBlock (
     ACPI_NAMESPACE_NODE     *GpeDevice,
-    ACPI_GENERIC_ADDRESS    *GpeBlockAddress,
+    UINT64                  Address,
+    UINT8                   SpaceId,
     UINT32                  RegisterCount,
-    UINT8                   GpeBlockBaseNumber,
+    UINT16                  GpeBlockBaseNumber,
     UINT32                  InterruptNumber,
     ACPI_GPE_BLOCK_INFO     **ReturnGpeBlock);
 
diff --git a/src/acpica/source/include/acglobal.h b/src/acpica/source/include/acglobal.h
index a3ae36a..d16a23d 100644
--- a/src/acpica/source/include/acglobal.h
+++ b/src/acpica/source/include/acglobal.h
@@ -117,146 +117,14 @@
 #define __ACGLOBAL_H__
 
 
-/*
- * Ensure that the globals are actually defined and initialized only once.
- *
- * The use of these macros allows a single list of globals (here) in order
- * to simplify maintenance of the code.
- */
-#ifdef DEFINE_ACPI_GLOBALS
-#define ACPI_GLOBAL(type,name) \
-    extern type name; \
-    type name
-
-#define ACPI_INIT_GLOBAL(type,name,value) \
-    type name=value
-
-#else
-#define ACPI_GLOBAL(type,name) \
-    extern type name
-
-#define ACPI_INIT_GLOBAL(type,name,value) \
-    extern type name
-#endif
-
-
-#ifdef DEFINE_ACPI_GLOBALS
-
-/* Public globals, available from outside ACPICA subsystem */
-
 /*****************************************************************************
  *
- * Runtime configuration (static defaults that can be overriden at runtime)
+ * Globals related to the ACPI tables
  *
  ****************************************************************************/
 
-/*
- * Enable "slack" in the AML interpreter?  Default is FALSE, and the
- * interpreter strictly follows the ACPI specification. Setting to TRUE
- * allows the interpreter to ignore certain errors and/or bad AML constructs.
- *
- * Currently, these features are enabled by this flag:
- *
- * 1) Allow "implicit return" of last value in a control method
- * 2) Allow access beyond the end of an operation region
- * 3) Allow access to uninitialized locals/args (auto-init to integer 0)
- * 4) Allow ANY object type to be a source operand for the Store() operator
- * 5) Allow unresolved references (invalid target name) in package objects
- * 6) Enable warning messages for behavior that is not ACPI spec compliant
- */
-ACPI_INIT_GLOBAL (UINT8,                AcpiGbl_EnableInterpreterSlack, FALSE);
-
-/*
- * 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.
- */
-ACPI_INIT_GLOBAL (UINT8,                AcpiGbl_AutoSerializeMethods, TRUE);
-
-/*
- * Create the predefined _OSI method in the namespace? Default is TRUE
- * because ACPICA is fully compatible with other ACPI implementations.
- * Changing this will revert ACPICA (and machine ASL) to pre-OSI behavior.
- */
-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.
- */
-ACPI_INIT_GLOBAL (UINT8,                AcpiGbl_UseDefaultRegisterWidths, TRUE);
-
-/*
- * Optionally enable output from the AML Debug Object.
- */
-ACPI_INIT_GLOBAL (UINT8,                AcpiGbl_EnableAmlDebugObject, FALSE);
-
-/*
- * Optionally copy the entire DSDT to local memory (instead of simply
- * mapping it.) There are some BIOSs that corrupt or replace the original
- * DSDT, creating the need for this option. Default is FALSE, do not copy
- * the DSDT.
- */
-ACPI_INIT_GLOBAL (UINT8,                AcpiGbl_CopyDsdtLocally, FALSE);
+/* Master list of all ACPI tables that were found in the RSDT/XSDT */
 
-/*
- * Optionally ignore an XSDT if present and use the RSDT instead.
- * Although the ACPI specification requires that an XSDT be used instead
- * 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.
- */
-ACPI_INIT_GLOBAL (UINT8,                AcpiGbl_DoNotUseXsdt, FALSE);
-
-/*
- * Optionally use 32-bit FADT addresses if and when there is a conflict
- * (address mismatch) between the 32-bit and 64-bit versions of the
- * address. Although ACPICA adheres to the ACPI specification which
- * requires the use of the corresponding 64-bit address if it is non-zero,
- * some machines have been found to have a corrupted non-zero 64-bit
- * address. Default is FALSE, do not favor the 32-bit addresses.
- */
-ACPI_INIT_GLOBAL (UINT8,                AcpiGbl_Use32BitFadtAddresses, FALSE);
-
-/*
- * Optionally truncate I/O addresses to 16 bits. Provides compatibility
- * with other ACPI implementations. NOTE: During ACPICA initialization,
- * this value is set to TRUE if any Windows OSI strings have been
- * requested by the BIOS.
- */
-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.
- */
-ACPI_INIT_GLOBAL (UINT8,                AcpiGbl_DisableAutoRepair, FALSE);
-
-/*
- * Optionally do not install any SSDTs from the RSDT/XSDT during initialization.
- * This can be useful for debugging ACPI problems on some machines.
- */
-ACPI_INIT_GLOBAL (UINT8,                AcpiGbl_DisableSsdtTableInstall, FALSE);
-
-/*
- * We keep track of the latest version of Windows that has been requested by
- * the BIOS.
- */
-ACPI_INIT_GLOBAL (UINT8,                AcpiGbl_OsiData, 0);
-
-#endif /* DEFINE_ACPI_GLOBALS */
-
-
-/*****************************************************************************
- *
- * ACPI Table globals
- *
- ****************************************************************************/
-
-/*
- * Master list of all ACPI tables that were found in the RSDT/XSDT.
- */
 ACPI_GLOBAL (ACPI_TABLE_LIST,           AcpiGbl_RootTableList);
 
 /* DSDT information. Used to check for DSDT corruption */
@@ -356,7 +224,6 @@ 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);
 
@@ -373,7 +240,6 @@ ACPI_GLOBAL (BOOLEAN,                   AcpiGbl_RegMethodsExecuted);
 /* Misc */
 
 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);
@@ -561,11 +427,6 @@ 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 */
 
 
diff --git a/src/acpica/source/include/aclocal.h b/src/acpica/source/include/aclocal.h
index 147d0fb..12925a8 100644
--- a/src/acpica/source/include/aclocal.h
+++ b/src/acpica/source/include/aclocal.h
@@ -588,9 +588,9 @@ typedef struct acpi_gpe_register_info
 {
     ACPI_GENERIC_ADDRESS            StatusAddress;  /* Address of status reg */
     ACPI_GENERIC_ADDRESS            EnableAddress;  /* Address of enable reg */
+    UINT16                          BaseGpeNumber;  /* Base GPE number for this register */
     UINT8                           EnableForWake;  /* GPEs to keep enabled when sleeping */
     UINT8                           EnableForRun;   /* GPEs to keep enabled when running */
-    UINT8                           BaseGpeNumber;  /* Base GPE number for this register */
 
 } ACPI_GPE_REGISTER_INFO;
 
@@ -606,10 +606,11 @@ typedef struct acpi_gpe_block_info
     struct acpi_gpe_xrupt_info      *XruptBlock;    /* Backpointer to interrupt block */
     ACPI_GPE_REGISTER_INFO          *RegisterInfo;  /* One per GPE register pair */
     ACPI_GPE_EVENT_INFO             *EventInfo;     /* One for each GPE */
-    ACPI_GENERIC_ADDRESS            BlockAddress;   /* Base address of the block */
+    UINT64                          Address;        /* Base address of the block */
     UINT32                          RegisterCount;  /* Number of register pairs in block */
     UINT16                          GpeCount;       /* Number of individual GPEs in block */
-    UINT8                           BlockBaseNumber;/* Base GPE number for this block */
+    UINT16                          BlockBaseNumber;/* Base GPE number for this block */
+    UINT8                           SpaceId;
     BOOLEAN                         Initialized;    /* TRUE if this block is initialized */
 
 } ACPI_GPE_BLOCK_INFO;
diff --git a/src/acpica/source/include/acnames.h b/src/acpica/source/include/acnames.h
index bde34f5..107c6c1 100644
--- a/src/acpica/source/include/acnames.h
+++ b/src/acpica/source/include/acnames.h
@@ -127,6 +127,7 @@
 #define METHOD_NAME__HID        "_HID"
 #define METHOD_NAME__INI        "_INI"
 #define METHOD_NAME__PLD        "_PLD"
+#define METHOD_NAME__PRP        "_PRP"
 #define METHOD_NAME__PRS        "_PRS"
 #define METHOD_NAME__PRT        "_PRT"
 #define METHOD_NAME__PRW        "_PRW"
diff --git a/src/acpica/source/include/acpixf.h b/src/acpica/source/include/acpixf.h
index 61125f1..ecb0442 100644
--- a/src/acpica/source/include/acpixf.h
+++ b/src/acpica/source/include/acpixf.h
@@ -113,64 +113,249 @@
  *
  *****************************************************************************/
 
-
 #ifndef __ACXFACE_H__
 #define __ACXFACE_H__
 
 /* Current ACPICA subsystem version in YYYYMMDD format */
 
-#define ACPI_CA_VERSION                 0x20140325
+#define ACPI_CA_VERSION                 0x20140424
 
 #include "acconfig.h"
 #include "actypes.h"
 #include "actbl.h"
 #include "acbuffer.h"
 
+
+/*****************************************************************************
+ *
+ * Macros used for ACPICA globals and configuration
+ *
+ ****************************************************************************/
+
+/*
+ * Ensure that global variables are defined and initialized only once.
+ *
+ * The use of these macros allows for a single list of globals (here)
+ * in order to simplify maintenance of the code.
+ */
+#ifdef DEFINE_ACPI_GLOBALS
+#define ACPI_GLOBAL(type,name) \
+    extern type name; \
+    type name
+
+#define ACPI_INIT_GLOBAL(type,name,value) \
+    type name=value
+
+#else
+#ifndef ACPI_GLOBAL
+#define ACPI_GLOBAL(type,name) \
+    extern type name
+#endif
+
+#ifndef ACPI_INIT_GLOBAL
+#define ACPI_INIT_GLOBAL(type,name,value) \
+    extern type name
+#endif
+#endif
+
+/*
+ * These macros configure the various ACPICA interfaces. They are
+ * useful for generating stub inline functions for features that are
+ * configured out of the current kernel or ACPICA application.
+ */
+#ifndef ACPI_EXTERNAL_RETURN_STATUS
+#define ACPI_EXTERNAL_RETURN_STATUS(Prototype) \
+    Prototype;
+#endif
+
+#ifndef ACPI_EXTERNAL_RETURN_OK
+#define ACPI_EXTERNAL_RETURN_OK(Prototype) \
+    Prototype;
+#endif
+
+#ifndef ACPI_EXTERNAL_RETURN_VOID
+#define ACPI_EXTERNAL_RETURN_VOID(Prototype) \
+    Prototype;
+#endif
+
+#ifndef ACPI_EXTERNAL_RETURN_UINT32
+#define ACPI_EXTERNAL_RETURN_UINT32(Prototype) \
+    Prototype;
+#endif
+
+#ifndef ACPI_EXTERNAL_RETURN_PTR
+#define ACPI_EXTERNAL_RETURN_PTR(Prototype) \
+    Prototype;
+#endif
+
+
+/*****************************************************************************
+ *
+ * Public globals and runtime configuration options
+ *
+ ****************************************************************************/
+
+/*
+ * Enable "slack mode" of the AML interpreter?  Default is FALSE, and the
+ * interpreter strictly follows the ACPI specification. Setting to TRUE
+ * allows the interpreter to ignore certain errors and/or bad AML constructs.
+ *
+ * Currently, these features are enabled by this flag:
+ *
+ * 1) Allow "implicit return" of last value in a control method
+ * 2) Allow access beyond the end of an operation region
+ * 3) Allow access to uninitialized locals/args (auto-init to integer 0)
+ * 4) Allow ANY object type to be a source operand for the Store() operator
+ * 5) Allow unresolved references (invalid target name) in package objects
+ * 6) Enable warning messages for behavior that is not ACPI spec compliant
+ */
+ACPI_INIT_GLOBAL (UINT8,            AcpiGbl_EnableInterpreterSlack, FALSE);
+
+/*
+ * 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.
+ */
+ACPI_INIT_GLOBAL (UINT8,            AcpiGbl_AutoSerializeMethods, TRUE);
+
+/*
+ * Create the predefined _OSI method in the namespace? Default is TRUE
+ * because ACPICA is fully compatible with other ACPI implementations.
+ * Changing this will revert ACPICA (and machine ASL) to pre-OSI behavior.
+ */
+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.
+ */
+ACPI_INIT_GLOBAL (UINT8,            AcpiGbl_UseDefaultRegisterWidths, TRUE);
+
+/*
+ * Optionally enable output from the AML Debug Object.
+ */
+ACPI_INIT_GLOBAL (UINT8,            AcpiGbl_EnableAmlDebugObject, FALSE);
+
+/*
+ * Optionally copy the entire DSDT to local memory (instead of simply
+ * mapping it.) There are some BIOSs that corrupt or replace the original
+ * DSDT, creating the need for this option. Default is FALSE, do not copy
+ * the DSDT.
+ */
+ACPI_INIT_GLOBAL (UINT8,            AcpiGbl_CopyDsdtLocally, FALSE);
+
+/*
+ * Optionally ignore an XSDT if present and use the RSDT instead.
+ * Although the ACPI specification requires that an XSDT be used instead
+ * 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.
+ */
+ACPI_INIT_GLOBAL (UINT8,            AcpiGbl_DoNotUseXsdt, FALSE);
+
+/*
+ * Optionally use 32-bit FADT addresses if and when there is a conflict
+ * (address mismatch) between the 32-bit and 64-bit versions of the
+ * address. Although ACPICA adheres to the ACPI specification which
+ * requires the use of the corresponding 64-bit address if it is non-zero,
+ * some machines have been found to have a corrupted non-zero 64-bit
+ * address. Default is FALSE, do not favor the 32-bit addresses.
+ */
+ACPI_INIT_GLOBAL (UINT8,            AcpiGbl_Use32BitFadtAddresses, FALSE);
+
+/*
+ * Optionally truncate I/O addresses to 16 bits. Provides compatibility
+ * with other ACPI implementations. NOTE: During ACPICA initialization,
+ * this value is set to TRUE if any Windows OSI strings have been
+ * requested by the BIOS.
+ */
+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.
+ */
+ACPI_INIT_GLOBAL (UINT8,            AcpiGbl_DisableAutoRepair, FALSE);
+
 /*
- * Globals that are publically available
+ * Optionally do not install any SSDTs from the RSDT/XSDT during initialization.
+ * This can be useful for debugging ACPI problems on some machines.
  */
-extern UINT32               AcpiCurrentGpeCount;
-extern ACPI_TABLE_FADT      AcpiGbl_FADT;
-extern BOOLEAN              AcpiGbl_SystemAwakeAndRunning;
-extern BOOLEAN              AcpiGbl_ReducedHardware;        /* ACPI 5.0 */
-extern UINT8                AcpiGbl_OsiData;
+ACPI_INIT_GLOBAL (UINT8,            AcpiGbl_DisableSsdtTableInstall, FALSE);
 
-/* Runtime configuration of debug print levels */
+/*
+ * We keep track of the latest version of Windows that has been requested by
+ * the BIOS. ACPI 5.0.
+ */
+ACPI_INIT_GLOBAL (UINT8,            AcpiGbl_OsiData, 0);
 
-extern UINT32               AcpiDbgLevel;
-extern UINT32               AcpiDbgLayer;
+/*
+ * 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.
+ */
+ACPI_INIT_GLOBAL (BOOLEAN,          AcpiGbl_ReducedHardware, FALSE);
 
-/* ACPICA runtime options */
+/*
+ * This mechanism is used to trace a specified AML method. The method is
+ * traced each time it is executed.
+ */
+ACPI_INIT_GLOBAL (UINT32,           AcpiGbl_TraceFlags, 0);
+ACPI_INIT_GLOBAL (ACPI_NAME,        AcpiGbl_TraceMethodName, 0);
 
-extern UINT8                AcpiGbl_AutoSerializeMethods;
-extern UINT8                AcpiGbl_CopyDsdtLocally;
-extern UINT8                AcpiGbl_CreateOsiMethod;
-extern UINT8                AcpiGbl_DisableAutoRepair;
-extern UINT8                AcpiGbl_DisableSsdtTableInstall;
-extern UINT8                AcpiGbl_DoNotUseXsdt;
-extern UINT8                AcpiGbl_EnableAmlDebugObject;
-extern UINT8                AcpiGbl_EnableInterpreterSlack;
-extern UINT32               AcpiGbl_TraceFlags;
-extern ACPI_NAME            AcpiGbl_TraceMethodName;
-extern UINT8                AcpiGbl_TruncateIoAddresses;
-extern UINT8                AcpiGbl_Use32BitFadtAddresses;
-extern UINT8                AcpiGbl_UseDefaultRegisterWidths;
+/*
+ * Runtime configuration of debug output control masks. We want the debug
+ * switches statically initialized so they are already set when the debugger
+ * is entered.
+ */
+#ifdef ACPI_DEBUG_OUTPUT
+ACPI_INIT_GLOBAL (UINT32,           AcpiDbgLevel, ACPI_DEBUG_DEFAULT);
+#else
+ACPI_INIT_GLOBAL (UINT32,           AcpiDbgLevel, ACPI_NORMAL_DEFAULT);
+#endif
+ACPI_INIT_GLOBAL (UINT32,           AcpiDbgLayer, ACPI_COMPONENT_DEFAULT);
+
+/*
+ * Other miscellaneous globals
+ */
+ACPI_GLOBAL (ACPI_TABLE_FADT,       AcpiGbl_FADT);
+ACPI_GLOBAL (UINT32,                AcpiCurrentGpeCount);
+ACPI_GLOBAL (BOOLEAN,               AcpiGbl_SystemAwakeAndRunning);
 
 
+/*****************************************************************************
+ *
+ * ACPICA public interface configuration.
+ *
+ * Interfaces that are configured out of the ACPICA build are replaced
+ * by inlined stubs by default.
+ *
+ ****************************************************************************/
+
 /*
- * Hardware-reduced prototypes. All interfaces that use these macros will
- * be configured out of the ACPICA build if the ACPI_REDUCED_HARDWARE flag
+ * Hardware-reduced prototypes (default: Not hardware reduced).
+ *
+ * All ACPICA hardware-related interfaces that use these macros will be
+ * configured out of the ACPICA build if the ACPI_REDUCED_HARDWARE flag
  * is set to TRUE.
+ *
+ * Note: This static build option for reduced hardware is intended to
+ * reduce ACPICA code size if desired or necessary. However, even if this
+ * option is not specified, the runtime behavior of ACPICA is dependent
+ * on the actual FADT reduced hardware flag (HW_REDUCED_ACPI). If set,
+ * the flag will enable similar behavior -- ACPICA will not attempt
+ * to access any ACPI-relate hardware (SCI, GPEs, Fixed Events, etc.)
  */
 #if (!ACPI_REDUCED_HARDWARE)
 #define ACPI_HW_DEPENDENT_RETURN_STATUS(Prototype) \
-    Prototype;
+    ACPI_EXTERNAL_RETURN_STATUS(Prototype)
 
 #define ACPI_HW_DEPENDENT_RETURN_OK(Prototype) \
-    Prototype;
+    ACPI_EXTERNAL_RETURN_OK(Prototype)
 
 #define ACPI_HW_DEPENDENT_RETURN_VOID(Prototype) \
-    Prototype;
+    ACPI_EXTERNAL_RETURN_VOID(Prototype)
 
 #else
 #define ACPI_HW_DEPENDENT_RETURN_STATUS(Prototype) \
@@ -186,29 +371,76 @@ extern UINT8                AcpiGbl_UseDefaultRegisterWidths;
 
 
 /*
+ * Error message prototypes (default: error messages enabled).
+ *
+ * All interfaces related to error and warning messages
+ * will be configured out of the ACPICA build if the
+ * ACPI_NO_ERROR_MESSAGE flag is defined.
+ */
+#ifndef ACPI_NO_ERROR_MESSAGES
+#define ACPI_MSG_DEPENDENT_RETURN_VOID(Prototype) \
+    Prototype;
+
+#else
+#define ACPI_MSG_DEPENDENT_RETURN_VOID(Prototype) \
+    static ACPI_INLINE Prototype {return;}
+
+#endif /* ACPI_NO_ERROR_MESSAGES */
+
+
+/*
+ * Debugging output prototypes (default: no debug output).
+ *
+ * All interfaces related to debug output messages
+ * will be configured out of the ACPICA build unless the
+ * ACPI_DEBUG_OUTPUT flag is defined.
+ */
+#ifdef ACPI_DEBUG_OUTPUT
+#define ACPI_DBG_DEPENDENT_RETURN_VOID(Prototype) \
+    Prototype;
+
+#else
+#define ACPI_DBG_DEPENDENT_RETURN_VOID(Prototype) \
+    static ACPI_INLINE Prototype {return;}
+
+#endif /* ACPI_DEBUG_OUTPUT */
+
+
+/*****************************************************************************
+ *
+ * ACPICA public interface prototypes
+ *
+ ****************************************************************************/
+
+/*
  * Initialization
  */
+ACPI_EXTERNAL_RETURN_STATUS (
 ACPI_STATUS
 AcpiInitializeTables (
     ACPI_TABLE_DESC         *InitialStorage,
     UINT32                  InitialTableCount,
-    BOOLEAN                 AllowResize);
+    BOOLEAN                 AllowResize))
 
+ACPI_EXTERNAL_RETURN_STATUS (
 ACPI_STATUS
 AcpiInitializeSubsystem (
-    void);
+    void))
 
+ACPI_EXTERNAL_RETURN_STATUS (
 ACPI_STATUS
 AcpiEnableSubsystem (
-    UINT32                  Flags);
+    UINT32                  Flags))
 
+ACPI_EXTERNAL_RETURN_STATUS (
 ACPI_STATUS
 AcpiInitializeObjects (
-    UINT32                  Flags);
+    UINT32                  Flags))
 
+ACPI_EXTERNAL_RETURN_STATUS (
 ACPI_STATUS
 AcpiTerminate (
-    void);
+    void))
 
 
 /*
@@ -224,114 +456,136 @@ ACPI_STATUS
 AcpiDisable (
     void))
 
+ACPI_EXTERNAL_RETURN_STATUS (
 ACPI_STATUS
 AcpiSubsystemStatus (
-    void);
+    void))
 
+ACPI_EXTERNAL_RETURN_STATUS (
 ACPI_STATUS
 AcpiGetSystemInfo (
-    ACPI_BUFFER             *RetBuffer);
+    ACPI_BUFFER             *RetBuffer))
 
+ACPI_EXTERNAL_RETURN_STATUS (
 ACPI_STATUS
 AcpiGetStatistics (
-    ACPI_STATISTICS         *Stats);
+    ACPI_STATISTICS         *Stats))
 
+ACPI_EXTERNAL_RETURN_PTR (
 const char *
 AcpiFormatException (
-    ACPI_STATUS             Exception);
+    ACPI_STATUS             Exception))
 
+ACPI_EXTERNAL_RETURN_STATUS (
 ACPI_STATUS
 AcpiPurgeCachedObjects (
-    void);
+    void))
 
+ACPI_EXTERNAL_RETURN_STATUS (
 ACPI_STATUS
 AcpiInstallInterface (
-    ACPI_STRING             InterfaceName);
+    ACPI_STRING             InterfaceName))
 
+ACPI_EXTERNAL_RETURN_STATUS (
 ACPI_STATUS
 AcpiRemoveInterface (
-    ACPI_STRING             InterfaceName);
+    ACPI_STRING             InterfaceName))
 
+ACPI_EXTERNAL_RETURN_STATUS (
 ACPI_STATUS
 AcpiUpdateInterfaces (
-    UINT8                   Action);
+    UINT8                   Action))
 
+ACPI_EXTERNAL_RETURN_UINT32 (
 UINT32
 AcpiCheckAddressRange (
     ACPI_ADR_SPACE_TYPE     SpaceId,
     ACPI_PHYSICAL_ADDRESS   Address,
     ACPI_SIZE               Length,
-    BOOLEAN                 Warn);
+    BOOLEAN                 Warn))
 
+ACPI_EXTERNAL_RETURN_STATUS (
 ACPI_STATUS
 AcpiDecodePldBuffer (
     UINT8                   *InBuffer,
     ACPI_SIZE               Length,
-    ACPI_PLD_INFO           **ReturnBuffer);
+    ACPI_PLD_INFO           **ReturnBuffer))
 
 
 /*
  * ACPI table load/unload interfaces
  */
+ACPI_EXTERNAL_RETURN_STATUS (
 ACPI_STATUS
 AcpiInstallTable (
     ACPI_PHYSICAL_ADDRESS   Address,
-    BOOLEAN                 Physical);
+    BOOLEAN                 Physical))
 
+ACPI_EXTERNAL_RETURN_STATUS (
 ACPI_STATUS
 AcpiLoadTable (
-    ACPI_TABLE_HEADER       *Table);
+    ACPI_TABLE_HEADER       *Table))
 
+ACPI_EXTERNAL_RETURN_STATUS (
 ACPI_STATUS
 AcpiUnloadParentTable (
-    ACPI_HANDLE             Object);
+    ACPI_HANDLE             Object))
 
+ACPI_EXTERNAL_RETURN_STATUS (
 ACPI_STATUS
 AcpiLoadTables (
-    void);
+    void))
 
 
 /*
  * ACPI table manipulation interfaces
  */
+ACPI_EXTERNAL_RETURN_STATUS (
 ACPI_STATUS
 AcpiReallocateRootTable (
-    void);
+    void))
 
+ACPI_EXTERNAL_RETURN_STATUS (
 ACPI_STATUS
 AcpiFindRootPointer (
-    ACPI_SIZE               *RsdpAddress);
+    ACPI_SIZE               *RsdpAddress))
 
+ACPI_EXTERNAL_RETURN_STATUS (
 ACPI_STATUS
 AcpiGetTableHeader (
     ACPI_STRING             Signature,
     UINT32                  Instance,
-    ACPI_TABLE_HEADER       *OutTableHeader);
+    ACPI_TABLE_HEADER       *OutTableHeader))
 
+ACPI_EXTERNAL_RETURN_STATUS (
 ACPI_STATUS
 AcpiGetTable (
     ACPI_STRING             Signature,
     UINT32                  Instance,
-    ACPI_TABLE_HEADER       **OutTable);
+    ACPI_TABLE_HEADER       **OutTable))
 
+ACPI_EXTERNAL_RETURN_STATUS (
 ACPI_STATUS
 AcpiGetTableByIndex (
     UINT32                  TableIndex,
-    ACPI_TABLE_HEADER       **OutTable);
+    ACPI_TABLE_HEADER       **OutTable))
 
+ACPI_EXTERNAL_RETURN_STATUS (
 ACPI_STATUS
 AcpiInstallTableHandler (
     ACPI_TABLE_HANDLER      Handler,
-    void                    *Context);
+    void                    *Context))
 
+ACPI_EXTERNAL_RETURN_STATUS (
 ACPI_STATUS
 AcpiRemoveTableHandler (
-    ACPI_TABLE_HANDLER      Handler);
+    ACPI_TABLE_HANDLER      Handler))
 
 
 /*
  * Namespace and name interfaces
  */
+ACPI_EXTERNAL_RETURN_STATUS (
 ACPI_STATUS
 AcpiWalkNamespace (
     ACPI_OBJECT_TYPE        Type,
@@ -340,104 +594,119 @@ AcpiWalkNamespace (
     ACPI_WALK_CALLBACK      DescendingCallback,
     ACPI_WALK_CALLBACK      AscendingCallback,
     void                    *Context,
-    void                    **ReturnValue);
+    void                    **ReturnValue))
 
+ACPI_EXTERNAL_RETURN_STATUS (
 ACPI_STATUS
 AcpiGetDevices (
     char                    *HID,
     ACPI_WALK_CALLBACK      UserFunction,
     void                    *Context,
-    void                    **ReturnValue);
+    void                    **ReturnValue))
 
+ACPI_EXTERNAL_RETURN_STATUS (
 ACPI_STATUS
 AcpiGetName (
     ACPI_HANDLE             Object,
     UINT32                  NameType,
-    ACPI_BUFFER             *RetPathPtr);
+    ACPI_BUFFER             *RetPathPtr))
 
+ACPI_EXTERNAL_RETURN_STATUS (
 ACPI_STATUS
 AcpiGetHandle (
     ACPI_HANDLE             Parent,
     ACPI_STRING             Pathname,
-    ACPI_HANDLE             *RetHandle);
+    ACPI_HANDLE             *RetHandle))
 
+ACPI_EXTERNAL_RETURN_STATUS (
 ACPI_STATUS
 AcpiAttachData (
     ACPI_HANDLE             Object,
     ACPI_OBJECT_HANDLER     Handler,
-    void                    *Data);
+    void                    *Data))
 
+ACPI_EXTERNAL_RETURN_STATUS (
 ACPI_STATUS
 AcpiDetachData (
     ACPI_HANDLE             Object,
-    ACPI_OBJECT_HANDLER     Handler);
+    ACPI_OBJECT_HANDLER     Handler))
 
+ACPI_EXTERNAL_RETURN_STATUS (
 ACPI_STATUS
 AcpiGetData (
     ACPI_HANDLE             Object,
     ACPI_OBJECT_HANDLER     Handler,
-    void                    **Data);
+    void                    **Data))
 
+ACPI_EXTERNAL_RETURN_STATUS (
 ACPI_STATUS
 AcpiDebugTrace (
     char                    *Name,
     UINT32                  DebugLevel,
     UINT32                  DebugLayer,
-    UINT32                  Flags);
+    UINT32                  Flags))
 
 
 /*
  * Object manipulation and enumeration
  */
+ACPI_EXTERNAL_RETURN_STATUS (
 ACPI_STATUS
 AcpiEvaluateObject (
     ACPI_HANDLE             Object,
     ACPI_STRING             Pathname,
     ACPI_OBJECT_LIST        *ParameterObjects,
-    ACPI_BUFFER             *ReturnObjectBuffer);
+    ACPI_BUFFER             *ReturnObjectBuffer))
 
+ACPI_EXTERNAL_RETURN_STATUS (
 ACPI_STATUS
 AcpiEvaluateObjectTyped (
     ACPI_HANDLE             Object,
     ACPI_STRING             Pathname,
     ACPI_OBJECT_LIST        *ExternalParams,
     ACPI_BUFFER             *ReturnBuffer,
-    ACPI_OBJECT_TYPE        ReturnType);
+    ACPI_OBJECT_TYPE        ReturnType))
 
+ACPI_EXTERNAL_RETURN_STATUS (
 ACPI_STATUS
 AcpiGetObjectInfo (
     ACPI_HANDLE             Object,
-    ACPI_DEVICE_INFO        **ReturnBuffer);
+    ACPI_DEVICE_INFO        **ReturnBuffer))
 
+ACPI_EXTERNAL_RETURN_STATUS (
 ACPI_STATUS
 AcpiInstallMethod (
-    UINT8                   *Buffer);
+    UINT8                   *Buffer))
 
+ACPI_EXTERNAL_RETURN_STATUS (
 ACPI_STATUS
 AcpiGetNextObject (
     ACPI_OBJECT_TYPE        Type,
     ACPI_HANDLE             Parent,
     ACPI_HANDLE             Child,
-    ACPI_HANDLE             *OutHandle);
+    ACPI_HANDLE             *OutHandle))
 
+ACPI_EXTERNAL_RETURN_STATUS (
 ACPI_STATUS
 AcpiGetType (
     ACPI_HANDLE             Object,
-    ACPI_OBJECT_TYPE        *OutType);
+    ACPI_OBJECT_TYPE        *OutType))
 
+ACPI_EXTERNAL_RETURN_STATUS (
 ACPI_STATUS
 AcpiGetParent (
     ACPI_HANDLE             Object,
-    ACPI_HANDLE             *OutHandle);
+    ACPI_HANDLE             *OutHandle))
 
 
 /*
  * Handler interfaces
  */
+ACPI_EXTERNAL_RETURN_STATUS (
 ACPI_STATUS
 AcpiInstallInitializationHandler (
     ACPI_INIT_HANDLER       Handler,
-    UINT32                  Function);
+    UINT32                  Function))
 
 ACPI_HW_DEPENDENT_RETURN_STATUS (
 ACPI_STATUS
@@ -485,40 +754,46 @@ AcpiRemoveGpeHandler (
     UINT32                  GpeNumber,
     ACPI_GPE_HANDLER        Address))
 
+ACPI_EXTERNAL_RETURN_STATUS (
 ACPI_STATUS
 AcpiInstallNotifyHandler (
     ACPI_HANDLE             Device,
     UINT32                  HandlerType,
     ACPI_NOTIFY_HANDLER     Handler,
-    void                    *Context);
+    void                    *Context))
 
+ACPI_EXTERNAL_RETURN_STATUS (
 ACPI_STATUS
 AcpiRemoveNotifyHandler (
     ACPI_HANDLE             Device,
     UINT32                  HandlerType,
-    ACPI_NOTIFY_HANDLER     Handler);
+    ACPI_NOTIFY_HANDLER     Handler))
 
+ACPI_EXTERNAL_RETURN_STATUS (
 ACPI_STATUS
 AcpiInstallAddressSpaceHandler (
     ACPI_HANDLE             Device,
     ACPI_ADR_SPACE_TYPE     SpaceId,
     ACPI_ADR_SPACE_HANDLER  Handler,
     ACPI_ADR_SPACE_SETUP    Setup,
-    void                    *Context);
+    void                    *Context))
 
+ACPI_EXTERNAL_RETURN_STATUS (
 ACPI_STATUS
 AcpiRemoveAddressSpaceHandler (
     ACPI_HANDLE             Device,
     ACPI_ADR_SPACE_TYPE     SpaceId,
-    ACPI_ADR_SPACE_HANDLER  Handler);
+    ACPI_ADR_SPACE_HANDLER  Handler))
 
+ACPI_EXTERNAL_RETURN_STATUS (
 ACPI_STATUS
 AcpiInstallExceptionHandler (
-    ACPI_EXCEPTION_HANDLER  Handler);
+    ACPI_EXCEPTION_HANDLER  Handler))
 
+ACPI_EXTERNAL_RETURN_STATUS (
 ACPI_STATUS
 AcpiInstallInterfaceHandler (
-    ACPI_INTERFACE_HANDLER  Handler);
+    ACPI_INTERFACE_HANDLER  Handler))
 
 
 /*
@@ -539,16 +814,18 @@ AcpiReleaseGlobalLock (
 /*
  * Interfaces to AML mutex objects
  */
+ACPI_EXTERNAL_RETURN_STATUS (
 ACPI_STATUS
 AcpiAcquireMutex (
     ACPI_HANDLE             Handle,
     ACPI_STRING             Pathname,
-    UINT16                  Timeout);
+    UINT16                  Timeout))
 
+ACPI_EXTERNAL_RETURN_STATUS (
 ACPI_STATUS
 AcpiReleaseMutex (
     ACPI_HANDLE             Handle,
-    ACPI_STRING             Pathname);
+    ACPI_STRING             Pathname))
 
 
 /*
@@ -676,79 +953,92 @@ ACPI_STATUS (*ACPI_WALK_RESOURCE_CALLBACK) (
     ACPI_RESOURCE           *Resource,
     void                    *Context);
 
+ACPI_EXTERNAL_RETURN_STATUS (
 ACPI_STATUS
 AcpiGetVendorResource (
     ACPI_HANDLE             Device,
     char                    *Name,
     ACPI_VENDOR_UUID        *Uuid,
-    ACPI_BUFFER             *RetBuffer);
+    ACPI_BUFFER             *RetBuffer))
 
+ACPI_EXTERNAL_RETURN_STATUS (
 ACPI_STATUS
 AcpiGetCurrentResources (
     ACPI_HANDLE             Device,
-    ACPI_BUFFER             *RetBuffer);
+    ACPI_BUFFER             *RetBuffer))
 
+ACPI_EXTERNAL_RETURN_STATUS (
 ACPI_STATUS
 AcpiGetPossibleResources (
     ACPI_HANDLE             Device,
-    ACPI_BUFFER             *RetBuffer);
+    ACPI_BUFFER             *RetBuffer))
 
+ACPI_EXTERNAL_RETURN_STATUS (
 ACPI_STATUS
 AcpiGetEventResources (
     ACPI_HANDLE             DeviceHandle,
-    ACPI_BUFFER             *RetBuffer);
+    ACPI_BUFFER             *RetBuffer))
 
+ACPI_EXTERNAL_RETURN_STATUS (
 ACPI_STATUS
 AcpiWalkResourceBuffer (
     ACPI_BUFFER                 *Buffer,
     ACPI_WALK_RESOURCE_CALLBACK UserFunction,
-    void                        *Context);
+    void                        *Context))
 
+ACPI_EXTERNAL_RETURN_STATUS (
 ACPI_STATUS
 AcpiWalkResources (
     ACPI_HANDLE                 Device,
     char                        *Name,
     ACPI_WALK_RESOURCE_CALLBACK UserFunction,
-    void                        *Context);
+    void                        *Context))
 
+ACPI_EXTERNAL_RETURN_STATUS (
 ACPI_STATUS
 AcpiSetCurrentResources (
     ACPI_HANDLE             Device,
-    ACPI_BUFFER             *InBuffer);
+    ACPI_BUFFER             *InBuffer))
 
+ACPI_EXTERNAL_RETURN_STATUS (
 ACPI_STATUS
 AcpiGetIrqRoutingTable (
     ACPI_HANDLE             Device,
-    ACPI_BUFFER             *RetBuffer);
+    ACPI_BUFFER             *RetBuffer))
 
+ACPI_EXTERNAL_RETURN_STATUS (
 ACPI_STATUS
 AcpiResourceToAddress64 (
     ACPI_RESOURCE           *Resource,
-    ACPI_RESOURCE_ADDRESS64 *Out);
+    ACPI_RESOURCE_ADDRESS64 *Out))
 
+ACPI_EXTERNAL_RETURN_STATUS (
 ACPI_STATUS
 AcpiBufferToResource (
     UINT8                   *AmlBuffer,
     UINT16                  AmlBufferLength,
-    ACPI_RESOURCE           **ResourcePtr);
+    ACPI_RESOURCE           **ResourcePtr))
 
 
 /*
  * Hardware (ACPI device) interfaces
  */
+ACPI_EXTERNAL_RETURN_STATUS (
 ACPI_STATUS
 AcpiReset (
-    void);
+    void))
 
+ACPI_EXTERNAL_RETURN_STATUS (
 ACPI_STATUS
 AcpiRead (
     UINT64                  *Value,
-    ACPI_GENERIC_ADDRESS    *Reg);
+    ACPI_GENERIC_ADDRESS    *Reg))
 
+ACPI_EXTERNAL_RETURN_STATUS (
 ACPI_STATUS
 AcpiWrite (
     UINT64                  Value,
-    ACPI_GENERIC_ADDRESS    *Reg);
+    ACPI_GENERIC_ADDRESS    *Reg))
 
 ACPI_HW_DEPENDENT_RETURN_STATUS (
 ACPI_STATUS
@@ -766,32 +1056,37 @@ AcpiWriteBitRegister (
 /*
  * Sleep/Wake interfaces
  */
+ACPI_EXTERNAL_RETURN_STATUS (
 ACPI_STATUS
 AcpiGetSleepTypeData (
     UINT8                   SleepState,
     UINT8                   *Slp_TypA,
-    UINT8                   *Slp_TypB);
+    UINT8                   *Slp_TypB))
 
+ACPI_EXTERNAL_RETURN_STATUS (
 ACPI_STATUS
 AcpiEnterSleepStatePrep (
-    UINT8                   SleepState);
+    UINT8                   SleepState))
 
+ACPI_EXTERNAL_RETURN_STATUS (
 ACPI_STATUS
 AcpiEnterSleepState (
-    UINT8                   SleepState);
+    UINT8                   SleepState))
 
 ACPI_HW_DEPENDENT_RETURN_STATUS (
 ACPI_STATUS
 AcpiEnterSleepStateS4bios (
     void))
 
+ACPI_EXTERNAL_RETURN_STATUS (
 ACPI_STATUS
 AcpiLeaveSleepStatePrep (
-    UINT8                   SleepState);
+    UINT8                   SleepState))
 
+ACPI_EXTERNAL_RETURN_STATUS (
 ACPI_STATUS
 AcpiLeaveSleepState (
-    UINT8                   SleepState);
+    UINT8                   SleepState))
 
 ACPI_HW_DEPENDENT_RETURN_STATUS (
 ACPI_STATUS
@@ -830,14 +1125,16 @@ AcpiGetTimerDuration (
 /*
  * Error/Warning output
  */
+ACPI_MSG_DEPENDENT_RETURN_VOID (
 ACPI_PRINTF_LIKE(3)
 void ACPI_INTERNAL_VAR_XFACE
 AcpiError (
     const char              *ModuleName,
     UINT32                  LineNumber,
     const char              *Format,
-    ...);
+    ...))
 
+ACPI_MSG_DEPENDENT_RETURN_VOID (
 ACPI_PRINTF_LIKE(4)
 void  ACPI_INTERNAL_VAR_XFACE
 AcpiException (
@@ -845,46 +1142,49 @@ AcpiException (
     UINT32                  LineNumber,
     ACPI_STATUS             Status,
     const char              *Format,
-    ...);
+    ...))
 
+ACPI_MSG_DEPENDENT_RETURN_VOID (
 ACPI_PRINTF_LIKE(3)
 void ACPI_INTERNAL_VAR_XFACE
 AcpiWarning (
     const char              *ModuleName,
     UINT32                  LineNumber,
     const char              *Format,
-    ...);
+    ...))
 
+ACPI_MSG_DEPENDENT_RETURN_VOID (
 ACPI_PRINTF_LIKE(3)
 void ACPI_INTERNAL_VAR_XFACE
 AcpiInfo (
     const char              *ModuleName,
     UINT32                  LineNumber,
     const char              *Format,
-    ...);
+    ...))
 
+ACPI_MSG_DEPENDENT_RETURN_VOID (
 ACPI_PRINTF_LIKE(3)
 void ACPI_INTERNAL_VAR_XFACE
 AcpiBiosError (
     const char              *ModuleName,
     UINT32                  LineNumber,
     const char              *Format,
-    ...);
+    ...))
 
+ACPI_MSG_DEPENDENT_RETURN_VOID (
 ACPI_PRINTF_LIKE(3)
 void ACPI_INTERNAL_VAR_XFACE
 AcpiBiosWarning (
     const char              *ModuleName,
     UINT32                  LineNumber,
     const char              *Format,
-    ...);
+    ...))
 
 
 /*
  * Debug output
  */
-#ifdef ACPI_DEBUG_OUTPUT
-
+ACPI_DBG_DEPENDENT_RETURN_VOID (
 ACPI_PRINTF_LIKE(6)
 void ACPI_INTERNAL_VAR_XFACE
 AcpiDebugPrint (
@@ -894,8 +1194,9 @@ AcpiDebugPrint (
     const char              *ModuleName,
     UINT32                  ComponentId,
     const char              *Format,
-    ...);
+    ...))
 
+ACPI_DBG_DEPENDENT_RETURN_VOID (
 ACPI_PRINTF_LIKE(6)
 void ACPI_INTERNAL_VAR_XFACE
 AcpiDebugPrintRaw (
@@ -905,7 +1206,6 @@ AcpiDebugPrintRaw (
     const char              *ModuleName,
     UINT32                  ComponentId,
     const char              *Format,
-    ...);
-#endif
+    ...))
 
 #endif /* __ACXFACE_H__ */
diff --git a/src/acpica/source/include/acpredef.h b/src/acpica/source/include/acpredef.h
index 7e804f3..81ade10 100644
--- a/src/acpica/source/include/acpredef.h
+++ b/src/acpica/source/include/acpredef.h
@@ -652,6 +652,10 @@ const ACPI_PREDEFINED_INFO          AcpiGbl_PredefinedMethods[] =
     {{"_LID",   METHOD_0ARGS,
                 METHOD_RETURNS (ACPI_RTYPE_INTEGER)}},
 
+    {{"_LPD",   METHOD_0ARGS,
+                METHOD_RETURNS (ACPI_RTYPE_PACKAGE)}}, /* Variable-length (1 Int(rev), n Pkg (2 Int) */
+                    PACKAGE_INFO (ACPI_PTYPE2_REV_FIXED, ACPI_RTYPE_INTEGER, 2,0,0,0),
+
     {{"_MAT",   METHOD_0ARGS,
                 METHOD_RETURNS (ACPI_RTYPE_BUFFER)}},
 
diff --git a/src/acpica/source/include/actbl1.h b/src/acpica/source/include/actbl1.h
index 4710672..e0905ee 100644
--- a/src/acpica/source/include/actbl1.h
+++ b/src/acpica/source/include/actbl1.h
@@ -852,7 +852,7 @@ enum AcpiMadtType
 
 
 /*
- * MADT Sub-tables, correspond to Type in ACPI_SUBTABLE_HEADER
+ * MADT Subtables, correspond to Type in ACPI_SUBTABLE_HEADER
  */
 
 /* 0: Processor Local APIC */
@@ -1150,7 +1150,7 @@ enum AcpiSratType
 };
 
 /*
- * SRAT Sub-tables, correspond to Type in ACPI_SUBTABLE_HEADER
+ * SRAT Subtables, correspond to Type in ACPI_SUBTABLE_HEADER
  */
 
 /* 0: Processor Local APIC/SAPIC Affinity */
diff --git a/src/acpica/source/include/actbl2.h b/src/acpica/source/include/actbl2.h
index 2ae8ce3..7a64788 100644
--- a/src/acpica/source/include/actbl2.h
+++ b/src/acpica/source/include/actbl2.h
@@ -144,6 +144,7 @@
 #define ACPI_SIG_HPET           "HPET"      /* High Precision Event Timer table */
 #define ACPI_SIG_IBFT           "IBFT"      /* iSCSI Boot Firmware Table */
 #define ACPI_SIG_IVRS           "IVRS"      /* I/O Virtualization Reporting Structure */
+#define ACPI_SIG_LPIT           "LPIT"      /* Low Power Idle Table */
 #define ACPI_SIG_MCFG           "MCFG"      /* PCI Memory Mapped Configuration table */
 #define ACPI_SIG_MCHI           "MCHI"      /* Management Controller Host Interface table */
 #define ACPI_SIG_MTMR           "MTMR"      /* MID Timer table */
@@ -593,7 +594,7 @@ typedef struct acpi_dmar_pci_path
 
 
 /*
- * DMAR Sub-tables, correspond to Type in ACPI_DMAR_HEADER
+ * DMAR Subtables, correspond to Type in ACPI_DMAR_HEADER
  */
 
 /* 0: Hardware Unit Definition */
@@ -1006,7 +1007,83 @@ typedef struct acpi_ivrs_memory
 
 /*******************************************************************************
  *
- * MCFG - PCI Memory Mapped Configuration table and sub-table
+ * LPIT - Low Power Idle Table
+ *
+ * Conforms to "ACPI Low Power Idle Table (LPIT) and _LPD Proposal (DRAFT)"
+ *
+ ******************************************************************************/
+
+typedef struct acpi_table_lpit
+{
+    ACPI_TABLE_HEADER       Header;             /* Common ACPI table header */
+
+} ACPI_TABLE_LPIT;
+
+
+/* LPIT subtable header */
+
+typedef struct acpi_lpit_header
+{
+    UINT32                  Type;               /* Subtable type */
+    UINT32                  Length;             /* Subtable length */
+    UINT16                  UniqueId;
+    UINT16                  Reserved;
+    UINT32                  Flags;
+
+} ACPI_LPIT_HEADER;
+
+/* Values for subtable Type above */
+
+enum AcpiLpitType
+{
+    ACPI_LPIT_TYPE_NATIVE_CSTATE    = 0x00,
+    ACPI_LPIT_TYPE_SIMPLE_IO        = 0x01
+};
+
+/* Masks for Flags field above  */
+
+#define ACPI_LPIT_STATE_DISABLED    (1)
+#define ACPI_LPIT_NO_COUNTER        (1<<1)
+
+/*
+ * LPIT subtables, correspond to Type in ACPI_LPIT_HEADER
+ */
+
+/* 0x00: Native C-state instruction based LPI structure */
+
+typedef struct acpi_lpit_native
+{
+    ACPI_LPIT_HEADER        Header;
+    ACPI_GENERIC_ADDRESS    EntryTrigger;
+    UINT32                  Residency;
+    UINT32                  Latency;
+    ACPI_GENERIC_ADDRESS    ResidencyCounter;
+    UINT64                  CounterFrequency;
+
+} ACPI_LPIT_NATIVE;
+
+
+/* 0x01: Simple I/O based LPI structure */
+
+typedef struct acpi_lpit_io
+{
+    ACPI_LPIT_HEADER        Header;
+    ACPI_GENERIC_ADDRESS    EntryTrigger;
+    UINT32                  TriggerAction;
+    UINT64                  TriggerValue;
+    UINT64                  TriggerMask;
+    ACPI_GENERIC_ADDRESS    MinimumIdleState;
+    UINT32                  Residency;
+    UINT32                  Latency;
+    ACPI_GENERIC_ADDRESS    ResidencyCounter;
+    UINT64                  CounterFrequency;
+
+} ACPI_LPIT_IO;
+
+
+/*******************************************************************************
+ *
+ * MCFG - PCI Memory Mapped Configuration table and subtable
  *        Version 1
  *
  * Conforms to "PCI Firmware Specification", Revision 3.0, June 20, 2005
@@ -1130,7 +1207,7 @@ enum AcpiSlicType
 
 
 /*
- * SLIC Sub-tables, correspond to Type in ACPI_SLIC_HEADER
+ * SLIC Subtables, correspond to Type in ACPI_SLIC_HEADER
  */
 
 /* 0: Public Key Structure */
diff --git a/src/acpica/source/include/actypes.h b/src/acpica/source/include/actypes.h
index a02cd10..60613de 100644
--- a/src/acpica/source/include/actypes.h
+++ b/src/acpica/source/include/actypes.h
@@ -127,8 +127,6 @@
 #error ACPI_MACHINE_WIDTH not defined
 #endif
 
-/*! [Begin] no source code translation */
-
 /*
  * Data type ranges
  * Note: These macros are designed to be compiler independent as well as
@@ -196,13 +194,15 @@
  *
  ******************************************************************************/
 
+#ifndef ACPI_USE_SYSTEM_INTTYPES
+
 typedef unsigned char                   BOOLEAN;
 typedef unsigned char                   UINT8;
 typedef unsigned short                  UINT16;
 typedef COMPILER_DEPENDENT_UINT64       UINT64;
 typedef COMPILER_DEPENDENT_INT64        INT64;
 
-/*! [End] no source code translation !*/
+#endif /* ACPI_USE_SYSTEM_INTTYPES */
 
 /*
  * Value returned by AcpiOsGetThreadId. There is no standard "thread_id"
@@ -223,12 +223,12 @@ typedef COMPILER_DEPENDENT_INT64        INT64;
 
 #if ACPI_MACHINE_WIDTH == 64
 
-/*! [Begin] no source code translation (keep the typedefs as-is) */
+#ifndef ACPI_USE_SYSTEM_INTTYPES
 
 typedef unsigned int                    UINT32;
 typedef int                             INT32;
 
-/*! [End] no source code translation !*/
+#endif /* ACPI_USE_SYSTEM_INTTYPES */
 
 
 typedef INT64                           ACPI_NATIVE_INT;
@@ -262,12 +262,12 @@ typedef UINT64                          ACPI_PHYSICAL_ADDRESS;
 
 #elif ACPI_MACHINE_WIDTH == 32
 
-/*! [Begin] no source code translation (keep the typedefs as-is) */
+#ifndef ACPI_USE_SYSTEM_INTTYPES
 
 typedef unsigned int                    UINT32;
 typedef int                             INT32;
 
-/*! [End] no source code translation !*/
+#endif /* ACPI_USE_SYSTEM_INTTYPES */
 
 
 typedef INT32                           ACPI_NATIVE_INT;
@@ -406,6 +406,15 @@ typedef UINT32                          ACPI_PHYSICAL_ADDRESS;
  *
  ******************************************************************************/
 
+#ifdef ACPI_NO_MEM_ALLOCATIONS
+
+#define ACPI_ALLOCATE(a)                NULL
+#define ACPI_ALLOCATE_ZEROED(a)         NULL
+#define ACPI_FREE(a)
+#define ACPI_MEM_TRACKING(a)
+
+#else /* ACPI_NO_MEM_ALLOCATIONS */
+
 #ifdef ACPI_DBG_TRACK_ALLOCATIONS
 /*
  * Memory allocation tracking (used by AcpiExec to detect memory leaks)
@@ -427,6 +436,8 @@ typedef UINT32                          ACPI_PHYSICAL_ADDRESS;
 
 #endif /* ACPI_DBG_TRACK_ALLOCATIONS */
 
+#endif /* ACPI_NO_MEM_ALLOCATIONS */
+
 
 /******************************************************************************
  *
@@ -1026,9 +1037,19 @@ typedef struct acpi_object_list
  * Miscellaneous common Data Structures used by the interfaces
  */
 #define ACPI_NO_BUFFER              0
+
+#ifdef ACPI_NO_MEM_ALLOCATIONS
+
+#define ACPI_ALLOCATE_BUFFER        (ACPI_SIZE) (0)
+#define ACPI_ALLOCATE_LOCAL_BUFFER  (ACPI_SIZE) (0)
+
+#else /* ACPI_NO_MEM_ALLOCATIONS */
+
 #define ACPI_ALLOCATE_BUFFER        (ACPI_SIZE) (-1)    /* Let ACPICA allocate buffer */
 #define ACPI_ALLOCATE_LOCAL_BUFFER  (ACPI_SIZE) (-2)    /* For internal use only (enables tracking) */
 
+#endif /* ACPI_NO_MEM_ALLOCATIONS */
+
 typedef struct acpi_buffer
 {
     ACPI_SIZE                       Length;         /* Length in bytes of the buffer */
diff --git a/src/acpica/source/include/platform/aclinux.h b/src/acpica/source/include/platform/aclinux.h
index c7ca287..229aa84 100644
--- a/src/acpica/source/include/platform/aclinux.h
+++ b/src/acpica/source/include/platform/aclinux.h
@@ -125,6 +125,8 @@
 
 #ifdef __KERNEL__
 
+#define ACPI_USE_SYSTEM_INTTYPES
+
 #include <linux/string.h>
 #include <linux/kernel.h>
 #include <linux/ctype.h>
@@ -138,6 +140,37 @@
 #endif
 #include <asm/acpi.h>
 
+#ifndef CONFIG_ACPI
+
+/* External globals for __KERNEL__, stubs is needed */
+
+#define ACPI_GLOBAL(t,a)
+#define ACPI_INIT_GLOBAL(t,a,b)
+
+/* Generating stubs for configurable ACPICA macros */
+
+#define ACPI_NO_MEM_ALLOCATIONS
+
+/* Generating stubs for configurable ACPICA functions */
+
+#define ACPI_NO_ERROR_MESSAGES
+#undef ACPI_DEBUG_OUTPUT
+
+/* External interface for __KERNEL__, stub is needed */
+
+#define ACPI_EXTERNAL_RETURN_STATUS(Prototype) \
+    static ACPI_INLINE Prototype {return(AE_NOT_CONFIGURED);}
+#define ACPI_EXTERNAL_RETURN_OK(Prototype) \
+    static ACPI_INLINE Prototype {return(AE_OK);}
+#define ACPI_EXTERNAL_RETURN_VOID(Prototype) \
+    static ACPI_INLINE Prototype {return;}
+#define ACPI_EXTERNAL_RETURN_UINT32(Prototype) \
+    static ACPI_INLINE Prototype {return(0);}
+#define ACPI_EXTERNAL_RETURN_PTR(Prototype) \
+    static ACPI_INLINE Prototype {return(NULL);}
+
+#endif /* CONFIG_ACPI */
+
 /* Host-dependent types and defines for in-kernel ACPICA */
 
 #define ACPI_MACHINE_WIDTH          BITS_PER_LONG
diff --git a/src/acpica/source/os_specific/service_layers/osunixxf.c b/src/acpica/source/os_specific/service_layers/osunixxf.c
index 6c1f5e6..4d4fea2 100644
--- a/src/acpica/source/os_specific/service_layers/osunixxf.c
+++ b/src/acpica/source/os_specific/service_layers/osunixxf.c
@@ -165,6 +165,7 @@ typedef void* (*PTHREAD_CALLBACK) (void *);
 #include <termios.h>
 
 struct termios              OriginalTermAttributes;
+int                         TermAttributesWereSet = 0;
 
 ACPI_STATUS
 AcpiUtReadLine (
@@ -218,7 +219,7 @@ OsEnterLineEditMode (
 
     if (tcgetattr (STDIN_FILENO, &OriginalTermAttributes))
     {
-        fprintf (stderr, "Could not get/set terminal attributes!\n");
+        fprintf (stderr, "Could not get terminal attributes!\n");
         return;
     }
 
@@ -231,16 +232,32 @@ OsEnterLineEditMode (
     LocalTermAttributes.c_cc[VMIN] = 1;
     LocalTermAttributes.c_cc[VTIME] = 0;
 
-    tcsetattr (STDIN_FILENO, TCSANOW, &LocalTermAttributes);
+    if (tcsetattr (STDIN_FILENO, TCSANOW, &LocalTermAttributes))
+    {
+        fprintf (stderr, "Could not set terminal attributes!\n");
+        return;
+    }
+
+    TermAttributesWereSet = 1;
 }
 
+
 static void
 OsExitLineEditMode (
     void)
 {
+
+    if (!TermAttributesWereSet)
+    {
+        return;
+    }
+
     /* Set terminal attributes back to the original values */
 
-    tcsetattr (STDIN_FILENO, TCSANOW, &OriginalTermAttributes);
+    if (tcsetattr (STDIN_FILENO, TCSANOW, &OriginalTermAttributes))
+    {
+        fprintf (stderr, "Could not restore terminal attributes!\n");
+    }
 }
 
 
diff --git a/src/acpica/source/tools/acpiexec/aehandlers.c b/src/acpica/source/tools/acpiexec/aehandlers.c
index 79fe358..7fd63e2 100644
--- a/src/acpica/source/tools/acpiexec/aehandlers.c
+++ b/src/acpica/source/tools/acpiexec/aehandlers.c
@@ -623,7 +623,7 @@ AeGpeHandler (
     ACPI_NAMESPACE_NODE     *DeviceNode = (ACPI_NAMESPACE_NODE *) GpeDevice;
 
 
-    AcpiOsPrintf ("[AcpiExec] GPE Handler received GPE%02X (GPE block %4.4s)\n",
+    AcpiOsPrintf ("[AcpiExec] GPE Handler received GPE %02X (GPE block %4.4s)\n",
         GpeNumber, GpeDevice ? DeviceNode->Name.Ascii : "FADT");
 
     return (ACPI_REENABLE_GPE);
diff --git a/src/lib/include/fwts_iasl.h b/src/lib/include/fwts_iasl.h
index 5efc95c..f7e025b 100644
--- a/src/lib/include/fwts_iasl.h
+++ b/src/lib/include/fwts_iasl.h
@@ -21,6 +21,7 @@
 #define __IASL_H__
 
 #include "fwts.h"
+#include <stdint.h>
 
 int fwts_iasl_disassemble_all_to_file(fwts_framework *fw,
 	const char *path);
@@ -37,4 +38,6 @@ int fwts_iasl_reassemble(fwts_framework *fw,
 	fwts_list **iasl_stdout,
 	fwts_list **iasl_stderr);
 
+const char *fwts_iasl_exception_level(uint8_t level);
+
 #endif
diff --git a/src/lib/src/Makefile.am b/src/lib/src/Makefile.am
index 377e8aa..4ab52c1 100644
--- a/src/lib/src/Makefile.am
+++ b/src/lib/src/Makefile.am
@@ -12,7 +12,7 @@ libfwts_la_LDFLAGS = 			\
 	-L$(top_srcdir)/src/acpica/source/compiler \
 	-lfwtsiasl
 
-libfwts_la_CPPFLAGS = $(AM_CPPFLAGS)
+libfwts_la_CPPFLAGS = $(AM_CPPFLAGS) -DACPI_DEBUG_OUTPUT
 
 #
 #  Components of the fwts core helper library libfwts
diff --git a/src/lib/src/fwts_iasl.c b/src/lib/src/fwts_iasl.c
index 1800912..33debab 100644
--- a/src/lib/src/fwts_iasl.c
+++ b/src/lib/src/fwts_iasl.c
@@ -238,3 +238,7 @@ int fwts_iasl_reassemble(fwts_framework *fw,
 	return FWTS_OK;
 }
 
+const char *fwts_iasl_exception_level(uint8_t level)
+{
+	return fwts_iasl_exception_level__(level);
+}
-- 
1.9.1




More information about the fwts-devel mailing list