summaryrefslogtreecommitdiffstats
path: root/sys/net80211/ieee80211_ioctl.c
diff options
context:
space:
mode:
authorsyrinx <syrinx@FreeBSD.org>2010-01-24 16:17:58 +0000
committersyrinx <syrinx@FreeBSD.org>2010-01-24 16:17:58 +0000
commit40d92428fb5aa102b7ab0489b9b39e999c4bab8e (patch)
treea651df091a85231247b0aa8d6f7042ce9ff2ef4c /sys/net80211/ieee80211_ioctl.c
parentf346ef85e4ce0941c071f15688f353cb189a5b3b (diff)
downloadFreeBSD-src-40d92428fb5aa102b7ab0489b9b39e999c4bab8e.zip
FreeBSD-src-40d92428fb5aa102b7ab0489b9b39e999c4bab8e.tar.gz
While flushing the multicast filter of an interface, do not zero the relevant
ifmultiaddr structures' reference to the parent interface, unless the parent interface is really detaching. While here, program only link layer multicast filters to a wlan's hardware parent interface. PR: kern/142391, kern/142392 Reviewed by: sam, rpaolo, bms MFC after: 1 week
Diffstat (limited to 'sys/net80211/ieee80211_ioctl.c')
-rw-r--r--sys/net80211/ieee80211_ioctl.c7
1 files changed, 5 insertions, 2 deletions
diff --git a/sys/net80211/ieee80211_ioctl.c b/sys/net80211/ieee80211_ioctl.c
index 35c7981..237e556 100644
--- a/sys/net80211/ieee80211_ioctl.c
+++ b/sys/net80211/ieee80211_ioctl.c
@@ -3199,15 +3199,18 @@ ieee80211_ioctl_updatemulti(struct ieee80211com *ic)
void *ioctl;
IEEE80211_LOCK(ic);
- if_purgemaddrs(parent);
+ if_delallmulti(parent);
ioctl = parent->if_ioctl; /* XXX WAR if_allmulti */
parent->if_ioctl = NULL;
TAILQ_FOREACH(vap, &ic->ic_vaps, iv_next) {
struct ifnet *ifp = vap->iv_ifp;
struct ifmultiaddr *ifma;
- TAILQ_FOREACH(ifma, &ifp->if_multiaddrs, ifma_link)
+ TAILQ_FOREACH(ifma, &ifp->if_multiaddrs, ifma_link) {
+ if (ifma->ifma_addr->sa_family != AF_LINK)
+ continue;
(void) if_addmulti(parent, ifma->ifma_addr, NULL);
+ }
}
parent->if_ioctl = ioctl;
ieee80211_runtask(ic, &ic->ic_mcast_task);
OpenPOWER on IntegriCloud