diff options
Diffstat (limited to 'sys/contrib/dev/acpica/compiler')
100 files changed, 508 insertions, 124 deletions
diff --git a/sys/contrib/dev/acpica/compiler/aslallocate.c b/sys/contrib/dev/acpica/compiler/aslallocate.c index 57e538b534e5..4d0aef2b4142 100644 --- a/sys/contrib/dev/acpica/compiler/aslallocate.c +++ b/sys/contrib/dev/acpica/compiler/aslallocate.c @@ -8,7 +8,7 @@ * * 1. Copyright Notice * - * Some or all of this work - Copyright (c) 1999 - 2025, Intel Corp. + * Some or all of this work - Copyright (c) 1999 - 2026, Intel Corp. * All rights reserved. * * 2. License diff --git a/sys/contrib/dev/acpica/compiler/aslanalyze.c b/sys/contrib/dev/acpica/compiler/aslanalyze.c index 625611a630de..015119ba4e78 100644 --- a/sys/contrib/dev/acpica/compiler/aslanalyze.c +++ b/sys/contrib/dev/acpica/compiler/aslanalyze.c @@ -8,7 +8,7 @@ * * 1. Copyright Notice * - * Some or all of this work - Copyright (c) 1999 - 2025, Intel Corp. + * Some or all of this work - Copyright (c) 1999 - 2026, Intel Corp. * All rights reserved. * * 2. License diff --git a/sys/contrib/dev/acpica/compiler/aslascii.c b/sys/contrib/dev/acpica/compiler/aslascii.c index 1de3d763c765..700ad30045f2 100644 --- a/sys/contrib/dev/acpica/compiler/aslascii.c +++ b/sys/contrib/dev/acpica/compiler/aslascii.c @@ -8,7 +8,7 @@ * * 1. Copyright Notice * - * Some or all of this work - Copyright (c) 1999 - 2025, Intel Corp. + * Some or all of this work - Copyright (c) 1999 - 2026, Intel Corp. * All rights reserved. * * 2. License diff --git a/sys/contrib/dev/acpica/compiler/aslbtypes.c b/sys/contrib/dev/acpica/compiler/aslbtypes.c index 539cd7977b4e..a11b1f465d9e 100644 --- a/sys/contrib/dev/acpica/compiler/aslbtypes.c +++ b/sys/contrib/dev/acpica/compiler/aslbtypes.c @@ -8,7 +8,7 @@ * * 1. Copyright Notice * - * Some or all of this work - Copyright (c) 1999 - 2025, Intel Corp. + * Some or all of this work - Copyright (c) 1999 - 2026, Intel Corp. * All rights reserved. * * 2. License diff --git a/sys/contrib/dev/acpica/compiler/aslcache.c b/sys/contrib/dev/acpica/compiler/aslcache.c index 9f917ff32945..93309f90093f 100644 --- a/sys/contrib/dev/acpica/compiler/aslcache.c +++ b/sys/contrib/dev/acpica/compiler/aslcache.c @@ -8,7 +8,7 @@ * * 1. Copyright Notice * - * Some or all of this work - Copyright (c) 1999 - 2025, Intel Corp. + * Some or all of this work - Copyright (c) 1999 - 2026, Intel Corp. * All rights reserved. * * 2. License diff --git a/sys/contrib/dev/acpica/compiler/aslcodegen.c b/sys/contrib/dev/acpica/compiler/aslcodegen.c index 684c59f802e9..f329f3738f8b 100644 --- a/sys/contrib/dev/acpica/compiler/aslcodegen.c +++ b/sys/contrib/dev/acpica/compiler/aslcodegen.c @@ -8,7 +8,7 @@ * * 1. Copyright Notice * - * Some or all of this work - Copyright (c) 1999 - 2025, Intel Corp. + * Some or all of this work - Copyright (c) 1999 - 2026, Intel Corp. * All rights reserved. * * 2. License @@ -586,14 +586,16 @@ CgWriteTableHeader ( /* OEMID */ Child = Child->Asl.Next; - memcpy (AslGbl_TableHeader.OemId, Child->Asl.Value.String, - strlen (Child->Asl.Value.String)); + /* Bound copy to header field size to avoid overflow on malformed input */ + strncpy (AslGbl_TableHeader.OemId, Child->Asl.Value.String, + ACPI_OEM_ID_SIZE); /* OEM TableID */ Child = Child->Asl.Next; - memcpy (AslGbl_TableHeader.OemTableId, Child->Asl.Value.String, - strlen (Child->Asl.Value.String)); + /* Bound copy to header field size to avoid overflow on malformed input */ + strncpy (AslGbl_TableHeader.OemTableId, Child->Asl.Value.String, + ACPI_OEM_TABLE_ID_SIZE); /* OEM Revision */ diff --git a/sys/contrib/dev/acpica/compiler/aslcompile.c b/sys/contrib/dev/acpica/compiler/aslcompile.c index 6e8ce6aae2c9..696da41ba46d 100644 --- a/sys/contrib/dev/acpica/compiler/aslcompile.c +++ b/sys/contrib/dev/acpica/compiler/aslcompile.c @@ -8,7 +8,7 @@ * * 1. Copyright Notice * - * Some or all of this work - Copyright (c) 1999 - 2025, Intel Corp. + * Some or all of this work - Copyright (c) 1999 - 2026, Intel Corp. * All rights reserved. * * 2. License diff --git a/sys/contrib/dev/acpica/compiler/aslcompiler.h b/sys/contrib/dev/acpica/compiler/aslcompiler.h index d131b949252a..d877357d4345 100644 --- a/sys/contrib/dev/acpica/compiler/aslcompiler.h +++ b/sys/contrib/dev/acpica/compiler/aslcompiler.h @@ -8,7 +8,7 @@ * * 1. Copyright Notice * - * Some or all of this work - Copyright (c) 1999 - 2025, Intel Corp. + * Some or all of this work - Copyright (c) 1999 - 2026, Intel Corp. * All rights reserved. * * 2. License diff --git a/sys/contrib/dev/acpica/compiler/aslcompiler.l b/sys/contrib/dev/acpica/compiler/aslcompiler.l index 5e94f9626018..bde40db4c00e 100644 --- a/sys/contrib/dev/acpica/compiler/aslcompiler.l +++ b/sys/contrib/dev/acpica/compiler/aslcompiler.l @@ -9,7 +9,7 @@ * * 1. Copyright Notice * - * Some or all of this work - Copyright (c) 1999 - 2025, Intel Corp. + * Some or all of this work - Copyright (c) 1999 - 2026, Intel Corp. * All rights reserved. * * 2. License diff --git a/sys/contrib/dev/acpica/compiler/aslcstyle.y b/sys/contrib/dev/acpica/compiler/aslcstyle.y index 59a1abea1bee..6384a1e932d6 100644 --- a/sys/contrib/dev/acpica/compiler/aslcstyle.y +++ b/sys/contrib/dev/acpica/compiler/aslcstyle.y @@ -9,7 +9,7 @@ NoEcho(' * * 1. Copyright Notice * - * Some or all of this work - Copyright (c) 1999 - 2025, Intel Corp. + * Some or all of this work - Copyright (c) 1999 - 2026, Intel Corp. * All rights reserved. * * 2. License diff --git a/sys/contrib/dev/acpica/compiler/asldebug.c b/sys/contrib/dev/acpica/compiler/asldebug.c index 18b68dea6de0..bb5e0bbdb047 100644 --- a/sys/contrib/dev/acpica/compiler/asldebug.c +++ b/sys/contrib/dev/acpica/compiler/asldebug.c @@ -8,7 +8,7 @@ * * 1. Copyright Notice * - * Some or all of this work - Copyright (c) 1999 - 2025, Intel Corp. + * Some or all of this work - Copyright (c) 1999 - 2026, Intel Corp. * All rights reserved. * * 2. License diff --git a/sys/contrib/dev/acpica/compiler/asldefine.h b/sys/contrib/dev/acpica/compiler/asldefine.h index 89b6b8a69956..5f694efe40df 100644 --- a/sys/contrib/dev/acpica/compiler/asldefine.h +++ b/sys/contrib/dev/acpica/compiler/asldefine.h @@ -8,7 +8,7 @@ * * 1. Copyright Notice * - * Some or all of this work - Copyright (c) 1999 - 2025, Intel Corp. + * Some or all of this work - Copyright (c) 1999 - 2026, Intel Corp. * All rights reserved. * * 2. License diff --git a/sys/contrib/dev/acpica/compiler/aslerror.c b/sys/contrib/dev/acpica/compiler/aslerror.c index ff01bef7b4b7..6612af39fa94 100644 --- a/sys/contrib/dev/acpica/compiler/aslerror.c +++ b/sys/contrib/dev/acpica/compiler/aslerror.c @@ -8,7 +8,7 @@ * * 1. Copyright Notice * - * Some or all of this work - Copyright (c) 1999 - 2025, Intel Corp. + * Some or all of this work - Copyright (c) 1999 - 2026, Intel Corp. * All rights reserved. * * 2. License diff --git a/sys/contrib/dev/acpica/compiler/aslexternal.c b/sys/contrib/dev/acpica/compiler/aslexternal.c index e2f082593c5d..83ba04f573f5 100644 --- a/sys/contrib/dev/acpica/compiler/aslexternal.c +++ b/sys/contrib/dev/acpica/compiler/aslexternal.c @@ -8,7 +8,7 @@ * * 1. Copyright Notice * - * Some or all of this work - Copyright (c) 1999 - 2025, Intel Corp. + * Some or all of this work - Copyright (c) 1999 - 2026, Intel Corp. * All rights reserved. * * 2. License @@ -170,6 +170,10 @@ static void ExMoveExternals ( ACPI_PARSE_OBJECT *DefinitionBlockOp); +static void +ExRemoveOpFromTree ( + ACPI_PARSE_OBJECT *Op); + /******************************************************************************* * @@ -194,9 +198,14 @@ ExDoExternal ( ACPI_PARSE_OBJECT *ArgCountOp; ACPI_PARSE_OBJECT *TypeOp; ACPI_PARSE_OBJECT *ExternTypeOp = Op->Asl.Child->Asl.Next; + ACPI_PARSE_OBJECT *Existing; + ACPI_PARSE_OBJECT *NameOp = Op->Asl.Child; + ACPI_PARSE_OBJECT *ExistingNameOp; UINT32 ExternType; UINT8 ParamCount = ASL_EXTERNAL_METHOD_UNKNOWN_PARAMS; UINT32 ParamTypes[ACPI_METHOD_NUM_ARGS]; + char *NewPath = NULL; + char *ExistingPath; ExternType = AnMapObjTypeToBtype (ExternTypeOp); @@ -250,6 +259,53 @@ ExDoExternal ( ArgCountOp->Asl.Value.Integer = ParamCount; UtSetParseOpName (ArgCountOp); + /* + * Deduplicate identical External() declarations. The disassembler + * already collapses duplicates; mirror that behavior in the compiler + * so duplicate externals do not bloat emitted AML. + */ + + NewPath = NameOp->Asl.Namepath; + if (!NewPath && NameOp->Asl.Value.String) + { + (void) UtInternalizeName (NameOp->Asl.Value.String, &NewPath); + NameOp->Asl.Namepath = NewPath; + } + + Existing = AslGbl_ExternalsListHead; + while (Existing && NewPath) + { + ExistingNameOp = Existing->Asl.Child->Asl.Child; + ExistingPath = ExistingNameOp->Asl.Namepath; + if (!ExistingPath && ExistingNameOp->Asl.Value.String) + { + (void) UtInternalizeName (ExistingNameOp->Asl.Value.String, + &ExistingPath); + ExistingNameOp->Asl.Namepath = ExistingPath; + } + + if (ExistingPath && !strcmp (NewPath, ExistingPath)) + { + ACPI_PARSE_OBJECT *ExistingArgCount; + + /* Update arg count if this instance is more specific */ + + ExistingArgCount = Existing->Asl.Child->Asl.Child->Asl.Next->Asl.Next; + if ((ExternType == ACPI_BTYPE_METHOD) && + (ParamCount < ExistingArgCount->Asl.Value.Integer)) + { + ExistingArgCount->Asl.Value.Integer = ParamCount; + } + + /* Remove duplicate External node from the parse tree */ + + ExRemoveOpFromTree (Op); + return; + } + + Existing = Existing->Asl.Next; + } + /* Create new list node of arbitrary type */ ListOp = TrAllocateOp (PARSEOP_DEFAULT_ARG); @@ -282,6 +338,53 @@ ExDoExternal ( /******************************************************************************* * + * FUNCTION: ExRemoveOpFromTree + * + * PARAMETERS: Op - Parse op to remove from the tree + * + * RETURN: None + * + * DESCRIPTION: Unlink a parse op from its parent sibling list. Used to drop + * duplicate External() declarations before AML emission. + * + ******************************************************************************/ + +static void +ExRemoveOpFromTree ( + ACPI_PARSE_OBJECT *Op) +{ + ACPI_PARSE_OBJECT *Parent; + ACPI_PARSE_OBJECT *Child; + + + if (!Op || !Op->Asl.Parent) + { + return; + } + + Parent = Op->Asl.Parent; + Child = Parent->Asl.Child; + + if (Child == Op) + { + Parent->Asl.Child = Op->Asl.Next; + return; + } + + while (Child && Child->Asl.Next != Op) + { + Child = Child->Asl.Next; + } + + if (Child) + { + Child->Asl.Next = Op->Asl.Next; + } +} + + +/******************************************************************************* + * * FUNCTION: ExInsertArgCount * * PARAMETERS: Op - Op for a method invocation diff --git a/sys/contrib/dev/acpica/compiler/aslfileio.c b/sys/contrib/dev/acpica/compiler/aslfileio.c index 4bf18404b1f5..e3dfaa6ebf6e 100644 --- a/sys/contrib/dev/acpica/compiler/aslfileio.c +++ b/sys/contrib/dev/acpica/compiler/aslfileio.c @@ -8,7 +8,7 @@ * * 1. Copyright Notice * - * Some or all of this work - Copyright (c) 1999 - 2025, Intel Corp. + * Some or all of this work - Copyright (c) 1999 - 2026, Intel Corp. * All rights reserved. * * 2. License diff --git a/sys/contrib/dev/acpica/compiler/aslfiles.c b/sys/contrib/dev/acpica/compiler/aslfiles.c index 0cad8eff47e8..4528d17764f0 100644 --- a/sys/contrib/dev/acpica/compiler/aslfiles.c +++ b/sys/contrib/dev/acpica/compiler/aslfiles.c @@ -8,7 +8,7 @@ * * 1. Copyright Notice * - * Some or all of this work - Copyright (c) 1999 - 2025, Intel Corp. + * Some or all of this work - Copyright (c) 1999 - 2026, Intel Corp. * All rights reserved. * * 2. License diff --git a/sys/contrib/dev/acpica/compiler/aslfold.c b/sys/contrib/dev/acpica/compiler/aslfold.c index 89107297588b..ecf4c683b78b 100644 --- a/sys/contrib/dev/acpica/compiler/aslfold.c +++ b/sys/contrib/dev/acpica/compiler/aslfold.c @@ -8,7 +8,7 @@ * * 1. Copyright Notice * - * Some or all of this work - Copyright (c) 1999 - 2025, Intel Corp. + * Some or all of this work - Copyright (c) 1999 - 2026, Intel Corp. * All rights reserved. * * 2. License diff --git a/sys/contrib/dev/acpica/compiler/aslglobal.h b/sys/contrib/dev/acpica/compiler/aslglobal.h index c79758919f6f..0f2d5931cec8 100644 --- a/sys/contrib/dev/acpica/compiler/aslglobal.h +++ b/sys/contrib/dev/acpica/compiler/aslglobal.h @@ -8,7 +8,7 @@ * * 1. Copyright Notice * - * Some or all of this work - Copyright (c) 1999 - 2025, Intel Corp. + * Some or all of this work - Copyright (c) 1999 - 2026, Intel Corp. * All rights reserved. * * 2. License @@ -252,6 +252,7 @@ extern FILE *AslCompilerin; extern int DtParserdebug; extern int PrParserdebug; extern const ASL_MAPPING_ENTRY AslKeywordMapping[]; +extern const UINT32 AslKeywordMappingCount; extern char *AslCompilertext; extern char *DtCompilerParsertext; diff --git a/sys/contrib/dev/acpica/compiler/aslhelp.c b/sys/contrib/dev/acpica/compiler/aslhelp.c index fcec07e67e70..0f6421ceba97 100644 --- a/sys/contrib/dev/acpica/compiler/aslhelp.c +++ b/sys/contrib/dev/acpica/compiler/aslhelp.c @@ -8,7 +8,7 @@ * * 1. Copyright Notice * - * Some or all of this work - Copyright (c) 1999 - 2025, Intel Corp. + * Some or all of this work - Copyright (c) 1999 - 2026, Intel Corp. * All rights reserved. * * 2. License diff --git a/sys/contrib/dev/acpica/compiler/aslhelpers.y b/sys/contrib/dev/acpica/compiler/aslhelpers.y index cb13d1ebcfe7..728ea9bd810c 100644 --- a/sys/contrib/dev/acpica/compiler/aslhelpers.y +++ b/sys/contrib/dev/acpica/compiler/aslhelpers.y @@ -9,7 +9,7 @@ NoEcho(' * * 1. Copyright Notice * - * Some or all of this work - Copyright (c) 1999 - 2025, Intel Corp. + * Some or all of this work - Copyright (c) 1999 - 2026, Intel Corp. * All rights reserved. * * 2. License diff --git a/sys/contrib/dev/acpica/compiler/aslhex.c b/sys/contrib/dev/acpica/compiler/aslhex.c index 927e50f24c1d..e0d8831e2a4a 100644 --- a/sys/contrib/dev/acpica/compiler/aslhex.c +++ b/sys/contrib/dev/acpica/compiler/aslhex.c @@ -8,7 +8,7 @@ * * 1. Copyright Notice * - * Some or all of this work - Copyright (c) 1999 - 2025, Intel Corp. + * Some or all of this work - Copyright (c) 1999 - 2026, Intel Corp. * All rights reserved. * * 2. License diff --git a/sys/contrib/dev/acpica/compiler/aslkeywords.y b/sys/contrib/dev/acpica/compiler/aslkeywords.y index 7cb670e61bfb..bdd42231cf55 100644 --- a/sys/contrib/dev/acpica/compiler/aslkeywords.y +++ b/sys/contrib/dev/acpica/compiler/aslkeywords.y @@ -9,7 +9,7 @@ NoEcho(' * * 1. Copyright Notice * - * Some or all of this work - Copyright (c) 1999 - 2025, Intel Corp. + * Some or all of this work - Copyright (c) 1999 - 2026, Intel Corp. * All rights reserved. * * 2. License diff --git a/sys/contrib/dev/acpica/compiler/asllength.c b/sys/contrib/dev/acpica/compiler/asllength.c index 136ca5823001..e2acc91755b9 100644 --- a/sys/contrib/dev/acpica/compiler/asllength.c +++ b/sys/contrib/dev/acpica/compiler/asllength.c @@ -8,7 +8,7 @@ * * 1. Copyright Notice * - * Some or all of this work - Copyright (c) 1999 - 2025, Intel Corp. + * Some or all of this work - Copyright (c) 1999 - 2026, Intel Corp. * All rights reserved. * * 2. License diff --git a/sys/contrib/dev/acpica/compiler/asllisting.c b/sys/contrib/dev/acpica/compiler/asllisting.c index 2a6341bb59e1..3c76672f0bef 100644 --- a/sys/contrib/dev/acpica/compiler/asllisting.c +++ b/sys/contrib/dev/acpica/compiler/asllisting.c @@ -8,7 +8,7 @@ * * 1. Copyright Notice * - * Some or all of this work - Copyright (c) 1999 - 2025, Intel Corp. + * Some or all of this work - Copyright (c) 1999 - 2026, Intel Corp. * All rights reserved. * * 2. License diff --git a/sys/contrib/dev/acpica/compiler/asllistsup.c b/sys/contrib/dev/acpica/compiler/asllistsup.c index 3458e28062de..f173d80de95d 100644 --- a/sys/contrib/dev/acpica/compiler/asllistsup.c +++ b/sys/contrib/dev/acpica/compiler/asllistsup.c @@ -8,7 +8,7 @@ * * 1. Copyright Notice * - * Some or all of this work - Copyright (c) 1999 - 2025, Intel Corp. + * Some or all of this work - Copyright (c) 1999 - 2026, Intel Corp. * All rights reserved. * * 2. License diff --git a/sys/contrib/dev/acpica/compiler/aslload.c b/sys/contrib/dev/acpica/compiler/aslload.c index c88fb13aba78..8aa3dce5b655 100644 --- a/sys/contrib/dev/acpica/compiler/aslload.c +++ b/sys/contrib/dev/acpica/compiler/aslload.c @@ -8,7 +8,7 @@ * * 1. Copyright Notice * - * Some or all of this work - Copyright (c) 1999 - 2025, Intel Corp. + * Some or all of this work - Copyright (c) 1999 - 2026, Intel Corp. * All rights reserved. * * 2. License @@ -1406,6 +1406,8 @@ LdNamespace2Begin ( /* Save the target node within the alias node as well as type information */ + /* Mark as alias node and store target namespace node */ + Node->Flags |= ANOBJ_IS_ALIAS; Node->Object = ACPI_CAST_PTR (ACPI_OPERAND_OBJECT, TargetNode); Node->Type = TargetNode->Type; if (Node->Type == ACPI_TYPE_METHOD) diff --git a/sys/contrib/dev/acpica/compiler/asllookup.c b/sys/contrib/dev/acpica/compiler/asllookup.c index 3dfdb1fce21e..c5885ea85786 100644 --- a/sys/contrib/dev/acpica/compiler/asllookup.c +++ b/sys/contrib/dev/acpica/compiler/asllookup.c @@ -8,7 +8,7 @@ * * 1. Copyright Notice * - * Some or all of this work - Copyright (c) 1999 - 2025, Intel Corp. + * Some or all of this work - Copyright (c) 1999 - 2026, Intel Corp. * All rights reserved. * * 2. License diff --git a/sys/contrib/dev/acpica/compiler/aslmain.c b/sys/contrib/dev/acpica/compiler/aslmain.c index ff22dec73369..21124cd1cabf 100644 --- a/sys/contrib/dev/acpica/compiler/aslmain.c +++ b/sys/contrib/dev/acpica/compiler/aslmain.c @@ -8,7 +8,7 @@ * * 1. Copyright Notice * - * Some or all of this work - Copyright (c) 1999 - 2025, Intel Corp. + * Some or all of this work - Copyright (c) 1999 - 2026, Intel Corp. * All rights reserved. * * 2. License diff --git a/sys/contrib/dev/acpica/compiler/aslmap.c b/sys/contrib/dev/acpica/compiler/aslmap.c index 4711b884a57c..08c1d5bdd36b 100644 --- a/sys/contrib/dev/acpica/compiler/aslmap.c +++ b/sys/contrib/dev/acpica/compiler/aslmap.c @@ -8,7 +8,7 @@ * * 1. Copyright Notice * - * Some or all of this work - Copyright (c) 1999 - 2025, Intel Corp. + * Some or all of this work - Copyright (c) 1999 - 2026, Intel Corp. * All rights reserved. * * 2. License @@ -611,3 +611,5 @@ const ASL_MAPPING_ENTRY AslKeywordMapping [] = /*! [End] no source code translation !*/ }; + +const UINT32 AslKeywordMappingCount = ACPI_ARRAY_LENGTH (AslKeywordMapping); diff --git a/sys/contrib/dev/acpica/compiler/aslmapenter.c b/sys/contrib/dev/acpica/compiler/aslmapenter.c index 81b57cb3f13d..032d953c596c 100644 --- a/sys/contrib/dev/acpica/compiler/aslmapenter.c +++ b/sys/contrib/dev/acpica/compiler/aslmapenter.c @@ -8,7 +8,7 @@ * * 1. Copyright Notice * - * Some or all of this work - Copyright (c) 1999 - 2025, Intel Corp. + * Some or all of this work - Copyright (c) 1999 - 2026, Intel Corp. * All rights reserved. * * 2. License diff --git a/sys/contrib/dev/acpica/compiler/aslmapoutput.c b/sys/contrib/dev/acpica/compiler/aslmapoutput.c index a009f64bc98d..86299dd5b783 100644 --- a/sys/contrib/dev/acpica/compiler/aslmapoutput.c +++ b/sys/contrib/dev/acpica/compiler/aslmapoutput.c @@ -8,7 +8,7 @@ * * 1. Copyright Notice * - * Some or all of this work - Copyright (c) 1999 - 2025, Intel Corp. + * Some or all of this work - Copyright (c) 1999 - 2026, Intel Corp. * All rights reserved. * * 2. License diff --git a/sys/contrib/dev/acpica/compiler/aslmaputils.c b/sys/contrib/dev/acpica/compiler/aslmaputils.c index f978e6a940b3..bafdca0322ce 100644 --- a/sys/contrib/dev/acpica/compiler/aslmaputils.c +++ b/sys/contrib/dev/acpica/compiler/aslmaputils.c @@ -8,7 +8,7 @@ * * 1. Copyright Notice * - * Some or all of this work - Copyright (c) 1999 - 2025, Intel Corp. + * Some or all of this work - Copyright (c) 1999 - 2026, Intel Corp. * All rights reserved. * * 2. License diff --git a/sys/contrib/dev/acpica/compiler/aslmessages.c b/sys/contrib/dev/acpica/compiler/aslmessages.c index 1e363236a149..f7c121ca990d 100644 --- a/sys/contrib/dev/acpica/compiler/aslmessages.c +++ b/sys/contrib/dev/acpica/compiler/aslmessages.c @@ -8,7 +8,7 @@ * * 1. Copyright Notice * - * Some or all of this work - Copyright (c) 1999 - 2025, Intel Corp. + * Some or all of this work - Copyright (c) 1999 - 2026, Intel Corp. * All rights reserved. * * 2. License @@ -412,7 +412,8 @@ const char *AslTableCompilerMsgs [] = /* ASL_MSG_UNKNOWN_FORMAT */ "Unknown format value", /* ASL_MSG_RESERVED_VALUE */ "Value for field is reserved or unknown", /* ASL_MSG_TWO_ZERO_VALUES */ "32-bit DSDT Address and 64-bit X_DSDT Address cannot both be zero", -/* ASL_MSG_BAD_PARSE_TREE */ "Parse tree appears to be ill-defined" +/* ASL_MSG_BAD_PARSE_TREE */ "Parse tree appears to be ill-defined", +/* ASL_MSG_MALFORMED_HEADER */ "Malformed ACPI table header detected" }; /* Preprocessor */ diff --git a/sys/contrib/dev/acpica/compiler/aslmessages.h b/sys/contrib/dev/acpica/compiler/aslmessages.h index dc0bbe10bd0d..f8ef09bbe9d3 100644 --- a/sys/contrib/dev/acpica/compiler/aslmessages.h +++ b/sys/contrib/dev/acpica/compiler/aslmessages.h @@ -8,7 +8,7 @@ * * 1. Copyright Notice * - * Some or all of this work - Copyright (c) 1999 - 2025, Intel Corp. + * Some or all of this work - Copyright (c) 1999 - 2026, Intel Corp. * All rights reserved. * * 2. License @@ -414,6 +414,7 @@ typedef enum ASL_MSG_RESERVED_VALUE, ASL_MSG_TWO_ZERO_VALUES, ASL_MSG_BAD_PARSE_TREE, + ASL_MSG_MALFORMED_HEADER, /* These messages are used by the Preprocessor only */ diff --git a/sys/contrib/dev/acpica/compiler/aslmethod.c b/sys/contrib/dev/acpica/compiler/aslmethod.c index 75096d38999e..6844890ce710 100644 --- a/sys/contrib/dev/acpica/compiler/aslmethod.c +++ b/sys/contrib/dev/acpica/compiler/aslmethod.c @@ -8,7 +8,7 @@ * * 1. Copyright Notice * - * Some or all of this work - Copyright (c) 1999 - 2025, Intel Corp. + * Some or all of this work - Copyright (c) 1999 - 2026, Intel Corp. * All rights reserved. * * 2. License diff --git a/sys/contrib/dev/acpica/compiler/aslnamesp.c b/sys/contrib/dev/acpica/compiler/aslnamesp.c index 9388d7428db6..e15421ec6df2 100644 --- a/sys/contrib/dev/acpica/compiler/aslnamesp.c +++ b/sys/contrib/dev/acpica/compiler/aslnamesp.c @@ -8,7 +8,7 @@ * * 1. Copyright Notice * - * Some or all of this work - Copyright (c) 1999 - 2025, Intel Corp. + * Some or all of this work - Copyright (c) 1999 - 2026, Intel Corp. * All rights reserved. * * 2. License diff --git a/sys/contrib/dev/acpica/compiler/asloffset.c b/sys/contrib/dev/acpica/compiler/asloffset.c index d60c4c4ec367..097bedd495fd 100644 --- a/sys/contrib/dev/acpica/compiler/asloffset.c +++ b/sys/contrib/dev/acpica/compiler/asloffset.c @@ -8,7 +8,7 @@ * * 1. Copyright Notice * - * Some or all of this work - Copyright (c) 1999 - 2025, Intel Corp. + * Some or all of this work - Copyright (c) 1999 - 2026, Intel Corp. * All rights reserved. * * 2. License diff --git a/sys/contrib/dev/acpica/compiler/aslopcodes.c b/sys/contrib/dev/acpica/compiler/aslopcodes.c index 8bef46b0d7ae..35f661331a9c 100644 --- a/sys/contrib/dev/acpica/compiler/aslopcodes.c +++ b/sys/contrib/dev/acpica/compiler/aslopcodes.c @@ -8,7 +8,7 @@ * * 1. Copyright Notice * - * Some or all of this work - Copyright (c) 1999 - 2025, Intel Corp. + * Some or all of this work - Copyright (c) 1999 - 2026, Intel Corp. * All rights reserved. * * 2. License @@ -863,6 +863,14 @@ OpcGenerateAmlOpcode ( Index = (UINT16) (Op->Asl.ParseOpcode - ASL_PARSE_OPCODE_BASE); + if ((Op->Asl.ParseOpcode < ASL_PARSE_OPCODE_BASE) || + (Index >= AslKeywordMappingCount)) + { + AslError (ASL_ERROR, ASL_MSG_COMPILER_INTERNAL, Op, + "Invalid parse opcode in OpcGenerateAmlOpcode"); + return; + } + Op->Asl.AmlOpcode = AslKeywordMapping[Index].AmlOpcode; Op->Asl.AcpiBtype = AslKeywordMapping[Index].AcpiBtype; Op->Asl.CompileFlags |= AslKeywordMapping[Index].Flags; diff --git a/sys/contrib/dev/acpica/compiler/asloperands.c b/sys/contrib/dev/acpica/compiler/asloperands.c index 1978b38b1cff..6e77ae165f87 100644 --- a/sys/contrib/dev/acpica/compiler/asloperands.c +++ b/sys/contrib/dev/acpica/compiler/asloperands.c @@ -8,7 +8,7 @@ * * 1. Copyright Notice * - * Some or all of this work - Copyright (c) 1999 - 2025, Intel Corp. + * Some or all of this work - Copyright (c) 1999 - 2026, Intel Corp. * All rights reserved. * * 2. License @@ -851,7 +851,9 @@ OpnDoPackage ( { ACPI_PARSE_OBJECT *InitializerOp; ACPI_PARSE_OBJECT *PackageLengthOp; + UINT64 DeclaredLength; UINT32 PackageLength = 0; + UINT32 MaxEncodedLength = 0x0FFFFFFF; /* Max AML package length encoding (28 bits) */ /* Opcode and package length first, followed by the initializer list */ @@ -875,9 +877,21 @@ OpnDoPackage ( /* If package length is a constant, compare to the initializer list */ if ((PackageLengthOp->Asl.ParseOpcode == PARSEOP_INTEGER) || - (PackageLengthOp->Asl.ParseOpcode == PARSEOP_QWORDCONST)) + (PackageLengthOp->Asl.ParseOpcode == PARSEOP_QWORDCONST) || + (PackageLengthOp->Asl.ParseOpcode == PARSEOP_PACKAGE_LENGTH)) { - if (PackageLengthOp->Asl.Value.Integer > PackageLength) + DeclaredLength = PackageLengthOp->Asl.Value.Integer; + + /* Guard against values that cannot be encoded in AML package length format */ + + if (DeclaredLength > MaxEncodedLength) + { + AslError (ASL_ERROR, ASL_MSG_ENCODING_LENGTH, PackageLengthOp, NULL); + DeclaredLength = MaxEncodedLength; + PackageLengthOp->Asl.Value.Integer = DeclaredLength; + } + + if (DeclaredLength > PackageLength) { /* * Allow package length to be longer than the initializer @@ -891,9 +905,9 @@ OpnDoPackage ( PackageLengthOp, NULL); } - PackageLength = (UINT32) PackageLengthOp->Asl.Value.Integer; + PackageLength = (UINT32) DeclaredLength; } - else if (PackageLengthOp->Asl.Value.Integer < PackageLength) + else if (DeclaredLength < PackageLength) { /* * The package length is smaller than the length of the @@ -999,7 +1013,13 @@ OpnDoLoadTable ( /* Fourth child is the RootPath string */ Next = Next->Asl.Next; - if (Next->Asl.ParseOpcode == PARSEOP_ZERO) + if ((Next->Asl.ParseOpcode == PARSEOP_ZERO) || + ((Next->Asl.Value.Integer == 0) && + ((Next->Asl.ParseOpcode == PARSEOP_INTEGER) || + (Next->Asl.ParseOpcode == PARSEOP_BYTECONST) || + (Next->Asl.ParseOpcode == PARSEOP_WORDCONST) || + (Next->Asl.ParseOpcode == PARSEOP_DWORDCONST)|| + (Next->Asl.ParseOpcode == PARSEOP_QWORDCONST)))) { Next->Asl.ParseOpcode = PARSEOP_STRING_LITERAL; Next->Asl.Value.String = "\\"; diff --git a/sys/contrib/dev/acpica/compiler/aslopt.c b/sys/contrib/dev/acpica/compiler/aslopt.c index 02d46458d6ac..afd11e06c2ac 100644 --- a/sys/contrib/dev/acpica/compiler/aslopt.c +++ b/sys/contrib/dev/acpica/compiler/aslopt.c @@ -8,7 +8,7 @@ * * 1. Copyright Notice * - * Some or all of this work - Copyright (c) 1999 - 2025, Intel Corp. + * Some or all of this work - Copyright (c) 1999 - 2026, Intel Corp. * All rights reserved. * * 2. License diff --git a/sys/contrib/dev/acpica/compiler/asloptions.c b/sys/contrib/dev/acpica/compiler/asloptions.c index a46ce96f5dbd..7c5cb69cf705 100644 --- a/sys/contrib/dev/acpica/compiler/asloptions.c +++ b/sys/contrib/dev/acpica/compiler/asloptions.c @@ -8,7 +8,7 @@ * * 1. Copyright Notice * - * Some or all of this work - Copyright (c) 1999 - 2025, Intel Corp. + * Some or all of this work - Copyright (c) 1999 - 2026, Intel Corp. * All rights reserved. * * 2. License diff --git a/sys/contrib/dev/acpica/compiler/aslparseop.c b/sys/contrib/dev/acpica/compiler/aslparseop.c index 65e5b5b3ea59..c9ffb1d8d850 100644 --- a/sys/contrib/dev/acpica/compiler/aslparseop.c +++ b/sys/contrib/dev/acpica/compiler/aslparseop.c @@ -8,7 +8,7 @@ * * 1. Copyright Notice * - * Some or all of this work - Copyright (c) 1999 - 2025, Intel Corp. + * Some or all of this work - Copyright (c) 1999 - 2026, Intel Corp. * All rights reserved. * * 2. License diff --git a/sys/contrib/dev/acpica/compiler/aslparser.y b/sys/contrib/dev/acpica/compiler/aslparser.y index 65a75af9763c..b29eb2ad0374 100644 --- a/sys/contrib/dev/acpica/compiler/aslparser.y +++ b/sys/contrib/dev/acpica/compiler/aslparser.y @@ -9,7 +9,7 @@ * * 1. Copyright Notice * - * Some or all of this work - Copyright (c) 1999 - 2025, Intel Corp. + * Some or all of this work - Copyright (c) 1999 - 2026, Intel Corp. * All rights reserved. * * 2. License diff --git a/sys/contrib/dev/acpica/compiler/aslpld.c b/sys/contrib/dev/acpica/compiler/aslpld.c index b1d9a05a7bdc..cfd725a76854 100644 --- a/sys/contrib/dev/acpica/compiler/aslpld.c +++ b/sys/contrib/dev/acpica/compiler/aslpld.c @@ -8,7 +8,7 @@ * * 1. Copyright Notice * - * Some or all of this work - Copyright (c) 1999 - 2025, Intel Corp. + * Some or all of this work - Copyright (c) 1999 - 2026, Intel Corp. * All rights reserved. * * 2. License diff --git a/sys/contrib/dev/acpica/compiler/aslpredef.c b/sys/contrib/dev/acpica/compiler/aslpredef.c index 4125c51c6895..5e1eb160f666 100644 --- a/sys/contrib/dev/acpica/compiler/aslpredef.c +++ b/sys/contrib/dev/acpica/compiler/aslpredef.c @@ -8,7 +8,7 @@ * * 1. Copyright Notice * - * Some or all of this work - Copyright (c) 1999 - 2025, Intel Corp. + * Some or all of this work - Copyright (c) 1999 - 2026, Intel Corp. * All rights reserved. * * 2. License diff --git a/sys/contrib/dev/acpica/compiler/aslprepkg.c b/sys/contrib/dev/acpica/compiler/aslprepkg.c index 9d0e861a0ff9..116aa04976e0 100644 --- a/sys/contrib/dev/acpica/compiler/aslprepkg.c +++ b/sys/contrib/dev/acpica/compiler/aslprepkg.c @@ -8,7 +8,7 @@ * * 1. Copyright Notice * - * Some or all of this work - Copyright (c) 1999 - 2025, Intel Corp. + * Some or all of this work - Copyright (c) 1999 - 2026, Intel Corp. * All rights reserved. * * 2. License diff --git a/sys/contrib/dev/acpica/compiler/aslprimaries.y b/sys/contrib/dev/acpica/compiler/aslprimaries.y index 608009d30da3..ef5aa3a7a8b1 100644 --- a/sys/contrib/dev/acpica/compiler/aslprimaries.y +++ b/sys/contrib/dev/acpica/compiler/aslprimaries.y @@ -11,7 +11,7 @@ NoEcho(' * * 1. Copyright Notice * - * Some or all of this work - Copyright (c) 1999 - 2025, Intel Corp. + * Some or all of this work - Copyright (c) 1999 - 2026, Intel Corp. * All rights reserved. * * 2. License diff --git a/sys/contrib/dev/acpica/compiler/aslprintf.c b/sys/contrib/dev/acpica/compiler/aslprintf.c index 819a498f2b7d..56faa95c6ba5 100644 --- a/sys/contrib/dev/acpica/compiler/aslprintf.c +++ b/sys/contrib/dev/acpica/compiler/aslprintf.c @@ -8,7 +8,7 @@ * * 1. Copyright Notice * - * Some or all of this work - Copyright (c) 1999 - 2025, Intel Corp. + * Some or all of this work - Copyright (c) 1999 - 2026, Intel Corp. * All rights reserved. * * 2. License diff --git a/sys/contrib/dev/acpica/compiler/aslprune.c b/sys/contrib/dev/acpica/compiler/aslprune.c index 4fc3c063f1d6..a8b96f299b60 100644 --- a/sys/contrib/dev/acpica/compiler/aslprune.c +++ b/sys/contrib/dev/acpica/compiler/aslprune.c @@ -8,7 +8,7 @@ * * 1. Copyright Notice * - * Some or all of this work - Copyright (c) 1999 - 2025, Intel Corp. + * Some or all of this work - Copyright (c) 1999 - 2026, Intel Corp. * All rights reserved. * * 2. License diff --git a/sys/contrib/dev/acpica/compiler/aslresource.c b/sys/contrib/dev/acpica/compiler/aslresource.c index 8250e84fd783..6ac8c03089ab 100644 --- a/sys/contrib/dev/acpica/compiler/aslresource.c +++ b/sys/contrib/dev/acpica/compiler/aslresource.c @@ -8,7 +8,7 @@ * * 1. Copyright Notice * - * Some or all of this work - Copyright (c) 1999 - 2025, Intel Corp. + * Some or all of this work - Copyright (c) 1999 - 2026, Intel Corp. * All rights reserved. * * 2. License diff --git a/sys/contrib/dev/acpica/compiler/aslresources.y b/sys/contrib/dev/acpica/compiler/aslresources.y index fd8a33d3c0d6..617a366411fd 100644 --- a/sys/contrib/dev/acpica/compiler/aslresources.y +++ b/sys/contrib/dev/acpica/compiler/aslresources.y @@ -11,7 +11,7 @@ NoEcho(' * * 1. Copyright Notice * - * Some or all of this work - Copyright (c) 1999 - 2025, Intel Corp. + * Some or all of this work - Copyright (c) 1999 - 2026, Intel Corp. * All rights reserved. * * 2. License diff --git a/sys/contrib/dev/acpica/compiler/aslrestype1.c b/sys/contrib/dev/acpica/compiler/aslrestype1.c index 3f873da0e703..c1f5a6885a4f 100644 --- a/sys/contrib/dev/acpica/compiler/aslrestype1.c +++ b/sys/contrib/dev/acpica/compiler/aslrestype1.c @@ -8,7 +8,7 @@ * * 1. Copyright Notice * - * Some or all of this work - Copyright (c) 1999 - 2025, Intel Corp. + * Some or all of this work - Copyright (c) 1999 - 2026, Intel Corp. * All rights reserved. * * 2. License diff --git a/sys/contrib/dev/acpica/compiler/aslrestype1i.c b/sys/contrib/dev/acpica/compiler/aslrestype1i.c index 02f4958d6d51..1ae5e3b0eef6 100644 --- a/sys/contrib/dev/acpica/compiler/aslrestype1i.c +++ b/sys/contrib/dev/acpica/compiler/aslrestype1i.c @@ -8,7 +8,7 @@ * * 1. Copyright Notice * - * Some or all of this work - Copyright (c) 1999 - 2025, Intel Corp. + * Some or all of this work - Copyright (c) 1999 - 2026, Intel Corp. * All rights reserved. * * 2. License diff --git a/sys/contrib/dev/acpica/compiler/aslrestype2.c b/sys/contrib/dev/acpica/compiler/aslrestype2.c index 6fb613370691..7296e2573858 100644 --- a/sys/contrib/dev/acpica/compiler/aslrestype2.c +++ b/sys/contrib/dev/acpica/compiler/aslrestype2.c @@ -8,7 +8,7 @@ * * 1. Copyright Notice * - * Some or all of this work - Copyright (c) 1999 - 2025, Intel Corp. + * Some or all of this work - Copyright (c) 1999 - 2026, Intel Corp. * All rights reserved. * * 2. License diff --git a/sys/contrib/dev/acpica/compiler/aslrestype2d.c b/sys/contrib/dev/acpica/compiler/aslrestype2d.c index 3a7ca9189aff..f392eb6eed7a 100644 --- a/sys/contrib/dev/acpica/compiler/aslrestype2d.c +++ b/sys/contrib/dev/acpica/compiler/aslrestype2d.c @@ -8,7 +8,7 @@ * * 1. Copyright Notice * - * Some or all of this work - Copyright (c) 1999 - 2025, Intel Corp. + * Some or all of this work - Copyright (c) 1999 - 2026, Intel Corp. * All rights reserved. * * 2. License diff --git a/sys/contrib/dev/acpica/compiler/aslrestype2e.c b/sys/contrib/dev/acpica/compiler/aslrestype2e.c index 4e6293617b94..d555fabb4114 100644 --- a/sys/contrib/dev/acpica/compiler/aslrestype2e.c +++ b/sys/contrib/dev/acpica/compiler/aslrestype2e.c @@ -8,7 +8,7 @@ * * 1. Copyright Notice * - * Some or all of this work - Copyright (c) 1999 - 2025, Intel Corp. + * Some or all of this work - Copyright (c) 1999 - 2026, Intel Corp. * All rights reserved. * * 2. License diff --git a/sys/contrib/dev/acpica/compiler/aslrestype2q.c b/sys/contrib/dev/acpica/compiler/aslrestype2q.c index 6ebe149a3c14..489400417f8a 100644 --- a/sys/contrib/dev/acpica/compiler/aslrestype2q.c +++ b/sys/contrib/dev/acpica/compiler/aslrestype2q.c @@ -8,7 +8,7 @@ * * 1. Copyright Notice * - * Some or all of this work - Copyright (c) 1999 - 2025, Intel Corp. + * Some or all of this work - Copyright (c) 1999 - 2026, Intel Corp. * All rights reserved. * * 2. License diff --git a/sys/contrib/dev/acpica/compiler/aslrestype2s.c b/sys/contrib/dev/acpica/compiler/aslrestype2s.c index f47402d4e025..8160114980ed 100644 --- a/sys/contrib/dev/acpica/compiler/aslrestype2s.c +++ b/sys/contrib/dev/acpica/compiler/aslrestype2s.c @@ -8,7 +8,7 @@ * * 1. Copyright Notice * - * Some or all of this work - Copyright (c) 1999 - 2025, Intel Corp. + * Some or all of this work - Copyright (c) 1999 - 2026, Intel Corp. * All rights reserved. * * 2. License diff --git a/sys/contrib/dev/acpica/compiler/aslrestype2w.c b/sys/contrib/dev/acpica/compiler/aslrestype2w.c index cc8a31804977..97a9ad82b5ef 100644 --- a/sys/contrib/dev/acpica/compiler/aslrestype2w.c +++ b/sys/contrib/dev/acpica/compiler/aslrestype2w.c @@ -8,7 +8,7 @@ * * 1. Copyright Notice * - * Some or all of this work - Copyright (c) 1999 - 2025, Intel Corp. + * Some or all of this work - Copyright (c) 1999 - 2026, Intel Corp. * All rights reserved. * * 2. License diff --git a/sys/contrib/dev/acpica/compiler/aslrules.y b/sys/contrib/dev/acpica/compiler/aslrules.y index c96d4cc75db6..00dede690168 100644 --- a/sys/contrib/dev/acpica/compiler/aslrules.y +++ b/sys/contrib/dev/acpica/compiler/aslrules.y @@ -11,7 +11,7 @@ NoEcho(' * * 1. Copyright Notice * - * Some or all of this work - Copyright (c) 1999 - 2025, Intel Corp. + * Some or all of this work - Copyright (c) 1999 - 2026, Intel Corp. * All rights reserved. * * 2. License diff --git a/sys/contrib/dev/acpica/compiler/aslstartup.c b/sys/contrib/dev/acpica/compiler/aslstartup.c index 628a5c1ada2d..0da5eaa4d099 100644 --- a/sys/contrib/dev/acpica/compiler/aslstartup.c +++ b/sys/contrib/dev/acpica/compiler/aslstartup.c @@ -8,7 +8,7 @@ * * 1. Copyright Notice * - * Some or all of this work - Copyright (c) 1999 - 2025, Intel Corp. + * Some or all of this work - Copyright (c) 1999 - 2026, Intel Corp. * All rights reserved. * * 2. License diff --git a/sys/contrib/dev/acpica/compiler/aslstubs.c b/sys/contrib/dev/acpica/compiler/aslstubs.c index 50bda4b83fe1..f872b0f5f2e0 100644 --- a/sys/contrib/dev/acpica/compiler/aslstubs.c +++ b/sys/contrib/dev/acpica/compiler/aslstubs.c @@ -8,7 +8,7 @@ * * 1. Copyright Notice * - * Some or all of this work - Copyright (c) 1999 - 2025, Intel Corp. + * Some or all of this work - Copyright (c) 1999 - 2026, Intel Corp. * All rights reserved. * * 2. License diff --git a/sys/contrib/dev/acpica/compiler/aslsupport.l b/sys/contrib/dev/acpica/compiler/aslsupport.l index 74ac78d8c4ef..d9e609faee46 100644 --- a/sys/contrib/dev/acpica/compiler/aslsupport.l +++ b/sys/contrib/dev/acpica/compiler/aslsupport.l @@ -9,7 +9,7 @@ * * 1. Copyright Notice * - * Some or all of this work - Copyright (c) 1999 - 2025, Intel Corp. + * Some or all of this work - Copyright (c) 1999 - 2026, Intel Corp. * All rights reserved. * * 2. License diff --git a/sys/contrib/dev/acpica/compiler/aslsupport.y b/sys/contrib/dev/acpica/compiler/aslsupport.y index 3bd09a55e704..7595c1065df6 100644 --- a/sys/contrib/dev/acpica/compiler/aslsupport.y +++ b/sys/contrib/dev/acpica/compiler/aslsupport.y @@ -9,7 +9,7 @@ NoEcho(' * * 1. Copyright Notice * - * Some or all of this work - Copyright (c) 1999 - 2025, Intel Corp. + * Some or all of this work - Copyright (c) 1999 - 2026, Intel Corp. * All rights reserved. * * 2. License diff --git a/sys/contrib/dev/acpica/compiler/asltokens.y b/sys/contrib/dev/acpica/compiler/asltokens.y index 50d6031e5ed0..0497ba9535ec 100644 --- a/sys/contrib/dev/acpica/compiler/asltokens.y +++ b/sys/contrib/dev/acpica/compiler/asltokens.y @@ -9,7 +9,7 @@ NoEcho(' * * 1. Copyright Notice * - * Some or all of this work - Copyright (c) 1999 - 2025, Intel Corp. + * Some or all of this work - Copyright (c) 1999 - 2026, Intel Corp. * All rights reserved. * * 2. License diff --git a/sys/contrib/dev/acpica/compiler/asltransform.c b/sys/contrib/dev/acpica/compiler/asltransform.c index c58f771354f1..f239ff0b11fe 100644 --- a/sys/contrib/dev/acpica/compiler/asltransform.c +++ b/sys/contrib/dev/acpica/compiler/asltransform.c @@ -8,7 +8,7 @@ * * 1. Copyright Notice * - * Some or all of this work - Copyright (c) 1999 - 2025, Intel Corp. + * Some or all of this work - Copyright (c) 1999 - 2026, Intel Corp. * All rights reserved. * * 2. License diff --git a/sys/contrib/dev/acpica/compiler/asltree.c b/sys/contrib/dev/acpica/compiler/asltree.c index 9237176c94b5..d8021dbbb765 100644 --- a/sys/contrib/dev/acpica/compiler/asltree.c +++ b/sys/contrib/dev/acpica/compiler/asltree.c @@ -8,7 +8,7 @@ * * 1. Copyright Notice * - * Some or all of this work - Copyright (c) 1999 - 2025, Intel Corp. + * Some or all of this work - Copyright (c) 1999 - 2026, Intel Corp. * All rights reserved. * * 2. License diff --git a/sys/contrib/dev/acpica/compiler/asltypes.h b/sys/contrib/dev/acpica/compiler/asltypes.h index 50234d71f0a7..36052302e9bf 100644 --- a/sys/contrib/dev/acpica/compiler/asltypes.h +++ b/sys/contrib/dev/acpica/compiler/asltypes.h @@ -8,7 +8,7 @@ * * 1. Copyright Notice * - * Some or all of this work - Copyright (c) 1999 - 2025, Intel Corp. + * Some or all of this work - Copyright (c) 1999 - 2026, Intel Corp. * All rights reserved. * * 2. License diff --git a/sys/contrib/dev/acpica/compiler/asltypes.y b/sys/contrib/dev/acpica/compiler/asltypes.y index 2c2669559585..3bfbae4f7b04 100644 --- a/sys/contrib/dev/acpica/compiler/asltypes.y +++ b/sys/contrib/dev/acpica/compiler/asltypes.y @@ -9,7 +9,7 @@ NoEcho(' * * 1. Copyright Notice * - * Some or all of this work - Copyright (c) 1999 - 2025, Intel Corp. + * Some or all of this work - Copyright (c) 1999 - 2026, Intel Corp. * All rights reserved. * * 2. License diff --git a/sys/contrib/dev/acpica/compiler/aslutils.c b/sys/contrib/dev/acpica/compiler/aslutils.c index 267ad8b77e13..69d0a2310a8d 100644 --- a/sys/contrib/dev/acpica/compiler/aslutils.c +++ b/sys/contrib/dev/acpica/compiler/aslutils.c @@ -8,7 +8,7 @@ * * 1. Copyright Notice * - * Some or all of this work - Copyright (c) 1999 - 2025, Intel Corp. + * Some or all of this work - Copyright (c) 1999 - 2026, Intel Corp. * All rights reserved. * * 2. License diff --git a/sys/contrib/dev/acpica/compiler/asluuid.c b/sys/contrib/dev/acpica/compiler/asluuid.c index 712a06fda951..a7e08380c67b 100644 --- a/sys/contrib/dev/acpica/compiler/asluuid.c +++ b/sys/contrib/dev/acpica/compiler/asluuid.c @@ -8,7 +8,7 @@ * * 1. Copyright Notice * - * Some or all of this work - Copyright (c) 1999 - 2025, Intel Corp. + * Some or all of this work - Copyright (c) 1999 - 2026, Intel Corp. * All rights reserved. * * 2. License diff --git a/sys/contrib/dev/acpica/compiler/aslwalks.c b/sys/contrib/dev/acpica/compiler/aslwalks.c index db2c9daa455e..c28177603823 100644 --- a/sys/contrib/dev/acpica/compiler/aslwalks.c +++ b/sys/contrib/dev/acpica/compiler/aslwalks.c @@ -8,7 +8,7 @@ * * 1. Copyright Notice * - * Some or all of this work - Copyright (c) 1999 - 2025, Intel Corp. + * Some or all of this work - Copyright (c) 1999 - 2026, Intel Corp. * All rights reserved. * * 2. License @@ -197,6 +197,7 @@ AnMethodTypingWalkEnd ( void *Context) { UINT32 ThisOpBtype; + ACPI_PARSE_OBJECT *TargetMethodOp; switch (Op->Asl.ParseOpcode) @@ -227,12 +228,24 @@ AnMethodTypingWalkEnd ( if (Op->Asl.Child->Asl.Node && (Op->Asl.ParentMethod != Op->Asl.Child->Asl.Node->Op)) { + TargetMethodOp = Op->Asl.Child->Asl.Node->Op; + + /* Break mutual-recursion loops during typing */ + if (TargetMethodOp->Asl.CompileFlags & OP_VISITED) + { + break; + } + + TargetMethodOp->Asl.CompileFlags |= OP_VISITED; + /* We must type the method here */ - TrWalkParseTree (Op->Asl.Child->Asl.Node->Op, + TrWalkParseTree (TargetMethodOp, ASL_WALK_VISIT_UPWARD, NULL, AnMethodTypingWalkEnd, NULL); + TargetMethodOp->Asl.CompileFlags &= ~OP_VISITED; + ThisOpBtype = AnGetBtype (Op->Asl.Child); } } diff --git a/sys/contrib/dev/acpica/compiler/aslxref.c b/sys/contrib/dev/acpica/compiler/aslxref.c index eb61b1d461cd..0f8c62262a0c 100644 --- a/sys/contrib/dev/acpica/compiler/aslxref.c +++ b/sys/contrib/dev/acpica/compiler/aslxref.c @@ -8,7 +8,7 @@ * * 1. Copyright Notice * - * Some or all of this work - Copyright (c) 1999 - 2025, Intel Corp. + * Some or all of this work - Copyright (c) 1999 - 2026, Intel Corp. * All rights reserved. * * 2. License @@ -558,11 +558,23 @@ XfNamespaceLocateBegin ( Node = NextOp->Asl.Node; + /* Malformed tree: parent method has no namespace node */ + if (!Node) + { + return_ACPI_STATUS (AE_OK); + } + /* Get Arg # */ RegisterNumber = Op->Asl.AmlOpcode - AML_ARG0; /* 0x68 through 0x6F */ MethodArgs = Node->MethodArgs; + /* Gracefully handle malformed trees where method args were not set up */ + if (!MethodArgs) + { + return_ACPI_STATUS (AE_OK); + } + /* Mark this Arg as referenced */ MethodArgs[RegisterNumber].Flags |= ASL_ARG_REFERENCED; diff --git a/sys/contrib/dev/acpica/compiler/aslxrefout.c b/sys/contrib/dev/acpica/compiler/aslxrefout.c index 67e26b3e69de..86c66868b857 100644 --- a/sys/contrib/dev/acpica/compiler/aslxrefout.c +++ b/sys/contrib/dev/acpica/compiler/aslxrefout.c @@ -8,7 +8,7 @@ * * 1. Copyright Notice * - * Some or all of this work - Copyright (c) 1999 - 2025, Intel Corp. + * Some or all of this work - Copyright (c) 1999 - 2026, Intel Corp. * All rights reserved. * * 2. License diff --git a/sys/contrib/dev/acpica/compiler/cvcompiler.c b/sys/contrib/dev/acpica/compiler/cvcompiler.c index e42dfa8066ac..de8c523e5647 100644 --- a/sys/contrib/dev/acpica/compiler/cvcompiler.c +++ b/sys/contrib/dev/acpica/compiler/cvcompiler.c @@ -8,7 +8,7 @@ * * 1. Copyright Notice * - * Some or all of this work - Copyright (c) 1999 - 2025, Intel Corp. + * Some or all of this work - Copyright (c) 1999 - 2026, Intel Corp. * All rights reserved. * * 2. License diff --git a/sys/contrib/dev/acpica/compiler/cvdisasm.c b/sys/contrib/dev/acpica/compiler/cvdisasm.c index ebc93a0bd194..f4eac2861996 100644 --- a/sys/contrib/dev/acpica/compiler/cvdisasm.c +++ b/sys/contrib/dev/acpica/compiler/cvdisasm.c @@ -8,7 +8,7 @@ * * 1. Copyright Notice * - * Some or all of this work - Copyright (c) 1999 - 2025, Intel Corp. + * Some or all of this work - Copyright (c) 1999 - 2026, Intel Corp. * All rights reserved. * * 2. License diff --git a/sys/contrib/dev/acpica/compiler/cvparser.c b/sys/contrib/dev/acpica/compiler/cvparser.c index 724daa0dea67..db5595e47d3e 100644 --- a/sys/contrib/dev/acpica/compiler/cvparser.c +++ b/sys/contrib/dev/acpica/compiler/cvparser.c @@ -9,7 +9,7 @@ * * 1. Copyright Notice * - * Some or all of this work - Copyright (c) 1999 - 2025, Intel Corp. + * Some or all of this work - Copyright (c) 1999 - 2026, Intel Corp. * All rights reserved. * * 2. License diff --git a/sys/contrib/dev/acpica/compiler/dtcompile.c b/sys/contrib/dev/acpica/compiler/dtcompile.c index 873baf397e47..e3447e28e0f0 100644 --- a/sys/contrib/dev/acpica/compiler/dtcompile.c +++ b/sys/contrib/dev/acpica/compiler/dtcompile.c @@ -8,7 +8,7 @@ * * 1. Copyright Notice * - * Some or all of this work - Copyright (c) 1999 - 2025, Intel Corp. + * Some or all of this work - Copyright (c) 1999 - 2026, Intel Corp. * All rights reserved. * * 2. License @@ -363,18 +363,42 @@ DtInsertCompilerIds ( return; } - /* Walk to the Compiler fields at the end of the header */ + /* Walk to the Compiler fields at the end of the header, with safety checks */ + + if (!FieldList) + { + DtError (ASL_WARNING, ASL_MSG_MALFORMED_HEADER, NULL, NULL); + return; + } Next = FieldList; for (i = 0; i < 7; i++) { + if (!Next || !Next->Next) + { + /* Malformed/short header: cannot insert compiler IDs */ + DtError (ASL_WARNING, ASL_MSG_MALFORMED_HEADER, FieldList, NULL); + return; + } Next = Next->Next; } + /* Ensure both Creator ID and Revision fields exist */ + if (!Next || !Next->Next) + { + DtError (ASL_WARNING, ASL_MSG_MALFORMED_HEADER, FieldList, NULL); + return; + } + Next->Value = ASL_CREATOR_ID; Next->Flags = DT_FIELD_NOT_ALLOCATED; Next = Next->Next; + if (!Next) + { + DtError (ASL_WARNING, ASL_MSG_MALFORMED_HEADER, FieldList, NULL); + return; + } Next->Value = VersionString; Next->Flags = DT_FIELD_NOT_ALLOCATED; } diff --git a/sys/contrib/dev/acpica/compiler/dtcompiler.h b/sys/contrib/dev/acpica/compiler/dtcompiler.h index 505bb6b40bed..6a47bd7b1691 100644 --- a/sys/contrib/dev/acpica/compiler/dtcompiler.h +++ b/sys/contrib/dev/acpica/compiler/dtcompiler.h @@ -8,7 +8,7 @@ * * 1. Copyright Notice * - * Some or all of this work - Copyright (c) 1999 - 2025, Intel Corp. + * Some or all of this work - Copyright (c) 1999 - 2026, Intel Corp. * All rights reserved. * * 2. License @@ -610,6 +610,10 @@ DtCompileDrtm ( void **PFieldList); ACPI_STATUS +DtCompileDtpr ( + void **PFieldList); + +ACPI_STATUS DtCompileEinj ( void **PFieldList); @@ -819,6 +823,7 @@ extern const unsigned char TemplateDbg2[]; extern const unsigned char TemplateDbgp[]; extern const unsigned char TemplateDmar[]; extern const unsigned char TemplateDrtm[]; +extern const unsigned char TemplateDtpr[]; extern const unsigned char TemplateEcdt[]; extern const unsigned char TemplateEinj[]; extern const unsigned char TemplateErdt[]; diff --git a/sys/contrib/dev/acpica/compiler/dtcompilerparser.l b/sys/contrib/dev/acpica/compiler/dtcompilerparser.l index 322ee225a60d..492468867acd 100644 --- a/sys/contrib/dev/acpica/compiler/dtcompilerparser.l +++ b/sys/contrib/dev/acpica/compiler/dtcompilerparser.l @@ -9,7 +9,7 @@ * * 1. Copyright Notice * - * Some or all of this work - Copyright (c) 1999 - 2025, Intel Corp. + * Some or all of this work - Copyright (c) 1999 - 2026, Intel Corp. * All rights reserved. * * 2. License diff --git a/sys/contrib/dev/acpica/compiler/dtcompilerparser.y b/sys/contrib/dev/acpica/compiler/dtcompilerparser.y index f160434e0959..4dab55c0b783 100644 --- a/sys/contrib/dev/acpica/compiler/dtcompilerparser.y +++ b/sys/contrib/dev/acpica/compiler/dtcompilerparser.y @@ -9,7 +9,7 @@ * * 1. Copyright Notice * - * Some or all of this work - Copyright (c) 1999 - 2025, Intel Corp. + * Some or all of this work - Copyright (c) 1999 - 2026, Intel Corp. * All rights reserved. * * 2. License diff --git a/sys/contrib/dev/acpica/compiler/dtexpress.c b/sys/contrib/dev/acpica/compiler/dtexpress.c index 65f10aac9f00..0a503febb22d 100644 --- a/sys/contrib/dev/acpica/compiler/dtexpress.c +++ b/sys/contrib/dev/acpica/compiler/dtexpress.c @@ -8,7 +8,7 @@ * * 1. Copyright Notice * - * Some or all of this work - Copyright (c) 1999 - 2025, Intel Corp. + * Some or all of this work - Copyright (c) 1999 - 2026, Intel Corp. * All rights reserved. * * 2. License diff --git a/sys/contrib/dev/acpica/compiler/dtfield.c b/sys/contrib/dev/acpica/compiler/dtfield.c index ded7315aaa3f..106db4d04e58 100644 --- a/sys/contrib/dev/acpica/compiler/dtfield.c +++ b/sys/contrib/dev/acpica/compiler/dtfield.c @@ -8,7 +8,7 @@ * * 1. Copyright Notice * - * Some or all of this work - Copyright (c) 1999 - 2025, Intel Corp. + * Some or all of this work - Copyright (c) 1999 - 2026, Intel Corp. * All rights reserved. * * 2. License diff --git a/sys/contrib/dev/acpica/compiler/dtio.c b/sys/contrib/dev/acpica/compiler/dtio.c index 7bcf16b8f9d1..b0a830386834 100644 --- a/sys/contrib/dev/acpica/compiler/dtio.c +++ b/sys/contrib/dev/acpica/compiler/dtio.c @@ -8,7 +8,7 @@ * * 1. Copyright Notice * - * Some or all of this work - Copyright (c) 1999 - 2025, Intel Corp. + * Some or all of this work - Copyright (c) 1999 - 2026, Intel Corp. * All rights reserved. * * 2. License @@ -422,6 +422,12 @@ DtParseLine ( End++; } + /* No value characters present */ + if (End <= Start) + { + return (AE_OK); + } + Length = ACPI_PTR_DIFF (End, Start); TmpValue = UtLocalCalloc (Length + 1); diff --git a/sys/contrib/dev/acpica/compiler/dtparser.l b/sys/contrib/dev/acpica/compiler/dtparser.l index 90fc39d8c66a..b7574e77a6ad 100644 --- a/sys/contrib/dev/acpica/compiler/dtparser.l +++ b/sys/contrib/dev/acpica/compiler/dtparser.l @@ -9,7 +9,7 @@ * * 1. Copyright Notice * - * Some or all of this work - Copyright (c) 1999 - 2025, Intel Corp. + * Some or all of this work - Copyright (c) 1999 - 2026, Intel Corp. * All rights reserved. * * 2. License diff --git a/sys/contrib/dev/acpica/compiler/dtparser.y b/sys/contrib/dev/acpica/compiler/dtparser.y index d6d584b2c6e9..9f6ad8b33d41 100644 --- a/sys/contrib/dev/acpica/compiler/dtparser.y +++ b/sys/contrib/dev/acpica/compiler/dtparser.y @@ -9,7 +9,7 @@ * * 1. Copyright Notice * - * Some or all of this work - Copyright (c) 1999 - 2025, Intel Corp. + * Some or all of this work - Copyright (c) 1999 - 2026, Intel Corp. * All rights reserved. * * 2. License diff --git a/sys/contrib/dev/acpica/compiler/dtsubtable.c b/sys/contrib/dev/acpica/compiler/dtsubtable.c index 0c660b7ab8bb..82a7b0c8a14c 100644 --- a/sys/contrib/dev/acpica/compiler/dtsubtable.c +++ b/sys/contrib/dev/acpica/compiler/dtsubtable.c @@ -8,7 +8,7 @@ * * 1. Copyright Notice * - * Some or all of this work - Copyright (c) 1999 - 2025, Intel Corp. + * Some or all of this work - Copyright (c) 1999 - 2026, Intel Corp. * All rights reserved. * * 2. License @@ -430,7 +430,12 @@ DtGetSubtableLength ( case ACPI_DMT_IORTMEM: - Step = 10; + /* + * The ACPI_DMT_IORTMEM type is defined in AcpiDmTableInfoIortAcc. + * TODO: compute number of fields ("Step") directly from the array initialisation. + * This may require some refactoring of dmtbinfo2.c and acdiasasm.h + */ + Step = 11; break; default: diff --git a/sys/contrib/dev/acpica/compiler/dttable.c b/sys/contrib/dev/acpica/compiler/dttable.c index effcf6d65e1c..6e0a0fedb0c0 100644 --- a/sys/contrib/dev/acpica/compiler/dttable.c +++ b/sys/contrib/dev/acpica/compiler/dttable.c @@ -8,7 +8,7 @@ * * 1. Copyright Notice * - * Some or all of this work - Copyright (c) 1999 - 2025, Intel Corp. + * Some or all of this work - Copyright (c) 1999 - 2026, Intel Corp. * All rights reserved. * * 2. License diff --git a/sys/contrib/dev/acpica/compiler/dttable1.c b/sys/contrib/dev/acpica/compiler/dttable1.c index a513ff9ed009..d82153d6a590 100644 --- a/sys/contrib/dev/acpica/compiler/dttable1.c +++ b/sys/contrib/dev/acpica/compiler/dttable1.c @@ -8,7 +8,7 @@ * * 1. Copyright Notice * - * Some or all of this work - Copyright (c) 1999 - 2025, Intel Corp. + * Some or all of this work - Copyright (c) 1999 - 2026, Intel Corp. * All rights reserved. * * 2. License @@ -1728,6 +1728,124 @@ DtCompileDrtm ( /****************************************************************************** * + * FUNCTION: DtCompileDtpr + * + * PARAMETERS: List - Current field list pointer + * + * RETURN: Status + * + * DESCRIPTION: Compile DTPR. + * + *****************************************************************************/ + +ACPI_STATUS +DtCompileDtpr ( + void **List) +{ + ACPI_STATUS Status; + DT_SUBTABLE *Subtable; + DT_SUBTABLE *ParentTable; + DT_FIELD **PFieldList = (DT_FIELD **) List; + ACPI_TABLE_DTPR *Dtpr; + ACPI_TPR_INSTANCE *TprInst; + UINT32 i, InsCnt, SrlCnt, TprCnt; + + + ParentTable = DtPeekSubtable (); + + Status = DtCompileTable (PFieldList, AcpiDmTableInfoDtpr, &Subtable); + if (ACPI_FAILURE (Status)) + { + return (Status); + } + + DtInsertSubtable (ParentTable, Subtable); + + Dtpr = ACPI_SUB_PTR (ACPI_TABLE_DTPR, Subtable->Buffer, + sizeof (ACPI_TABLE_HEADER)); + if (!Dtpr) + { + AcpiOsPrintf ("DTPR buffer pointer is NULL\n"); + return (AE_NULL_OBJECT); + } + + InsCnt = Dtpr->InsCnt; + + while (*PFieldList) + { + for (i = 0; i < InsCnt; i++) + { + Status = DtCompileTable (PFieldList, AcpiDmTableInfoDtprInstance, + &Subtable); + if (ACPI_FAILURE (Status)) + { + return (Status); + } + + TprInst = ACPI_CAST_PTR (ACPI_TPR_INSTANCE, Subtable->Buffer); + if (!TprInst) + { + AcpiOsPrintf ("Tpr Instance buffer pointer is NULL\n"); + return (AE_NULL_OBJECT); + } + + TprCnt = TprInst->TprCnt; + DtInsertSubtable (ParentTable, Subtable); + DtPushSubtable (Subtable); + ParentTable = DtPeekSubtable (); + + while (*PFieldList && TprCnt) + { + Status = DtCompileTable (PFieldList, AcpiDmTableInfoDtprArr, + &Subtable); + if (ACPI_FAILURE (Status)) + { + return (Status); + } + + DtInsertSubtable (ParentTable, Subtable); + TprCnt--; + } + + DtPopSubtable(); + ParentTable = DtPeekSubtable (); + } + + Status = DtCompileTable (PFieldList, AcpiDmTableInfoDtprSerializeReq0, + &Subtable); + if (ACPI_FAILURE (Status)) + { + return (Status); + } + + SrlCnt = *ACPI_CAST_PTR(UINT32, Subtable->Buffer); + DtInsertSubtable (ParentTable, Subtable); + DtPushSubtable (Subtable); + ParentTable = DtPeekSubtable (); + + while (*PFieldList && SrlCnt) + { + Status = DtCompileTable (PFieldList, AcpiDmTableInfoDtprSerializeReq1, + &Subtable); + if (ACPI_FAILURE (Status)) + { + return (Status); + } + + DtInsertSubtable (ParentTable, Subtable); + SrlCnt--; + } + + + DtPopSubtable(); + ParentTable = DtPeekSubtable (); + } + + return Status; +} + +/****************************************************************************** + * * FUNCTION: DtCompileEinj * * PARAMETERS: List - Current field list pointer @@ -2984,6 +3102,19 @@ DtCompileIort ( IortRmr->RmrCount = RmrCount; break; + case ACPI_IORT_NODE_IWB: + + Status = DtCompileTable (PFieldList, AcpiDmTableInfoIort7, + &Subtable); + if (ACPI_FAILURE (Status)) + { + return (Status); + } + + DtInsertSubtable (ParentTable, Subtable); + NodeLength += Subtable->Length; + break; + default: DtFatal (ASL_MSG_UNKNOWN_SUBTABLE, SubtableStart, "IORT"); diff --git a/sys/contrib/dev/acpica/compiler/dttable2.c b/sys/contrib/dev/acpica/compiler/dttable2.c index 43484490ff3e..e5ecb25332b9 100644 --- a/sys/contrib/dev/acpica/compiler/dttable2.c +++ b/sys/contrib/dev/acpica/compiler/dttable2.c @@ -8,7 +8,7 @@ * * 1. Copyright Notice * - * Some or all of this work - Copyright (c) 1999 - 2025, Intel Corp. + * Some or all of this work - Copyright (c) 1999 - 2026, Intel Corp. * All rights reserved. * * 2. License @@ -439,6 +439,21 @@ DtCompileMadt ( InfoTable = AcpiDmTableInfoMadt27; break; + case ACPI_MADT_TYPE_GICV5_IRS: + + InfoTable = AcpiDmTableInfoMadt28; + break; + + case ACPI_MADT_TYPE_GICV5_ITS: + + InfoTable = AcpiDmTableInfoMadt29; + break; + + case ACPI_MADT_TYPE_GICV5_ITS_TRANSLATE: + + InfoTable = AcpiDmTableInfoMadt30; + break; + default: if (MadtHeader->Type >= ACPI_MADT_TYPE_OEM_RESERVED) diff --git a/sys/contrib/dev/acpica/compiler/dttemplate.c b/sys/contrib/dev/acpica/compiler/dttemplate.c index d7140712d4e6..57d64cba27fa 100644 --- a/sys/contrib/dev/acpica/compiler/dttemplate.c +++ b/sys/contrib/dev/acpica/compiler/dttemplate.c @@ -8,7 +8,7 @@ * * 1. Copyright Notice * - * Some or all of this work - Copyright (c) 1999 - 2025, Intel Corp. + * Some or all of this work - Copyright (c) 1999 - 2026, Intel Corp. * All rights reserved. * * 2. License diff --git a/sys/contrib/dev/acpica/compiler/dttemplate.h b/sys/contrib/dev/acpica/compiler/dttemplate.h index 88bc38f25c39..460f3a54afe5 100644 --- a/sys/contrib/dev/acpica/compiler/dttemplate.h +++ b/sys/contrib/dev/acpica/compiler/dttemplate.h @@ -8,7 +8,7 @@ * * 1. Copyright Notice * - * Some or all of this work - Copyright (c) 1999 - 2025, Intel Corp. + * Some or all of this work - Copyright (c) 1999 - 2026, Intel Corp. * All rights reserved. * * 2. License @@ -643,6 +643,23 @@ const unsigned char TemplateEcdt[] = 0x09,0x00 /* 00000040 ".." */ }; +const unsigned char TemplateDtpr[] = +{ + 0x44,0x54,0x50,0x52,0x68,0x00,0x00,0x00, /* 00000000 "DTPRh..." */ + 0x01,0x0B,0x49,0x4E,0x54,0x45,0x4C,0x20, /* 00000008 ".#INTEL." */ + 0x54,0x45,0x4D,0x50,0x4C,0x41,0x54,0x45, /* 00000010 "TEMPLATE" */ + 0x00,0x00,0x00,0x01,0x49,0x4E,0x54,0x4C, /* 00000018 "....INTL" */ + 0x04,0x04,0x25,0x20,0x00,0x00,0x00,0x00, /* 00000020 "........" */ + 0x02,0x00,0x00,0x00,0x00,0x00,0x00,0x00, /* 00000028 "........" */ + 0x02,0x00,0x00,0x00,0x30,0xB0,0xAA,0xFF, /* 00000030 "....0..." */ + 0xFF,0x1F,0x00,0x00,0x38,0xB0,0xAA,0xFF, /* 00000038 "....8..." */ + 0xFF,0x1F,0x00,0x00,0x00,0x00,0x00,0x00, /* 00000040 "........" */ + 0x02,0x00,0x00,0x00,0x30,0xB0,0xBB,0xFF, /* 00000048 "....0..." */ + 0xFF,0x1F,0x00,0x00,0x38,0xB0,0xBB,0xFF, /* 00000050 "....8..." */ + 0xFF,0x1F,0x00,0x00,0x01,0x00,0x00,0x00, /* 00000058 "........" */ + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00 /* 00000060 "........" */ +}; + const unsigned char TemplateEinj[] = { 0x45,0x49,0x4E,0x4A,0x30,0x01,0x00,0x00, /* 00000000 "EINJ0..." */ @@ -1188,11 +1205,11 @@ const unsigned char TemplateHpet[] = const unsigned char TemplateIort[] = { - 0x49,0x4F,0x52,0x54,0x3C,0x02,0x00,0x00, /* 00000000 "IORT<..." */ - 0x05,0xCB,0x49,0x4E,0x54,0x45,0x4C,0x20, /* 00000008 "..INTEL " */ + 0x49,0x4F,0x52,0x54,0x78,0x02,0x00,0x00, /* 00000000 "IORTx..." */ + 0x05,0x85,0x49,0x4E,0x54,0x45,0x4C,0x20, /* 00000008 "..INTEL " */ 0x54,0x65,0x6D,0x70,0x6C,0x61,0x74,0x65, /* 00000010 "Template" */ 0x00,0x00,0x00,0x00,0x49,0x4E,0x54,0x4C, /* 00000018 "....INTL" */ - 0x17,0x12,0x21,0x20,0x07,0x00,0x00,0x00, /* 00000020 "..! ...." */ + 0x07,0x08,0x25,0x20,0x08,0x00,0x00,0x00, /* 00000020 "..% ...." */ 0x34,0x00,0x00,0x00,0x00,0x00,0x00,0x00, /* 00000028 "4......." */ 0x49,0x4F,0x52,0x54,0x00,0x18,0x00,0x01, /* 00000030 "IORT...." */ 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, /* 00000038 "........" */ @@ -1204,10 +1221,10 @@ const unsigned char TemplateIort[] = 0x00,0x5C,0x5F,0x53,0x42,0x2E,0x50,0x43, /* 00000068 ".\_SB.PC" */ 0x49,0x30,0x2E,0x44,0x45,0x56,0x30,0x00, /* 00000070 "I0.DEV0." */ 0x49,0x4F,0x52,0x54,0x3C,0x02,0x00,0x00, /* 00000078 "IORT<..." */ - 0x03,0xF1,0x49,0x4E,0x54,0x45,0x4C,0x20, /* 00000080 "..INTEL " */ + 0x05,0xCB,0x49,0x4E,0x54,0x45,0x4C,0x20, /* 00000080 "..INTEL " */ 0x54,0x65,0x6D,0x70,0x6C,0x61,0x74,0x65, /* 00000088 "Template" */ 0x00,0x00,0x00,0x00,0x49,0x4E,0x54,0x4C, /* 00000090 "....INTL" */ - 0x05,0x01,0x21,0x20,0x07,0x00,0x00,0x00, /* 00000098 "..! ...." */ + 0x17,0x12,0x21,0x20,0x07,0x00,0x00,0x00, /* 00000098 "..! ...." */ 0x34,0x00,0x00,0x00,0x00,0x00,0x00,0x00, /* 000000A0 "4......." */ 0x49,0x4F,0x52,0x54,0x00,0x18,0x00,0x01, /* 000000A8 "IORT...." */ 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, /* 000000B0 "........" */ @@ -1259,7 +1276,14 @@ const unsigned char TemplateIort[] = 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, /* 00000220 "........" */ 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, /* 00000228 "........" */ 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, /* 00000230 "........" */ - 0x00,0x00,0x00,0x00 /* 00000238 "...." */ + 0x00,0x00,0x00,0x00,0x07,0x3C,0x00,0x01, /* 00000238 ".....<.." */ + 0x00,0x00,0x00,0x00,0x01,0x00,0x00,0x00, /* 00000240 "........" */ + 0x28,0x00,0x00,0x00,0x00,0x00,0x00,0x2F, /* 00000248 "(....../" */ + 0x00,0x00,0x00,0x00,0x00,0x00,0x5C,0x5F, /* 00000250 "......\_" */ + 0x53,0x42,0x5F,0x2E,0x49,0x57,0x42,0x30, /* 00000258 "SB_.IWB0" */ + 0x00,0x00,0x00,0x00,0x00,0x01,0x00,0x00, /* 00000260 "........" */ + 0x00,0x40,0x00,0x00,0x00,0x30,0x00,0x00, /* 00000268 ".@...0.." */ + 0x00,0x01,0x00,0x00,0x00 /* 00000270 "....." */ }; const unsigned char TemplateIovt[] = @@ -1387,15 +1411,15 @@ const unsigned char TemplateLpit[] = 0x00,0x00,0x00,0x00 /* 00000090 "...." */ }; -/* MADT with ACPI 6.0 subtables */ +/* MADT with ACPI 6.7 subtables */ const unsigned char TemplateMadt[] = { - 0x41,0x50,0x49,0x43,0x62,0x02,0x00,0x00, /* 00000000 "APICb..." */ - 0x07,0x44,0x49,0x4E,0x54,0x45,0x4C,0x20, /* 00000008 ".DINTEL " */ + 0x41,0x50,0x49,0x43,0xAA,0x02,0x00,0x00, /* 00000000 "APIC...." */ + 0x07,0x5F,0x49,0x4E,0x54,0x45,0x4C,0x20, /* 00000008 "._INTEL " */ 0x54,0x65,0x6D,0x70,0x6C,0x61,0x74,0x65, /* 00000010 "Template" */ 0x01,0x00,0x00,0x00,0x49,0x4E,0x54,0x4C, /* 00000018 "....INTL" */ - 0x28,0x06,0x23,0x20,0x00,0x00,0x00,0x00, /* 00000020 "(.# ...." */ + 0x07,0x08,0x25,0x20,0x00,0x00,0x00,0x00, /* 00000020 "..% ...." */ 0x01,0x00,0x00,0x00,0x00,0x08,0x00,0x00, /* 00000028 "........" */ 0x01,0x00,0x00,0x00,0x01,0x0C,0x01,0x00, /* 00000030 "........" */ 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, /* 00000038 "........" */ @@ -1467,7 +1491,16 @@ const unsigned char TemplateMadt[] = 0x00,0x00,0x60,0x00,0x00,0x00,0x00,0x00, /* 00000248 "..`....." */ 0x00,0x00,0x00,0x00,0x60,0x00,0x00,0x00, /* 00000250 "....`..." */ 0x00,0x0C,0x00,0x00,0x00,0x00,0x00,0x00, /* 00000258 "........" */ - 0x00,0x00 /* 00000260 ".." */ + 0x00,0x00,0x1D,0x10,0x00,0x00,0x00,0x00, /* 00000260 "........" */ + 0x00,0x00,0x00,0x00,0x12,0x2F,0x00,0x00, /* 00000268 "...../.." */ + 0x00,0x00,0x1E,0x18,0x00,0x00,0x00,0x00, /* 00000270 "........" */ + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, /* 00000278 "........" */ + 0x00,0x00,0x00,0x00,0x13,0x2F,0x00,0x00, /* 00000280 "...../.." */ + 0x00,0x00,0x1C,0x20,0x05,0x00,0x00,0x00, /* 00000288 "... ...." */ + 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, /* 00000290 "........" */ + 0x00,0x00,0x00,0x00,0x1A,0x2F,0x00,0x00, /* 00000298 "...../.." */ + 0x00,0x00,0x00,0x00,0x1B,0x2F,0x00,0x00, /* 000002A0 "...../.." */ + 0x00,0x00 /* 000002A8 ".." */ }; const unsigned char TemplateMcfg[] = diff --git a/sys/contrib/dev/acpica/compiler/dtutils.c b/sys/contrib/dev/acpica/compiler/dtutils.c index f3b9fa856dd6..ff3b1b6e9453 100644 --- a/sys/contrib/dev/acpica/compiler/dtutils.c +++ b/sys/contrib/dev/acpica/compiler/dtutils.c @@ -8,7 +8,7 @@ * * 1. Copyright Notice * - * Some or all of this work - Copyright (c) 1999 - 2025, Intel Corp. + * Some or all of this work - Copyright (c) 1999 - 2026, Intel Corp. * All rights reserved. * * 2. License diff --git a/sys/contrib/dev/acpica/compiler/preprocess.h b/sys/contrib/dev/acpica/compiler/preprocess.h index 26a11f573402..8e3a602027b8 100644 --- a/sys/contrib/dev/acpica/compiler/preprocess.h +++ b/sys/contrib/dev/acpica/compiler/preprocess.h @@ -8,7 +8,7 @@ * * 1. Copyright Notice * - * Some or all of this work - Copyright (c) 1999 - 2025, Intel Corp. + * Some or all of this work - Copyright (c) 1999 - 2026, Intel Corp. * All rights reserved. * * 2. License diff --git a/sys/contrib/dev/acpica/compiler/prexpress.c b/sys/contrib/dev/acpica/compiler/prexpress.c index b2e7b785c5e9..ec430eda1b11 100644 --- a/sys/contrib/dev/acpica/compiler/prexpress.c +++ b/sys/contrib/dev/acpica/compiler/prexpress.c @@ -8,7 +8,7 @@ * * 1. Copyright Notice * - * Some or all of this work - Copyright (c) 1999 - 2025, Intel Corp. + * Some or all of this work - Copyright (c) 1999 - 2026, Intel Corp. * All rights reserved. * * 2. License diff --git a/sys/contrib/dev/acpica/compiler/prmacros.c b/sys/contrib/dev/acpica/compiler/prmacros.c index 6d2acf52b980..350839192c42 100644 --- a/sys/contrib/dev/acpica/compiler/prmacros.c +++ b/sys/contrib/dev/acpica/compiler/prmacros.c @@ -8,7 +8,7 @@ * * 1. Copyright Notice * - * Some or all of this work - Copyright (c) 1999 - 2025, Intel Corp. + * Some or all of this work - Copyright (c) 1999 - 2026, Intel Corp. * All rights reserved. * * 2. License diff --git a/sys/contrib/dev/acpica/compiler/prparser.l b/sys/contrib/dev/acpica/compiler/prparser.l index fe0495121911..d286cb84da7b 100644 --- a/sys/contrib/dev/acpica/compiler/prparser.l +++ b/sys/contrib/dev/acpica/compiler/prparser.l @@ -9,7 +9,7 @@ * * 1. Copyright Notice * - * Some or all of this work - Copyright (c) 1999 - 2025, Intel Corp. + * Some or all of this work - Copyright (c) 1999 - 2026, Intel Corp. * All rights reserved. * * 2. License diff --git a/sys/contrib/dev/acpica/compiler/prparser.y b/sys/contrib/dev/acpica/compiler/prparser.y index 47edb20dcba8..7a724e9ed55e 100644 --- a/sys/contrib/dev/acpica/compiler/prparser.y +++ b/sys/contrib/dev/acpica/compiler/prparser.y @@ -9,7 +9,7 @@ * * 1. Copyright Notice * - * Some or all of this work - Copyright (c) 1999 - 2025, Intel Corp. + * Some or all of this work - Copyright (c) 1999 - 2026, Intel Corp. * All rights reserved. * * 2. License diff --git a/sys/contrib/dev/acpica/compiler/prscan.c b/sys/contrib/dev/acpica/compiler/prscan.c index 81b703cfb081..59ef7cc73bf0 100644 --- a/sys/contrib/dev/acpica/compiler/prscan.c +++ b/sys/contrib/dev/acpica/compiler/prscan.c @@ -8,7 +8,7 @@ * * 1. Copyright Notice * - * Some or all of this work - Copyright (c) 1999 - 2025, Intel Corp. + * Some or all of this work - Copyright (c) 1999 - 2026, Intel Corp. * All rights reserved. * * 2. License diff --git a/sys/contrib/dev/acpica/compiler/prutils.c b/sys/contrib/dev/acpica/compiler/prutils.c index 902baed833c8..2bf700594ae3 100644 --- a/sys/contrib/dev/acpica/compiler/prutils.c +++ b/sys/contrib/dev/acpica/compiler/prutils.c @@ -8,7 +8,7 @@ * * 1. Copyright Notice * - * Some or all of this work - Copyright (c) 1999 - 2025, Intel Corp. + * Some or all of this work - Copyright (c) 1999 - 2026, Intel Corp. * All rights reserved. * * 2. License |
