STATION TABLE - AP STATION IN STA MODE(9)

πŸ“¦ version 7.3.1, in nixpkgs unstable

πŸŽ€ station table - AP Station in STA mode πŸŽ€

ok so this is a page from the Kernel API Manual, and bestie, it's a short one but it's important, so pay attention πŸ’…

✨ NAME ✨

station table β€” AP Station in STA mode. yes that's the whole name. she's concise. we respect it 🫢

🌸 DESCRIPTION 🌸

okay so picture this: iwl_mvm_vif includes the index of the AP station in the fw's STA table, and that index is called ap_sta_id. iconic little field. remember her πŸ’–

so when you've got that ap_sta_id and you need to get the point to the corresponding ieee80211_sta, you use fw_id_to_mac_id. that's the move. that's the lookup. slay πŸ”₯

but here's the part where you really need to listen, because due to the way the fw works, we must not remove the AP station from the fw before setting the MAC context as unassociated. not before. that's the rule. don't do it πŸ™ˆ

and because of that whole situation, fw_id_to_mac_id[ap_sta_id] will be NULLed when the AP station is removed by mac80211 β€” but the station won't be removed in the fw until the VIF is set as unassociated. like, that's when it actually happens. not before. periodt πŸ’€

then, and only then, ap_sta_id will be invalidated. that's the ending of the story. the finale. the last episode 🌈

⭐ lowkey a whole sequence of events, bestie β€” remove by mac80211 β†’ NULL in fw_id_to_mac_id[ap_sta_id] β†’ VIF set as unassociated β†’ station actually removed in fw β†’ ap_sta_id invalidated. order matters, iykyk πŸ‘‘

πŸ¦‹ SEE ALSO πŸ¦‹

go read these next, fr fr, they're all part of the same little universe 🌸

  • Kernel file ./drivers/net/wireless/intel/iwlwifi/mvm/sta.h
  • DQA - Dynamic Queue Allocation -introduction(9)
  • station table - introduction(9)
  • station table - locking(9)
  • station table - internal stations(9)
  • station table - Drain vs. Flush(9)
  • station table - fw restart(9)
  • AP mode - PS(9)
  • enum iwl_mvm_agg_state(9)
  • struct iwl_mvm_tid_data(9)
  • enum iwl_mvm_rxq_notif_type(9)
  • struct iwl_mvm_internal_rxq_notif(9)
  • struct iwl_mvm_rxq_dup_data(9)
  • struct iwl_mvm_link_sta(9)
  • struct iwl_mvm_sta(9)
  • struct iwl_mvm_int_sta(9)
  • iwl_mvm_sta_send_to_fw(9)
  • struct iwl_mvm_sta_state_ops(9)

and that's the whole page, bestie πŸ’œ it lives at ./drivers/net/wireless/intel/i... and it's dated October 2026, so like, from the future?? anyway, go forth and don't remove that AP station too early πŸ§šπŸ’–

πŸ“¦ where this page comes from