summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorwpaul <wpaul@FreeBSD.org>1999-07-22 18:10:20 +0000
committerwpaul <wpaul@FreeBSD.org>1999-07-22 18:10:20 +0000
commitcd1022ef50ba4f9d025ed14ed82aae121048ee34 (patch)
tree8d29d325f908b77143a6511457d2b51d739350d1
parent52eee06a54a722fd13efe839648ef2154e29a263 (diff)
downloadFreeBSD-src-cd1022ef50ba4f9d025ed14ed82aae121048ee34.zip
FreeBSD-src-cd1022ef50ba4f9d025ed14ed82aae121048ee34.tar.gz
Well, it seems that loading a PCI driver module after the system has
been booted works too -- very neat. However I don't want the system to stop for 5 seconds when the MII autoprobe is triggered in the xl and tl drivers since that's lame. Instead, only use the hard delay when we've been cold booted. If not, use the timeout mechanism instead. (The SysKonnect driver doesn't use the same autonegotiation scheme, so no change is required there.)
-rw-r--r--sys/pci/if_tl.c5
-rw-r--r--sys/pci/if_xl.c10
2 files changed, 12 insertions, 3 deletions
diff --git a/sys/pci/if_tl.c b/sys/pci/if_tl.c
index eaceb6e..117d587 100644
--- a/sys/pci/if_tl.c
+++ b/sys/pci/if_tl.c
@@ -1517,7 +1517,10 @@ static int tl_attach_phy(sc)
#ifdef TL_BACKGROUND_AUTONEG
tl_autoneg(sc, TL_FLAG_SCHEDDELAY, 1);
#else
- tl_autoneg(sc, TL_FLAG_FORCEDELAY, 1);
+ if (cold)
+ tl_autoneg(sc, TL_FLAG_FORCEDELAY, 1);
+ else
+ tl_autoneg(sc, TL_FLAG_SCHEDDELAY, 1);
#endif
}
diff --git a/sys/pci/if_xl.c b/sys/pci/if_xl.c
index fad4143..d9ea654 100644
--- a/sys/pci/if_xl.c
+++ b/sys/pci/if_xl.c
@@ -1771,7 +1771,10 @@ xl_attach(dev)
#ifdef XL_BACKGROUND_AUTONEG
xl_autoneg_mii(sc, XL_FLAG_SCHEDDELAY, 1);
#else
- xl_autoneg_mii(sc, XL_FLAG_FORCEDELAY, 1);
+ if (cold)
+ xl_autoneg_mii(sc, XL_FLAG_FORCEDELAY, 1);
+ else
+ xl_autoneg_mii(sc, XL_FLAG_SCHEDDELAY, 1);
#endif
media = sc->ifmedia.ifm_media;
break;
@@ -1780,7 +1783,10 @@ xl_attach(dev)
#ifdef XL_BACKGROUND_AUTONEG
xl_autoneg_mii(sc, XL_FLAG_SCHEDDELAY, 1);
#else
- xl_autoneg_mii(sc, XL_FLAG_FORCEDELAY, 1);
+ if (cold)
+ xl_autoneg_mii(sc, XL_FLAG_FORCEDELAY, 1);
+ else
+ xl_autoneg_mii(sc, XL_FLAG_SCHEDDELAY, 1);
#endif
media = sc->ifmedia.ifm_media;
break;
OpenPOWER on IntegriCloud