diff options
author | Warner Losh <imp@FreeBSD.org> | 2005-09-08 17:17:13 +0000 |
---|---|---|
committer | Warner Losh <imp@FreeBSD.org> | 2005-09-08 17:17:13 +0000 |
commit | fd410513a976dcb0bb94a5bef25bf3e8b099c66b (patch) | |
tree | eeb200535e2a0c167fc0f003e8dca59839d0e4b9 | |
parent | c16a45fc5bac8f79a6b7fdb0ba7a01cff91ddd9d (diff) | |
download | src-fd410513a976dcb0bb94a5bef25bf3e8b099c66b.tar.gz src-fd410513a976dcb0bb94a5bef25bf3e8b099c66b.zip |
The ed driver lock is already held in the mii frobbing routines. Remove
locking from these routines.
Notes
Notes:
svn path=/head/; revision=149891
-rw-r--r-- | sys/dev/ed/if_ed.c | 11 |
1 files changed, 0 insertions, 11 deletions
diff --git a/sys/dev/ed/if_ed.c b/sys/dev/ed/if_ed.c index d848fe3220d3..3a34488f61e6 100644 --- a/sys/dev/ed/if_ed.c +++ b/sys/dev/ed/if_ed.c @@ -1645,20 +1645,14 @@ ed_miibus_readreg(device_t dev, int phy, int reg) int failed, val; sc = device_get_softc(dev); - - /* XXX is this right? */ - ED_LOCK(sc); (*sc->mii_writebits)(sc, 0xffffffff, 32); (*sc->mii_writebits)(sc, ED_MII_STARTDELIM, ED_MII_STARTDELIM_BITS); (*sc->mii_writebits)(sc, ED_MII_READOP, ED_MII_OP_BITS); (*sc->mii_writebits)(sc, phy, ED_MII_PHY_BITS); (*sc->mii_writebits)(sc, reg, ED_MII_REG_BITS); - failed = (*sc->mii_readbits)(sc, ED_MII_ACK_BITS); val = (*sc->mii_readbits)(sc, ED_MII_DATA_BITS); (*sc->mii_writebits)(sc, ED_MII_IDLE, ED_MII_IDLE_BITS); - /* XXX is this right? */ - ED_UNLOCK(sc); return (failed ? 0 : val); } @@ -1668,9 +1662,6 @@ ed_miibus_writereg(device_t dev, int phy, int reg, int data) struct ed_softc *sc; sc = device_get_softc(dev); - - /* XXX is this right? */ - ED_LOCK(sc); (*sc->mii_writebits)(sc, 0xffffffff, 32); (*sc->mii_writebits)(sc, ED_MII_STARTDELIM, ED_MII_STARTDELIM_BITS); (*sc->mii_writebits)(sc, ED_MII_WRITEOP, ED_MII_OP_BITS); @@ -1679,8 +1670,6 @@ ed_miibus_writereg(device_t dev, int phy, int reg, int data) (*sc->mii_writebits)(sc, ED_MII_TURNAROUND, ED_MII_TURNAROUND_BITS); (*sc->mii_writebits)(sc, data, ED_MII_DATA_BITS); (*sc->mii_writebits)(sc, ED_MII_IDLE, ED_MII_IDLE_BITS); - /* XXX is this right? */ - ED_UNLOCK(sc); } int |