aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/pci/hotplug/pciehp_hpc.c
diff options
context:
space:
mode:
authorKenji Kaneshige <kaneshige.kenji@jp.fujitsu.com>2008-05-27 06:06:22 -0400
committerJesse Barnes <jbarnes@virtuousgeek.org>2008-05-27 18:43:33 -0400
commit0711c70ec0e9d2c002b1e9b5fb9f21e49d77f4fd (patch)
tree3660b129fe485637baf164e7092b630e5ad3cd19 /drivers/pci/hotplug/pciehp_hpc.c
parent6592e02ae4bd7b277230aa0c5821588a13b9d8e3 (diff)
pciehp: move msleep after power off
According to the PCI Express specification, we must wait for at least 1 second after turning power off before taking any action that relies on power having been removed from the slot/adapter. For this, current pciehp wait for 1 second after issuing the power off command in hpc_power_off_slot() function. But waiting for 1 second in hpc_power_off_slot() can make pciehp probing slow-down because pciehp probe code calls hpc_power_off_slot() if the slot is not occupied just in case. We don't need to wait for 1 second at the pciehp probe time because there is no action on that empty slot. So move 1 second wait from hpc_power_off_slot() to the caller of hpc_power_off_slot(). Signed-off-by: Kenji Kaneshige <kaneshige.kenji@jp.fujitsu.com> Signed-off-by: Kristen Carlson Accardi <kristen.c.accardi@intel.com> Signed-off-by: Jesse Barnes <jbarnes@virtuousgeek.org>
Diffstat (limited to 'drivers/pci/hotplug/pciehp_hpc.c')
-rw-r--r--drivers/pci/hotplug/pciehp_hpc.c7
1 files changed, 0 insertions, 7 deletions
diff --git a/drivers/pci/hotplug/pciehp_hpc.c b/drivers/pci/hotplug/pciehp_hpc.c
index eb631af94738..79f104963166 100644
--- a/drivers/pci/hotplug/pciehp_hpc.c
+++ b/drivers/pci/hotplug/pciehp_hpc.c
@@ -754,13 +754,6 @@ static int hpc_power_off_slot(struct slot * slot)
754 } 754 }
755 dbg("%s: SLOTCTRL %x write cmd %x\n", 755 dbg("%s: SLOTCTRL %x write cmd %x\n",
756 __func__, ctrl->cap_base + SLOTCTRL, slot_cmd); 756 __func__, ctrl->cap_base + SLOTCTRL, slot_cmd);
757
758 /*
759 * After turning power off, we must wait for at least 1 second
760 * before taking any action that relies on power having been
761 * removed from the slot/adapter.
762 */
763 msleep(1000);
764 out: 757 out:
765 if (changed) 758 if (changed)
766 pcie_unmask_bad_dllp(ctrl); 759 pcie_unmask_bad_dllp(ctrl);