summaryrefslogtreecommitdiffstats
path: root/drivers/pci/hotplug/pciehp_ctrl.c
diff options
context:
space:
mode:
authorYijing Wang2014-02-12 01:36:51 +0100
committerBjorn Helgaas2014-02-14 18:13:56 +0100
commit50277c8b06d56f2345e1a0693db46db29fc6d063 (patch)
tree8593272fd1307dbcd6b0d1f675eec3b12e85b1f4 /drivers/pci/hotplug/pciehp_ctrl.c
parentPCI: pciehp: Add hotplug_lock to serialize hotplug events (diff)
downloadkernel-qcow2-linux-50277c8b06d56f2345e1a0693db46db29fc6d063.tar.gz
kernel-qcow2-linux-50277c8b06d56f2345e1a0693db46db29fc6d063.tar.xz
kernel-qcow2-linux-50277c8b06d56f2345e1a0693db46db29fc6d063.zip
PCI: pciehp: Don't turn slot off when hot-added device already exists
If we found device already exists during hot add device, we should leave it, not turn the slot off. Signed-off-by: Yijing Wang <wangyijing@huawei.com> Signed-off-by: Bjorn Helgaas <bhelgaas@google.com>
Diffstat (limited to 'drivers/pci/hotplug/pciehp_ctrl.c')
-rw-r--r--drivers/pci/hotplug/pciehp_ctrl.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/drivers/pci/hotplug/pciehp_ctrl.c b/drivers/pci/hotplug/pciehp_ctrl.c
index fec99a164d93..b4a4ac150e61 100644
--- a/drivers/pci/hotplug/pciehp_ctrl.c
+++ b/drivers/pci/hotplug/pciehp_ctrl.c
@@ -233,7 +233,8 @@ static int board_added(struct slot *p_slot)
if (retval) {
ctrl_err(ctrl, "Cannot add device at %04x:%02x:00\n",
pci_domain_nr(parent), parent->number);
- goto err_exit;
+ if (retval != -EEXIST)
+ goto err_exit;
}
pciehp_green_led_on(p_slot);