Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

PCI: hotplug: pciehp: wait for 1 second after power off slot

According to the 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.

Signed-off-by: Kenji Kaneshige <kaneshige.kenji@jp.fujitsu.com>
Signed-off-by: Kristen Carlson Accardi <kristen.c.accardi@intel.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>

authored by

Kenji Kaneshige and committed by
Greg Kroah-Hartman
5b57a6ce cca03dec

+12
+12
drivers/pci/hotplug/pciehp_ctrl.c
··· 197 197 __FUNCTION__); 198 198 return; 199 199 } 200 + /* 201 + * After turning power off, we must wait for at least 202 + * 1 second before taking any action that relies on 203 + * power having been removed from the slot/adapter. 204 + */ 205 + msleep(1000); 200 206 } 201 207 } 202 208 ··· 621 615 mutex_unlock(&p_slot->ctrl->crit_sect); 622 616 return -EINVAL; 623 617 } 618 + /* 619 + * After turning power off, we must wait for at least 620 + * 1 second before taking any action that relies on 621 + * power having been removed from the slot/adapter. 622 + */ 623 + msleep(1000); 624 624 } 625 625 626 626 ret = remove_board(p_slot);