FreeBSD/sys/contrib/dev/acpica/components/executer/extrace.c
/*******************************************************************************
 *
 * FUNCTION:    AcpiExStopTraceMethod
 *
 * PARAMETERS:  MethodNode          - Node of the method
 *              ObjDesc             - The method object
 *              WalkState           - current state, NULL if not yet executing
 *                                    a method.
 *
 * RETURN:      None
 *
 * DESCRIPTION: Stop control method execution trace
 *
 ******************************************************************************/
AcpiExStopTraceMethod
PARAMETERS:  MethodNode          - Node of the method
ObjDesc             - The method object
WalkState           - current state, NULL if not yet executing
a method.

None

Stop control method execution trace
AcpiExStopTraceMethod PARAMETERS : MethodNode - Node of the method ObjDesc - The method object WalkState - current state NULL if not yet executing a method . None Stop control method execution trace
void
AcpiExStopTraceMethod (
    ACPI_NAMESPACE_NODE     *MethodNode,
    ACPI_OPERAND_OBJECT     *ObjDesc,
    ACPI_WALK_STATE         *WalkState)
{
    ACPI_STATUS             Status;
    char                    *Pathname = NULL;
    BOOLEAN                 Enabled;
    ACPI_FUNCTION_NAME (ExStopTraceMethod);
    if (MethodNode)
    {
        Pathname = AcpiNsGetNormalizedPathname (MethodNode, TRUE);
    }
    Status = AcpiUtAcquireMutex (ACPI_MTX_NAMESPACE);
    if (ACPI_FAILURE (Status))
    {
        goto ExitPath;
    }
    Enabled = AcpiExInterpreterTraceEnabled (NULL);
    (void) AcpiUtReleaseMutex (ACPI_MTX_NAMESPACE);
    if (Enabled)
    {
        ACPI_TRACE_POINT (ACPI_TRACE_AML_METHOD, FALSE,
            ObjDesc ? ObjDesc->Method.AmlStart : NULL, Pathname);
    }
    Status = AcpiUtAcquireMutex (ACPI_MTX_NAMESPACE);
    if (ACPI_FAILURE (Status))
    {
        goto ExitPath;
    }
    if (AcpiGbl_TraceMethodObject == ObjDesc)
    {
        if (AcpiGbl_TraceFlags & ACPI_TRACE_ONESHOT)
        {
            AcpiGbl_TraceMethodName = NULL;
        }
        AcpiDbgLevel = AcpiGbl_OriginalDbgLevel;
        AcpiDbgLayer = AcpiGbl_OriginalDbgLayer;
        AcpiGbl_TraceMethodObject = NULL;
    }
    (void) AcpiUtReleaseMutex (ACPI_MTX_NAMESPACE);
ExitPath:
    if (Pathname)
    {
        ACPI_FREE (Pathname);
    }
}
void AcpiExStopTraceMethod ( ACPI_NAMESPACE_NODE * MethodNode , ACPI_OPERAND_OBJECT * ObjDesc , ACPI_WALK_STATE * WalkState ) { ACPI_STATUS Status ; char * Pathname = NULL ; BOOLEAN Enabled ; ACPI_FUNCTION_NAME ( ExStopTraceMethod ) ; if ( MethodNode ) { Pathname = AcpiNsGetNormalizedPathname ( MethodNode , TRUE ) ; } Status = AcpiUtAcquireMutex ( ACPI_MTX_NAMESPACE ) ; if ( ACPI_FAILURE ( Status ) ) { goto ExitPath ; } Enabled = AcpiExInterpreterTraceEnabled ( NULL ) ; ( void ) AcpiUtReleaseMutex ( ACPI_MTX_NAMESPACE ) ; if ( Enabled ) { ACPI_TRACE_POINT ( ACPI_TRACE_AML_METHOD , FALSE , ObjDesc ? ObjDesc -> Method . AmlStart : NULL , Pathname ) ; } Status = AcpiUtAcquireMutex ( ACPI_MTX_NAMESPACE ) ; if ( ACPI_FAILURE ( Status ) ) { goto ExitPath ; } if ( AcpiGbl_TraceMethodObject == ObjDesc ) { if ( AcpiGbl_TraceFlags & ACPI_TRACE_ONESHOT ) { AcpiGbl_TraceMethodName = NULL ; } AcpiDbgLevel = AcpiGbl_OriginalDbgLevel ; AcpiDbgLayer = AcpiGbl_OriginalDbgLayer ; AcpiGbl_TraceMethodObject = NULL ; } ( void ) AcpiUtReleaseMutex ( ACPI_MTX_NAMESPACE ) ; ExitPath : if ( Pathname ) { ACPI_FREE ( Pathname ) ; } }
FUNCTION:    AcpiExStopTraceMethod
 PARAMETERS:  MethodNode          - Node of the method
              ObjDesc             - The method object
              WalkState           - current state, NULL if not yet executing
                                    a method.
FUNCTION : AcpiExStopTraceMethod PARAMETERS : MethodNode - Node of the method ObjDesc - The method object WalkState - current state NULL if not yet executing a method .
/* Check whether the tracer should be stopped */ /* Disable further tracing if type is one-shot */