diff mbox

[08/10] phb4: Remove retry on electrical link timeout

Message ID 20170720062220.14667-8-mikey@neuling.org
State Accepted
Headers show

Commit Message

Michael Neuling July 20, 2017, 6:22 a.m. UTC
Currently we retry if we don't detect an electrical link. This is
pointless as all devices should respond in the given time.

This patches removes this retry and just returns OPAL_HARDWARE if we
don't detect an electrical link.

This has the additional benefit of improving boot times on machines
that have badly wired presence detect (ie. says a device is present
when there isn't).

Signed-off-by: Michael Neuling <mikey@neuling.org>
---
 hw/phb4.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
diff mbox

Patch

diff --git a/hw/phb4.c b/hw/phb4.c
index f72eb6f962..157074fd24 100644
--- a/hw/phb4.c
+++ b/hw/phb4.c
@@ -2219,7 +2219,7 @@  static int64_t phb4_poll_link(struct pci_slot *slot)
 		if (slot->retries-- == 0) {
 			PHBERR(p, "LINK: Timeout waiting for electrical link\n");
 			PHBDBG(p, "LINK: DLP train control: 0x%016llx\n", reg);
-			return phb4_retry_state(slot);
+			return OPAL_HARDWARE;
 		}
 		return pci_slot_set_sm_timeout(slot, msecs_to_tb(100));
 	case PHB4_SLOT_LINK_WAIT: