On Sat, 2008-10-11 at 03:29 +0300, Jouni Malinen wrote: > ieee80211_bss_info_update() can return NULL. Verify that this is not the > case before calling ieee802111_rx_bss_put() which would trigger an oops > in interrupt context in atomic_dec_and_lock(). > > Signed-off-by: Jouni Malinen <jouni.malinen@xxxxxxxxxxx> Acked-by: Johannes Berg <johannes@xxxxxxxxxxxxxxxx> > > Index: wireless-testing/net/mac80211/scan.c > =================================================================== > --- wireless-testing.orig/net/mac80211/scan.c > +++ wireless-testing/net/mac80211/scan.c > @@ -388,7 +388,8 @@ ieee80211_scan_rx(struct ieee80211_sub_i > bss = ieee80211_bss_info_update(sdata->local, rx_status, > mgmt, skb->len, &elems, > freq, beacon); > - ieee80211_rx_bss_put(sdata->local, bss); > + if (bss) > + ieee80211_rx_bss_put(sdata->local, bss); I keep falling into that trap, maybe the put function should just handle NULL instead... johannes
Attachment:
signature.asc
Description: This is a digitally signed message part