Skip to content

Commit

Permalink
PCI: pciehp: wait 100 ms after Link Training check
Browse files Browse the repository at this point in the history
If the port supports Link speeds greater than 5.0 GT/s, we must wait
for 100 ms after Link training completes before sending configuration
request.

Acked-by: Yinghai Lu <yinghai@kernel.org>
Tested-by: Yinghai Lu <yinghai@kernel.org>
Signed-off-by: Kenji Kaneshige <kaneshige.kenji@jp.fujitsu.com>
Signed-off-by: Jesse Barnes <jbarnes@virtuousgeek.org>
  • Loading branch information
Kenji Kaneshige authored and Jesse Barnes committed Nov 11, 2011
1 parent 0027cb3 commit b3c0045
Showing 1 changed file with 8 additions and 0 deletions.
8 changes: 8 additions & 0 deletions drivers/pci/hotplug/pciehp_hpc.c
Original file line number Diff line number Diff line change
Expand Up @@ -302,6 +302,14 @@ int pciehp_check_link_status(struct controller *ctrl)
return retval;
}

/*
* If the port supports Link speeds greater than 5.0 GT/s, we
* must wait for 100 ms after Link training completes before
* sending configuration request.
*/
if (ctrl->pcie->port->subordinate->max_bus_speed > PCIE_SPEED_5_0GT)
msleep(100);

pcie_update_link_speed(ctrl->pcie->port->subordinate, lnk_status);

return retval;
Expand Down

0 comments on commit b3c0045

Please sign in to comment.