Page MenuHomeFreeBSD

[iwn] Flip over to use VAP flags rather than ic flags for things

Authored by adrian on Mar 22 2021, 4:53 PM.



net80211 changed a while back to support per-VAP config for things
rather than it being global. This is to support firmware NICs that
support per-VAP flags and configuration where the firmware will figure
out how to combine them.

However, it introduced a fun timing issue - those changes used to happen
to the shared ic state before newstate() was called, but now they're
also tasks and they can happen /after/.

This isn't a problem for ath(4), but it exposed some interesting
timing and config bugs here. Notably, I saw short slot NOT being
configured in 5GHz mode during some associations, so 5GHz stuff
would hang or behave poorly. Other times the follow-up auth has
the right config, so it didn't hang.

So for now, just flip this over to using the per-VAP flags which
are correct when newstate() is called. net80211 should also have
those flags synch'ed to the global ic state before newstate() runs
and that can come in a subsequent commit.

Whilst here also fix plcp to be consistently logged as a hex value.

Test Plan
  • iwn(4) Intel 6205, STA mode, both 2GHz and 5GHz

Diff Detail

rG FreeBSD src repository
Automatic diff as part of commit; lint not applicable.
Automatic diff as part of commit; unit tests not applicable.

Event Timeline

Scrolling through it looks okay; delayed tasks are not the answer to all questions in the universe it seems ... but that is indeed a story for another day.

This revision is now accepted and ready to land.Mar 23 2021, 9:52 PM