Don't assume page register value is 0 and restore previous page

register after issuing 'powerup'.
This commit is contained in:
Pyun YongHyeon 2009-06-02 00:21:30 +00:00
parent c3655fa4f2
commit 3e6843d1d7

View File

@ -239,11 +239,13 @@ e1000phy_reset(struct mii_softc *sc)
PHY_WRITE(sc, E1000_SCR, reg);
if (esc->mii_model == MII_MODEL_MARVELL_E1116) {
page = PHY_READ(sc, E1000_EADR);
/* Select page 2, MAC specific control register. */
PHY_WRITE(sc, E1000_EADR, 2);
reg = PHY_READ(sc, E1000_SCR);
reg |= E1000_SCR_RGMII_POWER_UP;
PHY_WRITE(sc, E1000_SCR, reg);
PHY_WRITE(sc, E1000_EADR, 0);
PHY_WRITE(sc, E1000_EADR, page);
}
}