PERFORCE change 37533 for review
Sam Leffler
sam at FreeBSD.org
Thu Sep 4 14:47:21 PDT 2003
http://perforce.freebsd.org/chv.cgi?CH=37533
Change 37533 by sam at sam_ebb on 2003/09/04 14:46:32
Add missing bpfdetach calls. These potentially caused the
driver softc to be modified after free if dhclient was
active as the interface was detached at the 802.11 and Ethernet
layers but not the driver. Consequently when dhclient closed
it's file descriptor the bpf code blindly wrote to the softc
structure.
Affected files ...
.. //depot/projects/netperf/sys/dev/ath/if_ath.c#12 edit
.. //depot/projects/netperf/sys/dev/wi/if_wi.c#7 edit
Differences ...
==== //depot/projects/netperf/sys/dev/ath/if_ath.c#12 (text+ko) ====
@@ -332,6 +332,7 @@
mtx_lock(&sc->sc_mtx);
ath_stop(ifp);
+ bpfdetach(ifp);
ath_desc_free(sc);
ath_hal_detach(sc->sc_ah);
ieee80211_ifdetach(ifp);
==== //depot/projects/netperf/sys/dev/wi/if_wi.c#7 (text+ko) ====
@@ -506,6 +506,9 @@
wi_stop(ifp, 0);
+#if NBPFILTER > 0
+ bpfdetach(ifp);
+#endif
ieee80211_ifdetach(ifp);
WI_UNLOCK(sc);
bus_teardown_intr(dev, sc->irq, sc->wi_intrhand);
More information about the p4-projects
mailing list