Because the AML has been parsed at this point, assume that the
parse object has been constructed properly.
Signed-off-by: Erik Schmauss <erik.schmauss@intel.com>
Since External Ops are resolved during namespace load, the code
that resolves external ops within AcpiDmXrefDescendingWalk can
be removed. Because AML_EXTERNAL_OP is an AML_NAMED object, handle
External Ops similar to AML_NAMED objects.
Signed-off-by: Erik Schmauss <erik.schmauss@intel.com>
This is different than AcpiDmEmitExternals due to the fact that
AcpiDmEmitExternal generates ASL based off of the parse tree
rather than AcpiGbl_ExternalList. This check searches
AcpiGbl_ExternalList to see if the External declaration being
emitted is a conflicting external declaration or not.
Signed-off-by: Erik Schmauss <erik.schmauss@intel.com>
Conflicting external declarations are illegal in ASL. When the
disassembler encounters a conflicting external in the AML, the
conflicting external is emitted with a comment warning the user
that a conflicting external has been emitted. The alternative
approach to handling conflicting external declarations within
AML is for the disassembler to abort. This approach is not
preferred because the purpose of the disassembler is to
disassemble the AML rather than prevent the disassembly due to
the quality of AML.
Signed-off-by: Erik Schmauss <erik.schmauss@intel.com>
An external declaration is a conflicting declaration when a name has
been declared as an external and a named object within the same file.
Signed-off-by: Erik Schmauss <erik.schmauss@intel.com>
By doing so, external control method resolutions can be resolved like
normal control methods. This eliminates the need to reparse the aml
all over again for external control methods that were encoded within
the aml with the 0x15 bytecode.
Signed-off-by: Erik Schmauss <erik.schmauss@intel.com>
This is done because there are certain parts of this function that need
to be used elsewhere in the code base.
Signed-off-by: Erik Schmauss <erik.schmauss@intel.com>
Since Externals could be of ACPI_TYPE_METHOD, there is a possibility
that the AcpiNsLookup may cause a new scope to be opened. Therefore,
disable opening the scope for all AcpiNsLookup invocations that deal
with externals.
Signed-off-by: Erik Schmauss <erik.schmauss@intel.com>
This means that the namepath of external ops should be referenced as Op->Named.Path rather
than Op->Common.Value.Name.
Signed-off-by: Erik Schmauss <erik.schmauss@intel.com>
This method has been changed to count methods that are not resolved at this
point. Resolved methods do not need to be reparsed since the amount of
arguments should be known after it is parsed in PsParseLoop.
Signed-off-by: Erik Schmauss <erik.schmauss@intel.com>
This is a name change as well as a change in the scope of this flag.
This is done so that it can be referenced in the dispatcher.
Signed-off-by: Erik Schmauss <erik.schmauss@intel.com>
This is done so that the aml parser will build the parse tree of
External Op as a named object. This is done to streamline creation
of external op parse nodes and facilitate namespace resolution of
externals.
Signed-off-by: Erik Schmauss <erik.schmauss@intel.com>
When tests are meant to return exceptions, proceeding causes unexpected
number of exceptions left. This patch fixes such issues by interrupting the
tests when exception is expected. Lv Zheng.
Signed-off-by: Lv Zheng <lv.zheng@intel.com>
The p6a0 store matrix is used to indicate "Stroe" allowable types while
b67a contains indexes to this matrix.
1. Row[3] is used for Package target,
Row[4] is used for Method target,
Row[5] is used for Non-computational data (Device/Event/...) target.
2. Col[2] is used for FIXED fields result,
Col[3] is used for Computational data (Integer/String/Buffer) result,
Col[4] is used for Package result.
As it is not possible to:
1. Store(Package/Method/Noncomputation, Field/Computationl/Package)
2. Store(Method/Noncomputation, Field/Computational)
We must change the matrix to reflect the validated Windows behavior. By
doing so, several m689 failures are fixed. Lv Zheng.
Signed-off-by: Lv Zheng <lv.zheng@intel.com>
In m702 tests, there are 2 lines trying to exclude 2 test cases, while
the test cases should be valid. OTOH, GeneralPurposeIo test is not
correct, it shouldn't validate the region access result as we don't
implement fully functioning region handlers in acpiexec. This patch fixes
these breakage. Lv Zheng.
Signed-off-by: Lv Zheng <lv.zheng@intel.com>
Store(Integer/String/Buffer, Package) results in AE_AML_TARGET_TYPE. This
patch fixes ASLTS failures by removing these invalid test cases.
Note that m34d is not a kind of coverage test that also validates if
invalid Store test cases can trigger exceptions, it only contains valid
Store test cases where the results' ObjectType can be compared, so we
should just remove the invalid test cases instead of adding exception
check. Lv Zheng.
Signed-off-by: Lv Zheng <lv.zheng@intel.com>
This patch fixes the Identity2MS collection's directory name of its
sub-test-cases in order to fix unexpected error occurred to the following
command:
aslts.sh -u -m n32 -c extra_aslts
The Identity2MS test cases are located at Identity2MS/abbu, rather than
Identity2MS/extra or Identity2MS/extra_aslts. Lv Zheng.
Signed-off-by: Lv Zheng <lv.zheng@intel.com>
If there is an external declaration and named object declaration with the
same name within the same table, this is considered a redefinition of that
named object or external.
For example, the following ASL code is considered a redeclaration:
DefinitonBlock (...)
{
Name(abcd, 0)
External(abcd)
}
This change enables the compiler to emit an error when compiling ASL code
that is similar to the above example.
Signed-off-by: Erik Schmauss <erik.schmauss@intel.com>
By doing so, we can label each namespace node with a particular OwnerId.
This will be used in later changes to help identify redeclarations in
the presence of Externals.
Signed-off-by: Erik Schmauss <erik.schmauss@intel.com>
Converter related structures are released to Linux kernel while they
are not correctly linuxized. This patch fixes this issue. Lv Zheng.
Signed-off-by: Lv Zheng <lv.zheng@intel.com>
This change enhances the capability of the compiler to handle
multiple extraneous parens, for example:
Return (((((((((((INT1)))))))))))
ACPICA BZ 1380
There are enough of these strings to justify a separate file.
Also, these strings are only used for the disassembler and
the debugger. Thus, this change improves ACPICA modularity.