@param [in] Node Newly created node.\r
@param [in] ParentNode If provided, set ParentNode as the parent\r
of the node created.\r
- @param [out] NewObjectNode If success, contains the created object node.\r
+ @param [out] NewObjectNode If not NULL:\r
+ - and Success, contains the created Node.\r
+ - and Error, reset to NULL.\r
\r
@retval EFI_SUCCESS The function completed successfully.\r
@retval EFI_INVALID_PARAMETER Invalid parameter.\r
EFI_STATUS Status;\r
\r
if (NewObjectNode != NULL) {\r
- *NewObjectNode = Node;\r
+ *NewObjectNode = NULL;\r
}\r
\r
// Add RdNode as the last element.\r
}\r
}\r
\r
+ if (NewObjectNode != NULL) {\r
+ *NewObjectNode = Node;\r
+ }\r
+\r
return EFI_SUCCESS;\r
}\r
\r
RdNode is then added at the end of the variable\r
list of resource data elements, but before the\r
"End Tag" Resource Data.\r
- @param [out] NewRdNode If not NULL, update the its value to RdNode.\r
+ @param [out] NewRdNode If not NULL:\r
+ - and Success, contains RdNode.\r
+ - and Error, reset to NULL.\r
\r
@retval EFI_SUCCESS The function completed successfully.\r
@retval EFI_INVALID_PARAMETER Invalid parameter.\r
AML_OBJECT_NODE *BufferOpNode;\r
\r
if (NewRdNode != NULL) {\r
- *NewRdNode = RdNode;\r
+ *NewRdNode = NULL;\r
}\r
\r
if (ParentNode != NULL) {\r
}\r
}\r
\r
+ if (NewRdNode != NULL) {\r
+ *NewRdNode = RdNode;\r
+ }\r
+\r
return Status;\r
\r
error_handler:\r
\r
@param [in] SdtHeader Pointer to an ACPI DSDT/SSDT header to copy\r
the data from.\r
- @param [out] NewRootNodePtr The created AML_ROOT_NODE.\r
+ @param [out] NewRootNodePtr If success, contains the created\r
+ AML_ROOT_NODE.\r
+ Otherwise reset to NULL.\r
\r
@retval EFI_SUCCESS The function completed successfully.\r
@retval EFI_INVALID_PARAMETER Invalid parameter.\r
return EFI_INVALID_PARAMETER;\r
}\r
\r
+ *NewRootNodePtr = NULL;\r
+\r
RootNode = AllocateZeroPool (sizeof (AML_ROOT_NODE));\r
if (RootNode == NULL) {\r
ASSERT (0);\r
@param [in] PkgLength PkgLength of the node if the AmlByteEncoding\r
has the PkgLen attribute.\r
0 otherwise.\r
- @param [out] NewObjectNodePtr The created AML_OBJECT_NODE.\r
+ @param [out] NewObjectNodePtr If success, contains the created\r
+ AML_OBJECT_NODE.\r
+ Otherwise reset to NULL.\r
\r
@retval EFI_SUCCESS The function completed successfully.\r
@retval EFI_INVALID_PARAMETER Invalid parameter.\r
return EFI_INVALID_PARAMETER;\r
}\r
\r
+ *NewObjectNodePtr = NULL;\r
+\r
ObjectNode = AllocateZeroPool (sizeof (AML_OBJECT_NODE));\r
if (ObjectNode == NULL) {\r
ASSERT (0);\r
this node. Data is copied from there.\r
@param [in] DataSize Number of bytes to consider at the address\r
pointed by Data.\r
- @param [out] NewDataNodePtr The created AML_DATA_NODE.\r
+ @param [out] NewDataNodePtr If success, contains the created\r
+ AML_DATA_NODE.\r
+ Otherwise reset to NULL.\r
\r
@retval EFI_SUCCESS The function completed successfully.\r
@retval EFI_INVALID_PARAMETER Invalid parameter.\r
return EFI_INVALID_PARAMETER;\r
}\r
\r
+ *NewDataNodePtr = NULL;\r
+\r
DataNode = AllocateZeroPool (sizeof (AML_DATA_NODE));\r
if (DataNode == NULL) {\r
ASSERT (0);\r
\r
@param [in] SdtHeader Pointer to an ACPI DSDT/SSDT header to copy\r
the data from.\r
- @param [out] NewRootNodePtr The created AML_ROOT_NODE.\r
+ @param [out] NewRootNodePtr If success, contains the created\r
+ AML_ROOT_NODE.\r
+ Otherwise reset to NULL.\r
\r
@retval EFI_SUCCESS The function completed successfully.\r
@retval EFI_INVALID_PARAMETER Invalid parameter.\r
@param [in] PkgLength PkgLength of the node if the AmlByteEncoding\r
has the PkgLen attribute.\r
0 otherwise.\r
- @param [out] NewObjectNodePtr The created AML_OBJECT_NODE.\r
+ @param [out] NewObjectNodePtr If success, contains the created\r
+ AML_OBJECT_NODE.\r
+ Otherwise reset to NULL.\r
\r
@retval EFI_SUCCESS The function completed successfully.\r
@retval EFI_INVALID_PARAMETER Invalid parameter.\r
this node. Data is copied from there.\r
@param [in] DataSize Number of bytes to consider at the address\r
pointed by Data.\r
- @param [out] NewDataNodePtr The created AML_DATA_NODE.\r
+ @param [out] NewDataNodePtr If success, contains the created\r
+ AML_DATA_NODE.\r
+ Otherwise reset to NULL.\r
\r
@retval EFI_SUCCESS The function completed successfully.\r
@retval EFI_INVALID_PARAMETER Invalid parameter.\r