Skip to content

Commit

Permalink
ACPI / hotplug / PCI: Fix error code path in acpiphp_enumerate_slots()
Browse files Browse the repository at this point in the history
One of the error code paths in acpiphp_enumerate_slots() is missing
a pci_dev_put(bridge->pci_dev) call, so add it.

Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com>
Acked-by: Bjorn Helgaas <bhelgaas@google.com>
  • Loading branch information
Rafael J. Wysocki committed Oct 11, 2013
1 parent d0e639c commit 5d44945
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions drivers/pci/hotplug/acpiphp_glue.c
Original file line number Diff line number Diff line change
Expand Up @@ -1002,6 +1002,7 @@ void acpiphp_enumerate_slots(struct pci_bus *bus)
if (WARN_ON(!context)) {
mutex_unlock(&acpiphp_context_lock);
put_device(&bus->dev);
pci_dev_put(bridge->pci_dev);
kfree(bridge);
return;
}
Expand Down

0 comments on commit 5d44945

Please sign in to comment.