diff options
Diffstat (limited to 'drivers/pci/hotplug/acpiphp_glue.c')
-rw-r--r-- | drivers/pci/hotplug/acpiphp_glue.c | 8 |
1 files changed, 7 insertions, 1 deletions
diff --git a/drivers/pci/hotplug/acpiphp_glue.c b/drivers/pci/hotplug/acpiphp_glue.c index bbe27c16bc3d..610a530232ff 100644 --- a/drivers/pci/hotplug/acpiphp_glue.c +++ b/drivers/pci/hotplug/acpiphp_glue.c | |||
@@ -1592,9 +1592,15 @@ int acpiphp_enable_slot(struct acpiphp_slot *slot) | |||
1592 | if (retval) | 1592 | if (retval) |
1593 | goto err_exit; | 1593 | goto err_exit; |
1594 | 1594 | ||
1595 | if (get_slot_status(slot) == ACPI_STA_ALL) | 1595 | if (get_slot_status(slot) == ACPI_STA_ALL) { |
1596 | /* configure all functions */ | 1596 | /* configure all functions */ |
1597 | retval = enable_device(slot); | 1597 | retval = enable_device(slot); |
1598 | if (retval) | ||
1599 | power_off_slot(slot); | ||
1600 | } else { | ||
1601 | dbg("%s: Slot status is not ACPI_STA_ALL\n", __FUNCTION__); | ||
1602 | power_off_slot(slot); | ||
1603 | } | ||
1598 | 1604 | ||
1599 | err_exit: | 1605 | err_exit: |
1600 | mutex_unlock(&slot->crit_sect); | 1606 | mutex_unlock(&slot->crit_sect); |