summaryrefslogtreecommitdiffstats
path: root/source/components/hardware/hwpci.c
diff options
context:
space:
mode:
authorjkim <jkim@FreeBSD.org>2014-04-25 16:53:42 +0000
committerjkim <jkim@FreeBSD.org>2014-04-25 16:53:42 +0000
commit34dc9d28dcb64ffb397ae86712fcea0cce546203 (patch)
tree643f58d38011b3076bfc6a234d83f22c69487b8c /source/components/hardware/hwpci.c
parent36570d433866fe6dd6cfd1efeaa154ed7ade2121 (diff)
downloadFreeBSD-src-34dc9d28dcb64ffb397ae86712fcea0cce546203.zip
FreeBSD-src-34dc9d28dcb64ffb397ae86712fcea0cce546203.tar.gz
Import ACPICA 20140424.
Diffstat (limited to 'source/components/hardware/hwpci.c')
-rw-r--r--source/components/hardware/hwpci.c13
1 files changed, 10 insertions, 3 deletions
diff --git a/source/components/hardware/hwpci.c b/source/components/hardware/hwpci.c
index 08e5ecc..86017ed 100644
--- a/source/components/hardware/hwpci.c
+++ b/source/components/hardware/hwpci.c
@@ -161,11 +161,12 @@ AcpiHwDerivePciId (
/* Walk the list, updating the PCI device/function/bus numbers */
Status = AcpiHwProcessPciList (PciId, ListHead);
- }
- /* Always delete the list */
+ /* Delete the list */
+
+ AcpiHwDeletePciList (ListHead);
+ }
- AcpiHwDeletePciList (ListHead);
return_ACPI_STATUS (Status);
}
@@ -213,6 +214,9 @@ AcpiHwBuildPciList (
Status = AcpiGetParent (CurrentDevice, &ParentDevice);
if (ACPI_FAILURE (Status))
{
+ /* Must delete the list before exit */
+
+ AcpiHwDeletePciList (*ReturnListHead);
return (Status);
}
@@ -227,6 +231,9 @@ AcpiHwBuildPciList (
ListElement = ACPI_ALLOCATE (sizeof (ACPI_PCI_DEVICE));
if (!ListElement)
{
+ /* Must delete the list before exit */
+
+ AcpiHwDeletePciList (*ReturnListHead);
return (AE_NO_MEMORY);
}
OpenPOWER on IntegriCloud