void AcpiDbDisplayLocals ( void) { ACPI_WALK_STATE *WalkState; WalkState = AcpiDsGetCurrentWalkState (AcpiGbl_CurrentWalkList); if (!WalkState) { AcpiOsPrintf ("There is no method currently executing\n"); return; } AcpiDmDisplayLocals (WalkState); }
void AcpiDmDumpMethodInfo ( ACPI_STATUS Status, ACPI_WALK_STATE *WalkState, ACPI_PARSE_OBJECT *Op) { ACPI_PARSE_OBJECT *Next; ACPI_THREAD_STATE *Thread; ACPI_WALK_STATE *NextWalkState; ACPI_NAMESPACE_NODE *PreviousMethod = NULL; /* Ignore control codes, they are not errors */ if ((Status & AE_CODE_MASK) == AE_CODE_CONTROL) { return; } /* We may be executing a deferred opcode */ if (WalkState->DeferredNode) { AcpiOsPrintf ("Executing subtree for Buffer/Package/Region\n"); return; } /* * If there is no Thread, we are not actually executing a method. * This can happen when the iASL compiler calls the interpreter * to perform constant folding. */ Thread = WalkState->Thread; if (!Thread) { return; } /* Display exception and method name */ AcpiOsPrintf ("\n**** Exception %s during execution of method ", AcpiFormatException (Status)); AcpiNsPrintNodePathname (WalkState->MethodNode, NULL); /* Display stack of executing methods */ AcpiOsPrintf ("\n\nMethod Execution Stack:\n"); NextWalkState = Thread->WalkStateList; /* Walk list of linked walk states */ while (NextWalkState) { AcpiOsPrintf (" Method [%4.4s] executing: ", AcpiUtGetNodeName (NextWalkState->MethodNode)); /* First method is the currently executing method */ if (NextWalkState == WalkState) { if (Op) { /* Display currently executing ASL statement */ Next = Op->Common.Next; Op->Common.Next = NULL; AcpiDmDisassemble (NextWalkState, Op, ACPI_UINT32_MAX); Op->Common.Next = Next; } } else { /* * This method has called another method * NOTE: the method call parse subtree is already deleted at this * point, so we cannot disassemble the method invocation. */ AcpiOsPrintf ("Call to method "); AcpiNsPrintNodePathname (PreviousMethod, NULL); } PreviousMethod = NextWalkState->MethodNode; NextWalkState = NextWalkState->Next; AcpiOsPrintf ("\n"); } /* Display the method locals and arguments */ AcpiOsPrintf ("\n"); AcpiDmDisplayLocals (WalkState); AcpiOsPrintf ("\n"); AcpiDmDisplayArguments (WalkState); AcpiOsPrintf ("\n"); }
void AcpiDmDumpMethodInfo ( ACPI_STATUS Status, ACPI_WALK_STATE *WalkState, ACPI_PARSE_OBJECT *Op) { ACPI_PARSE_OBJECT *Next; ACPI_THREAD_STATE *Thread; ACPI_WALK_STATE *NextWalkState; ACPI_NAMESPACE_NODE *PreviousMethod = NULL; /* Ignore control codes, they are not errors */ if ((Status & AE_CODE_MASK) == AE_CODE_CONTROL) { return; } /* Display exception and method name */ AcpiOsPrintf ("\n**** Exception %s during execution of method ", AcpiFormatException (Status)); AcpiNsPrintNodePathname (WalkState->MethodNode, NULL); /* Display stack of executing methods */ AcpiOsPrintf ("\n\nMethod Execution Stack:\n"); Thread = WalkState->Thread; NextWalkState = Thread->WalkStateList; /* Walk list of linked walk states */ while (NextWalkState) { AcpiOsPrintf (" Method [%4.4s] executing: ", NextWalkState->MethodNode->Name.Ascii); /* First method is the currently executing method */ if (NextWalkState == WalkState) { /* Display currently executing ASL statement */ Next = Op->Common.Next; Op->Common.Next = NULL; AcpiDmDisassemble (NextWalkState, Op, ACPI_UINT32_MAX); Op->Common.Next = Next; } else { /* * This method has called another method * NOTE: the method call parse subtree is already deleted at this * point, so we cannot disassemble the method invocation. */ AcpiOsPrintf ("Call to method "); AcpiNsPrintNodePathname (PreviousMethod, NULL); } PreviousMethod = NextWalkState->MethodNode; NextWalkState = NextWalkState->Next; AcpiOsPrintf ("\n"); } /* Display the method locals and arguments */ AcpiOsPrintf ("\n"); AcpiDmDisplayLocals (WalkState); AcpiOsPrintf ("\n"); AcpiDmDisplayArguments (WalkState); AcpiOsPrintf ("\n"); }