PCI: mvebu: Dynamically detect if the PEX link is up to enable hot plug
authorJason Gunthorpe <jgunthorpe@obsidianresearch.com>
Tue, 1 Oct 2013 17:58:00 +0000 (11:58 -0600)
committerJason Cooper <jason@lakedaemon.net>
Tue, 8 Oct 2013 16:45:16 +0000 (16:45 +0000)
Otherwise hotplugging the PEX doesn't work at all since the driver
detects the link state at probe time. Simply replacing the two tests
of haslink with a register read is enough to fix it.

Tested on kirkwood with repeated plug/unplug of the link partner.

Signed-off-by: Jason Gunthorpe <jgunthorpe@obsidianresearch.com>
Acked-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
Tested-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
Signed-off-by: Jason Cooper <jason@lakedaemon.net>

No differences found