PCI: pciehp: Retrieve link speed after link is trained
authorYinghai Lu <yinghai.lu@oracle.com>
Mon, 7 Nov 2011 15:53:23 +0000 (07:53 -0800)
committerJesse Barnes <jbarnes@virtuousgeek.org>
Mon, 7 Nov 2011 16:07:34 +0000 (08:07 -0800)
During hot plug, board_added will call pciehp_power_on_slot().
But link speed is updated in pciehp_power_on_slot().

We should not update link speed there, because that is too early.

So move the link speed update to pciehp_check_link_status() after making
sure the link has been trained.

-v2: fix compile warning that Kenji found.

Signed-off-by: Yinghai Lu <yinghai.lu@oracle.com>
Reviewed-by: Kenji Kaneshige <kaneshige.kenji@jp.fujitsu.com>
Tested-by: Kenji Kaneshige <kaneshige.kenji@jp.fujitsu.com>
Signed-off-by: Jesse Barnes <jbarnes@virtuousgeek.org>

No differences found