For Windows compatibility, return an implicit integer of value
zero for methods that have no executable code. A default implicit
value of zero is provided for methods.
Such methods are seen in the field as stubs (presumably), and can
cause drivers to fail if they expect a return value. Lin Ming.
Merge the code that validates control method argument counts into
the predefined validation module. Eliminates possible multiple
warnings for incorrect counts.
This can happen if the _WAK method returns nothing (as per ACPI 1.0)
but does return an integer if the implicit return mechanism is enabled.
This is the only method that has this problem, since it is also
defined to return a package of two integers (ACPI 1.0b+). In all
other cases, if a method returns an object when one was not expected,
no warning is issued.
For predefined methods (such as _BIF), add automatic conversion for
objects that are required to be a String, but a Buffer was found
instead. This can happen when reading string battery data from
an operation region, because it used to be difficult to convert
the data from buffer to string from within the ASL. Linux BZ 11822.
In a fully qualified namepath, allow multiple backslash prefixes.
This can happen because of the use of a double-backslash in
strings (since backslash is the escape character) causing confusion.
ACPICA BZ 739 Lin Ming.
Moved some commonly-used defines and global variables from the
private headers to the public headers. Split the resource descriptor
structs out of actypes.h to a new file, acrestyp.h
Fixes a problem where the use of an alias within a namepath would
result in a not found error or cause the compiler to fault.
Also now allows forward references from the Alias operator itself.
ACPICA BZ 738.
Added the -e option to allow the inclusion of additional ACPI tables
to help with the disassembly of method invocations and the generation
of external declarations during the disassembly. Certain external
method invocations cannot be disassembled properly without the actual
declaration of the method. Use the -e option to include the table
where the external method(s) are actually declared. Most useful for
disassembling SSDTs that make method calls back to the master DSDT.
Lin Ming.
Example: To disassemble an SSDT with calls to DSDT:
iasl -d -e dsdt.aml ssdt1.aml
The current implemenation of _OSI within ACPICA only allows other
control methods to execute _OSI. This change allows the host OS
to execute _OSI via the AcpiEvaluateObject interface. _OSI is a
special method -- it does not exist in the AML code, it is
implemented within ACPICA.
acpi.h now includes only the "public" acpica headers. All other
acpica headers are "private" and should not be included by acpica
users. One new file, accommon.h is used to include the commonly
used private headers for acpica code generation. Future plans are
to move all private headers to a new subdirectory.
Added two initialization examples (within a comment block) that
show how to init ACPI for early table access and for a normal
initialization. Same code will appear in the ACPICA reference
manual.
Use a global pointer instead of using AcpiGetTableByIndex for each
FACS access. This simplifies the code for the Global Lock and the
Firmware Waking Vector(s).
Add a loop counter to force exit from AML While loops if the count
becomes too large. This can occur in poorly written AML when the
hardware does not respond within a while loop and the loop does not
implement a timeout. The maximum loop count is configurable. A new
exception code is returned when a loop is broken, AE_AML_INFINITE_LOOP.
Bob Moore, Alexey Starikovskiy.
Previously, a control state object was allocated and freed for each
execution of the loop. The optimization is to simply reuse the control
state for each iteration. This speeds up the raw loop execution time by
about 5%.
Fixes a possible memory leak if an allocation failure happens in
the parse loop. Must terminate an executing control method. Lin Ming,
Bob Moore. ACPICA BZ 489.
Split AcpiSetFirmwareWakingVector into two: one for the 32-bit vector,
another for the 64-bit vector. This is required because the host OS must
setup the wake much differently for each vector (real vs. protected mode,
etc.) and the interface should not be deciding which vector to use.
Also eliminate the GetFirmwareWakingVector interface, as it served no
purpose (only the firmware reads the vector, OS only writes the vector.)
ACPICA BZ 731.
Removed the "$Revision" number that appeared in each module header.
This version number was useful under SourceSafe and CVS, but has no
meaning under git. It is not only incorrect, it could also be
misleading.
Allow zero length strings during interpreter buffer-to-string
conversions. For example, during the ToDecimalString and ToHexString
operaters, as well as implicit conversions. Fiodor Suietov.
ACPICA BZ 585.
Validates predefined ACPI objects that appear in the namespace, at the
time they are evaluated. The argument count and the type of the returned
object are validated. The purpose of this validation is to detect problems
with the BIOS-exposed predefined ACPI objects before the results are
returned to the ACPI-related drivers.
Fixed two possible memory leaks in the error exit paths of
AcpiUtUpdateObjectReference and AcpiUtWalkPackageTree. These functions
are similar in that they use a stack of state objects in order to
eliminate recursion. The stack must be fully deallocated if an error
occurs. Lin Ming. BZ 383.
Removed the ACPI_BITREG_WAKE_ENABLE definition and entry in the global
register table. This bit does not exist and is unused. Lin Ming, Bob Moore
BZ 442.