On 12/12/15(Sat) 00:19, Stefan Sperling wrote: > On Sat, Dec 12, 2015 at 12:09:17AM +0100, Stefan Sperling wrote: > > Here's an updated diff, which applies to -current, for testing. > > I'll spend some time tomorrow splitting this up into smaller > > chunks for review with explanations of the changes. > > > > No known problems exist with this diff. > > Please test anywhere, even without iwm(4). Thanks. > > > > For some reason, a rouge pci/if_iwm.c file sneaked into > the previous diff. Sorry about that.
> Index: net80211/ieee80211_input.c > =================================================================== > RCS file: /cvs/src/sys/net80211/ieee80211_input.c,v > retrieving revision 1.142 > diff -u -p -r1.142 ieee80211_input.c > --- net80211/ieee80211_input.c 15 Nov 2015 11:14:17 -0000 1.142 > +++ net80211/ieee80211_input.c 11 Dec 2015 22:43:24 -0000 > @@ -1569,10 +1597,13 @@ ieee80211_recv_probe_resp(struct ieee802 > */ > if (ni->ni_flags & IEEE80211_NODE_QOS) { > /* always prefer EDCA IE over Wi-Fi Alliance WMM IE */ > - if (edcaie != NULL) > - ieee80211_parse_edca_params(ic, edcaie); > - else if (wmmie != NULL) > - ieee80211_parse_wmm_params(ic, wmmie); > + if ((edcaie != NULL && > + ieee80211_parse_edca_params(ic, edcaie) == 0) || > + (wmmie != NULL && > + ieee80211_parse_wmm_params(ic, wmmie) == 0)) > + ni->ni_flags |= IEEE80211_NODE_QOS; > + else > + ni->ni_flags &= ~IEEE80211_NODE_QOS; I like the code unification but I find a bit confusing that IEEE80211_NODE_QOS is checked/set twice. What should a client do if QoS has been negotiated during association and then the kernel fails tp parse EDCA/WMMIE params? Is it correct to unset IEEE80211_NODE_QOS here? But I don't think this should prevent you from committing this. You have my ok.