mac80211: keep mesh ifaces in allmulti mode

Currently a mesh node will not forward a multicast frame if it is not subscribed
to the specific multicast address. This patch addresses the issue and fixes mesh
multicast forwarding.

Signed-off-by: Luis Carlos Cobo <luisca@cozybit.com>
Acked-by: Johannes Berg <johannes@sipsolutions.net>
Signed-off-by: John W. Linville <linville@tuxdriver.com>

authored by Luis Carlos Cobo and committed by John W. Linville 8dbc1722 e32f85f7

+7 -1
+7 -1
net/mac80211/main.c
··· 245 245 case IEEE80211_IF_TYPE_AP: 246 246 sdata->bss = &sdata->u.ap; 247 247 break; 248 + case IEEE80211_IF_TYPE_MESH_POINT: 249 + /* mesh ifaces must set allmulti to forward mcast traffic */ 250 + atomic_inc(&local->iff_allmultis); 251 + break; 248 252 case IEEE80211_IF_TYPE_STA: 249 253 case IEEE80211_IF_TYPE_MNTR: 250 254 case IEEE80211_IF_TYPE_IBSS: 251 - case IEEE80211_IF_TYPE_MESH_POINT: 252 255 /* no special treatment */ 253 256 break; 254 257 case IEEE80211_IF_TYPE_INVALID: ··· 498 495 netif_addr_unlock_bh(local->mdev); 499 496 break; 500 497 case IEEE80211_IF_TYPE_MESH_POINT: 498 + /* allmulti is always set on mesh ifaces */ 499 + atomic_dec(&local->iff_allmultis); 500 + /* fall through */ 501 501 case IEEE80211_IF_TYPE_STA: 502 502 case IEEE80211_IF_TYPE_IBSS: 503 503 sdata->u.sta.state = IEEE80211_DISABLED;