summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorWarner Losh <imp@FreeBSD.org>1999-12-10 07:22:53 +0000
committerWarner Losh <imp@FreeBSD.org>1999-12-10 07:22:53 +0000
commit47c6e6e8498597ab760ce0f1a17ad5e88acc6d77 (patch)
treef546a5fece88f5ef69104eed37eea976ac5bec23
parent88f1ea0a8c53be8f90894f846fef3f99ff5f22a9 (diff)
Notes
-rw-r--r--sys/dev/ed/if_ed.c3
-rw-r--r--sys/dev/ed/if_ed_pccard.c4
-rw-r--r--sys/dev/ed/if_edvar.h1
3 files changed, 5 insertions, 3 deletions
diff --git a/sys/dev/ed/if_ed.c b/sys/dev/ed/if_ed.c
index b355f4fe047d..959d78288900 100644
--- a/sys/dev/ed/if_ed.c
+++ b/sys/dev/ed/if_ed.c
@@ -76,7 +76,6 @@ static int ed_ioctl __P((struct ifnet *, u_long, caddr_t));
static void ed_start __P((struct ifnet *));
static void ed_reset __P((struct ifnet *));
static void ed_watchdog __P((struct ifnet *));
-static void ed_stop __P((struct ed_softc *));
static void ds_getmcaf __P((struct ed_softc *, u_long *));
@@ -1719,7 +1718,7 @@ ed_reset(ifp)
/*
* Take interface offline.
*/
-static void
+void
ed_stop(sc)
struct ed_softc *sc;
{
diff --git a/sys/dev/ed/if_ed_pccard.c b/sys/dev/ed/if_ed_pccard.c
index 549a9a343c65..a8c819abbbb5 100644
--- a/sys/dev/ed/if_ed_pccard.c
+++ b/sys/dev/ed/if_ed_pccard.c
@@ -88,10 +88,12 @@ ed_pccard_detach(device_t dev)
device_printf(dev, "already unloaded\n");
return (0);
}
+ ed_stop(sc);
ifp->if_flags &= ~IFF_RUNNING;
if_detach(ifp);
- bus_teardown_intr(dev, sc->irq_res, &sc->irq_handle);
sc->gone = 1;
+ bus_teardown_intr(dev, sc->irq_res, sc->irq_handle);
+ ed_release_resources(dev);
device_printf(dev, "unload\n");
return (0);
}
diff --git a/sys/dev/ed/if_edvar.h b/sys/dev/ed/if_edvar.h
index b94366e708b6..39db7243a34b 100644
--- a/sys/dev/ed/if_edvar.h
+++ b/sys/dev/ed/if_edvar.h
@@ -102,6 +102,7 @@ int ed_probe_Novell_generic __P((device_t, int, int));
int ed_probe_HP_pclanp __P((device_t));
int ed_attach __P((struct ed_softc *, int, int));
+void ed_stop __P((struct ed_softc *));
driver_intr_t edintr;