# WiFi: need multicast update callback, found cause



## Maelstorm (Oct 20, 2020)

For those who are seeing the message '<driver>x: need multicast update callback,' well, I found the cause.

The cause *IS* a software bug...or in this case a lack of software.  The problem is in the specific wifi device drivers that are experiencing the issue.  In my case, it's the ral driver.  What's happening is that the multicast callback function in the drivers is missing.  The message is coming from the 802.11 wlan framework in /usr/src/sys/net80211/ieee80211.c.  The default function is null_update_mcast and is on line 256 of that file.  Interestingly enough, some drivers have it.  The following WiFi drivers have the required function:

iwn
ath
rtwn
wtap
otus
All the other ones are missing it.  The default function, null_update_mcast, is getting called because the specific drivers are not updating the function pointer in the ieee80211com struct.  Looking at the list that I have, it seems that a number of USB wifi device drivers have it.  I had to dig through the kernel source code to find it.  Here's a list of the drivers that actually have the required software:


```
wildfire:/usr/src/sys 114 ### ->grep -Rn ic_update_mcast *
dev/iwm/if_iwm.c:6077:  ic->ic_update_mcast = iwm_update_mcast;
dev/wi/if_wi.c:435:     ic->ic_update_mcast = wi_update_mcast;
dev/wpi/if_wpi.c:514:   ic->ic_update_mcast = wpi_update_mcast;
dev/usb/wlan/if_rsu.c:596:      ic->ic_update_mcast = rsu_update_mcast;
dev/usb/wlan/if_upgt.c:354:     ic->ic_update_mcast = upgt_update_mcast;
dev/usb/wlan/if_zyd.c:401:      ic->ic_update_mcast = zyd_update_mcast;
dev/usb/wlan/if_urtw.c:902:     ic->ic_update_mcast = urtw_update_mcast;
dev/usb/wlan/if_run.c:832:      ic->ic_update_mcast = run_update_mcast;
dev/usb/wlan/if_uath.c:451:     ic->ic_update_mcast = uath_update_mcast;
dev/usb/wlan/if_rum.c:573:      ic->ic_update_mcast = rum_update_mcast;
dev/mwl/if_mwl.c:473:   ic->ic_update_mcast = mwl_update_mcast;
dev/if_ndis/if_ndis.c:929:      ic->ic_update_mcast = ndis_update_mcast;
dev/iwn/if_iwn.c:672:   ic->ic_update_mcast = iwn_update_mcast;
dev/ath/if_ath.c:1304:  ic->ic_update_mcast = ath_update_mcast;
dev/rtwn/if_rtwn.c:296: ic->ic_update_mcast = rtwn_update_mcast;
dev/wtap/if_wtap.c:662: ic->ic_update_mcast = wtap_update_mcast;
dev/otus/if_otus.c:759: ic->ic_update_mcast = otus_update_mcast;
net80211/ieee80211_ddb.c:636:           DB_PRINTSYM("\t", "ic_update_mcast", ic->ic_update_mcast);
net80211/ieee80211_var.h:303:   void                    (*ic_update_mcast)(struct ieee80211com *);
net80211/ieee80211_proto.c:1373:        ic->ic_update_mcast(ic);
net80211/ieee80211.c:349:       ic->ic_update_mcast = null_update_mcast;
wildfire:/usr/src/sys 115 ### ->
```

Interestingly enough, the promisuous mode update callback functions are missing too...for the same drivers.  I'm not sure if this was deliberate or an oversight.  Perhaps the driver does not need this functionality.  In either case, this is bad form to let it print out an error. I don't know enough about wifi or these drivers in particular to actually write the code to fix this problem.  The best that I can do is add dummy functions to silence the message.  I don't know how this would impact the functionality of multicast routing, but I'm quite sure that multicast routing is used in service provider networks to duplicate audio/video feeds.  I'm going to be sending in a bug report.

UPDATE: PR 250482 has been issues for this problem.


----------



## Alexander88207 (Oct 20, 2020)

Thanks for this information. I saw this message in the console from time to time and wondered what it meant.


----------

