/* Parse the AML stream and populate the root node. */
STATIC EFI_STATUS EFIAPI AmlPopulateRootNode(IN AML_ROOT_NODE *RootNode, IN OUT AML_STREAM *FStream, IN OUT LIST_ENTRY *NameSpaceRefList)
/* Parse the AML stream and populate the root node. */
STATIC EFI_STATUS EFIAPI AmlPopulateRootNode(IN AML_ROOT_NODE *RootNode, IN OUT AML_STREAM *FStream, IN OUT LIST_ENTRY *NameSpaceRefList)
{
  EFI_STATUS  Status;
  if (!IS_AML_ROOT_NODE (RootNode)  ||
      !IS_STREAM (FStream)          ||
      IS_END_OF_STREAM (FStream)    ||
      !IS_STREAM_FORWARD (FStream)  ||
      (NameSpaceRefList == NULL))
  {
    ASSERT (0);
    return EFI_INVALID_PARAMETER;
  }
  Status = AmlParseVariableArguments (
             (AML_NODE_HEADER *)RootNode,
             FStream,
             NameSpaceRefList
             );
  ASSERT_EFI_ERROR (Status);
  return Status;
}