FreeBSD/sys/contrib/dev/acpica/components/namespace/nsalloc.c
/*******************************************************************************
 *
 * FUNCTION:    AcpiNsDeleteChildren
 *
 * PARAMETERS:  ParentNode      - Delete this objects children
 *
 * RETURN:      None.
 *
 * DESCRIPTION: Delete all children of the parent object. In other words,
 *              deletes a "scope".
 *
 ******************************************************************************/
AcpiNsDeleteChildren
PARAMETERS:  ParentNode      - Delete this objects children

None.

Delete all children of the parent object. In other words,
deletes a "scope".
AcpiNsDeleteChildren PARAMETERS : ParentNode - Delete this objects children None . Delete all children of the parent object . In other words deletes a " scope " .
void
AcpiNsDeleteChildren (
    ACPI_NAMESPACE_NODE     *ParentNode)
{
    ACPI_NAMESPACE_NODE     *NextNode;
    ACPI_NAMESPACE_NODE     *NodeToDelete;
    ACPI_FUNCTION_TRACE_PTR (NsDeleteChildren, ParentNode);
    if (!ParentNode)
    {
        return_VOID;
    }
    NextNode = ParentNode->Child;
    while (NextNode)
    {
        if (NextNode->Child)
        {
            ACPI_ERROR ((AE_INFO, "Found a grandchild! P=%p C=%p",
                ParentNode, NextNode));
        }
        NodeToDelete = NextNode;
        NextNode = NextNode->Peer;
        AcpiNsDeleteNode (NodeToDelete);
    };
    ParentNode->Child = NULL;
    return_VOID;
}
void AcpiNsDeleteChildren ( ACPI_NAMESPACE_NODE * ParentNode ) { ACPI_NAMESPACE_NODE * NextNode ; ACPI_NAMESPACE_NODE * NodeToDelete ; ACPI_FUNCTION_TRACE_PTR ( NsDeleteChildren , ParentNode ) ; if ( ! ParentNode ) { return_VOID ; } NextNode = ParentNode -> Child ; while ( NextNode ) { if ( NextNode -> Child ) { ACPI_ERROR ( ( AE_INFO , " " , ParentNode , NextNode ) ) ; } NodeToDelete = NextNode ; NextNode = NextNode -> Peer ; AcpiNsDeleteNode ( NodeToDelete ) ; } ; ParentNode -> Child = NULL ; return_VOID ; }
FUNCTION:    AcpiNsDeleteChildren
 PARAMETERS:  ParentNode      - Delete this objects children
FUNCTION : AcpiNsDeleteChildren PARAMETERS : ParentNode - Delete this objects children
/* Deallocate all children at this level */ /* Grandchildren should have all been deleted already */ /*
         * Delete this child node and move on to the next child in the list.
         * No need to unlink the node since we are deleting the entire branch.
         */ /* Clear the parent's child pointer */