Skip to content

RFC refactor station state management

Johannes Berg linux-wireless 1 version In review

Get series with b4
b4 am [email protected]

Versions newest first

  1. v1 RFC Latest4 patches 2 repliesIn review

Patches in v1 No applies recorded yet

#Subject and filesSizeRepliesApplied
1/4mac80211: use station mutex in configurationnet/mac80211/cfg.c+6 -60 replies
2/4mac80211: refactor station state transitionsnet/mac80211/cfg.c net/mac80211/ibss.c net/mac80211/iface.c +5 more+136 -302 replies
3/4mac80211: unwind station state on destroynet/mac80211/sta_info.c net/mac80211/sta_info.h+4 -00 replies
4/4mac80211: count authorized stations per BSSnet/mac80211/debugfs_netdev.c net/mac80211/ieee80211_i.h net/mac80211/sta_info.c +1 more+20 -160 replies

Reviews trailers per patch

No Reviewed-by, Acked-by or Tested-by trailers for v1 yet.

Read the v1 thread

Cover letter [RFC 0/4] refactor station state management

Here's a first step towards something I talked to some of you about -- making drivers more aware of station state.

Because experience tells me that drivers will be written for the common case, and forget about uncommon sequences, this first step enforces proper ordering of states, now a station can move only between these states like this:
NONE <--> AUTHENTICATED <--> ASSOCIATED <--> AUTHORIZED

As a consequence, IBSS stations and WDS peers need to go through ASSOCIATED state (and get ASSOC flag set), but this doesn't seem to be an issue, in fact it makes at least one place in the code simpler.

This patchset still has two issues:
* secure mesh is broken right now I think, its state change possibilities are rather confusing (need help to fix this, at least explanations)
* TLDS isn't handled (maybe not an issue?)

My further plan is the following:
1) figure out the issues above
2) notify drivers of these state changes
3) refactor auth/assoc process as described before
a) don't track multiple authentications
b) don't try to keep an existing authentication/association
c) set channel first etc.
4) remove dummy station code
a) add regular station entry before auth
b) notify to AUTH state when auth succeeds
c) notify to ASSOC state when assoc succeeds

This patchset is but the first step on this journey, at the end of which we will hopefully find multi-channel support :-)

johannes