From 1684fc165728f428b4dee60799c10bbe7d9a83ea Mon Sep 17 00:00:00 2001 From: Oleg Bulyzhin Date: Mon, 3 Jul 2006 10:37:09 +0000 Subject: [PATCH] Reset autonegotiation timer if current media is not 'auto'. Approved by: glebius (mentor) MFC after: 2 weeks --- sys/dev/mii/mii_physubr.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/sys/dev/mii/mii_physubr.c b/sys/dev/mii/mii_physubr.c index cc60966dacd..281016bcd54 100644 --- a/sys/dev/mii/mii_physubr.c +++ b/sys/dev/mii/mii_physubr.c @@ -213,8 +213,10 @@ mii_phy_tick(struct mii_softc *sc) * status so we can generate an announcement if the status * changes. */ - if (IFM_SUBTYPE(ife->ifm_media) != IFM_AUTO) + if (IFM_SUBTYPE(ife->ifm_media) != IFM_AUTO) { + sc->mii_ticks = 0; /* reset autonegotiation timer. */ return (0); + } /* Read the status register twice; BMSR_LINK is latch-low. */ reg = PHY_READ(sc, MII_BMSR) | PHY_READ(sc, MII_BMSR);