From: Rafael J. Wysocki Date: Fri, 11 Oct 2013 11:20:50 +0000 (+0200) Subject: ACPI / hotplug / PCI: Fix error code path in acpiphp_enumerate_slots() X-Git-Tag: v4.14-rc1~8769^2^2~1 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=5d4494573c1fed806b97c2a1ba619d50bb89d1ed;p=platform%2Fkernel%2Flinux-rpi.git ACPI / hotplug / PCI: Fix error code path in acpiphp_enumerate_slots() 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 Acked-by: Bjorn Helgaas --- diff --git a/drivers/pci/hotplug/acpiphp_glue.c b/drivers/pci/hotplug/acpiphp_glue.c index 0b7d23b4ad95..5042b572609e 100644 --- a/drivers/pci/hotplug/acpiphp_glue.c +++ b/drivers/pci/hotplug/acpiphp_glue.c @@ -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; }