ACPICA: Resources: New interface, AcpiWalkResourceBuffer.

Implements a new interface for walking resource lists that it at
a lower level than the existing AcpiWalkResources.  (Method is
not executed.)

Signed-off-by: Bob Moore <robert.moore@intel.com>
Signed-off-by: Lv Zheng <lv.zheng@intel.com>
Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com>
ACPICA: Change exception code for LoadTable operator.

For the case where one of the input strings is too long,
change the returned exception code from AE_BAD_PARAMETER to
AE_AML_STRING_LIMIT.

Signed-off-by: Bob Moore <robert.moore@intel.com>
Signed-off-by: Lv Zheng <lv.zheng@intel.com>
Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com>
ACPICA: Eliminate some small unnecessary pathname functions.

Removed several small pathname functions to increase efficiency.
Essentially, they replace a function call with a single compare.

Signed-off-by: Bob Moore <robert.moore@intel.com>
Signed-off-by: Lv Zheng <lv.zheng@intel.com>
Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com>
ACPICA: Add root node optimization to internal get namespace node function.

Detect a request for the root node (a lone backslash) up front
before invoking a full namespace lookup.

Signed-off-by: Bob Moore <robert.moore@intel.com>
Signed-off-by: Lv Zheng <lv.zheng@intel.com>
Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com>
ACPICA: Lint changes, no functional change.

Some changes from lint.

Signed-off-by: Bob Moore <robert.moore@intel.com>
Signed-off-by: Lv Zheng <lv.zheng@intel.com>
Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com>
ACPICA: Add time macros for various timer/time manipulation.

Constants for time manipulation, including constants for the 100
nanosecond timers. Chao Guan, Bob Moore, Lv Zheng.

Signed-off-by: Bob Moore <robert.moore@intel.com>
Signed-off-by: Lv Zheng <lv.zheng@intel.com>
Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com>
ACPICA: Add header file support for the ACPI 5 TPM2 ACPI table.

Reserved in ACPI 5.0 specification, but defined in a November
2011 Microsoft document.

Signed-off-by: Bob Moore <robert.moore@intel.com>
Signed-off-by: Lv Zheng <lv.zheng@intel.com>
Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com>
ACPICA: Resource Manager: Add a pointer cast for a namespace node.

Add a missing cast for a namespace node pointer passed in from
an external interface. Reported Rafael Wysocki.

Signed-off-by: Bob Moore <robert.moore@intel.com>
Signed-off-by: Lv Zheng <lv.zheng@intel.com>
Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com>
ACPICA: DEBUG_PRINT macros: Update to improve performance.

Move check for "debug enable" to before the actual call to the
debug print routine. Improves time of ASLTS by about 15%.  Also,
remove "safe" exit macros since no complex expressions are ever
used in the return statements.

Signed-off-by: Bob Moore <robert.moore@intel.com>
Signed-off-by: Lv Zheng <lv.zheng@intel.com>
Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com>
ACPICA: FUNCTION_TRACE macros: Check if debug is enabled up-front.

In the functions that implement the macros, check if debug
is enabled up-front before the call to the lower debug print
function. This provides a small performance improvement.

Signed-off-by: Bob Moore <robert.moore@intel.com>
Signed-off-by: Lv Zheng <lv.zheng@intel.com>
Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com>
ACPICA: Eliminate superfluous return_UINT8 and return_UINT32 macros.

These macros were implemented the same as return_VALUE and thus
they were not needed.

Signed-off-by: Bob Moore <robert.moore@intel.com>
Signed-off-by: Lv Zheng <lv.zheng@intel.com>
Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com>
ACPICA: Update ACPI_IS_DEBUG_ENABLED macro.

Add extra parens to allow use of !ACPI_IS_DEBUG_ENABLED.

Signed-off-by: Bob Moore <robert.moore@intel.com>
Signed-off-by: Lv Zheng <lv.zheng@intel.com>
Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com>
ACPICA: Deploy new ACPI_IS_DEBUG_ENABLED macro in debug output code.

Simplifies check for debug output enables.

Signed-off-by: Bob Moore <robert.moore@intel.com>
Signed-off-by: Lv Zheng <lv.zheng@intel.com>
Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com>
ACPICA: Merge all debug output macros into a single file, acoutput.

Moved the debug trace macros from acmacros.h into acoutput.h
where they belong.

Signed-off-by: Bob Moore <robert.moore@intel.com>
Signed-off-by: Lv Zheng <lv.zheng@intel.com>
Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com>
ACPICA: iASL: Finish support for CSRT table.

Add intel-specific shared info subtable.  Add data table compiler
and template support.

Signed-off-by: Bob Moore <robert.moore@intel.com>
Signed-off-by: Lv Zheng <lv.zheng@intel.com>
Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com>
ACPICA: iASL: Finish support for the TPM2 table.

Add disassembler, table compiler, and template support.

Signed-off-by: Bob Moore <robert.moore@intel.com>
Signed-off-by: Lv Zheng <lv.zheng@intel.com>
Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com>
ACPICA: Update for non-configured ACPI_IS_DEBUG_ENABLED macro.

Also add acoutput.h to the nsdump.c file.

Signed-off-by: Bob Moore <robert.moore@intel.com>
Signed-off-by: Lv Zheng <lv.zheng@intel.com>
Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com>
ACPICA: Fix possible memory leak in dispatcher error path.

On error, delete mutex object created during method mutex creation.
Reported by tim.gardner@canonical.com.

Signed-off-by: Tim Gardner <tim.gardner@canonical.com>
Signed-off-by: Bob Moore <robert.moore@intel.com>
Signed-off-by: Lv Zheng <lv.zheng@intel.com>
Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com>
ACPICA: Resource manager: Add support for ACPI 5 wake bit in IRQ descriptor.

Add support to both get and set the extended share flags for the
IRQ() resource descriptor. Reported by Aaron Lu.

Signed-off-by: Aaron Lu <aaron.lu@intel.com>
Signed-off-by: Bob Moore <robert.moore@intel.com>
Signed-off-by: Lv Zheng <lv.zheng@intel.com>
Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com>
ACPICA: Namespace: Eliminate dot...dot output during initialization.

This feature no longer serves any good purpose and also confuses any error
messages during ACPICA initialization.

Signed-off-by: Bob Moore <robert.moore@intel.com>
Signed-off-by: Lv Zheng <lv.zheng@intel.com>
Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com>