References passed as arguments to control methods were dereferenced
immediately (before control was passed to the called method). The
references are now correctly passed directly to the called
method.
http://bugzilla.kernel.org/show_bug.cgi?id=5389
Signed-off-by: Lin Ming <ming.m.lin@intel.com>
Signed-off-by: Bob Moore <robert.moore@intel.com>
Signed-off-by: Alexey Starikovskiy <astarikovskiy@suse.de>
Signed-off-by: Len Brown <len.brown@intel.com>
+ /* If method call - leave the Reference on the stack */
+
+ if (walk_state->opcode == AML_INT_METHODCALL_OP) {
+ break;
+ }
+
obj_desc = *stack_desc->reference.where;
if (obj_desc) {
/*
obj_desc = *stack_desc->reference.where;
if (obj_desc) {
/*
* the package, can't dereference it
*/
ACPI_ERROR((AE_INFO,
* the package, can't dereference it
*/
ACPI_ERROR((AE_INFO,
- "Attempt to deref an Index to NULL pkg element Idx=%p",
+ "Attempt to dereference an Index to NULL package element Idx=%p",
stack_desc));
status = AE_AML_UNINITIALIZED_ELEMENT;
}
stack_desc));
status = AE_AML_UNINITIALIZED_ELEMENT;
}
/* Invalid reference object */
ACPI_ERROR((AE_INFO,
/* Invalid reference object */
ACPI_ERROR((AE_INFO,
- "Unknown TargetType %X in Index/Reference obj %p",
+ "Unknown TargetType %X in Index/Reference object %p",
stack_desc->reference.target_type,
stack_desc));
status = AE_AML_INTERNAL;
stack_desc->reference.target_type,
stack_desc));
status = AE_AML_INTERNAL;