diff options
author | Marcus Glocker <mglocker@cvs.openbsd.org> | 2007-09-16 12:15:58 +0000 |
---|---|---|
committer | Marcus Glocker <mglocker@cvs.openbsd.org> | 2007-09-16 12:15:58 +0000 |
commit | 001b9f723b0b77e321ccd722bdecfd73e696f564 (patch) | |
tree | 4a684021aa0b50a277cc026fa5470ff3c54114af | |
parent | 6555d0f34894b30c5995ae2a70e227baddd0ad8b (diff) |
Do sc_disable when device gets stopped.
OK jsg@
-rw-r--r-- | sys/dev/ic/bwi.c | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/sys/dev/ic/bwi.c b/sys/dev/ic/bwi.c index af1815e9e0d..246223eca2a 100644 --- a/sys/dev/ic/bwi.c +++ b/sys/dev/ic/bwi.c @@ -1,4 +1,4 @@ -/* $OpenBSD: bwi.c,v 1.31 2007/09/16 11:52:40 jsg Exp $ */ +/* $OpenBSD: bwi.c,v 1.32 2007/09/16 12:15:57 mglocker Exp $ */ /* * Copyright (c) 2007 The DragonFly Project. All rights reserved. @@ -6377,6 +6377,7 @@ bwi_init(struct ifnet *ifp) return (1); } + /* power on cardbus socket */ if (sc->sc_enable != NULL) (*sc->sc_enable)(sc); @@ -6694,6 +6695,10 @@ bwi_stop(struct bwi_softc *sc) ifp->if_timer = 0; ifp->if_flags &= ~(IFF_RUNNING | IFF_OACTIVE); + /* power off cardbus socket */ + if (sc->sc_disable) + sc->sc_disable(sc); + return (0); } |