STRUCT IEEE80211_IF_NAN(9)

πŸ“¦ version 7.3.1, in nixpkgs unstable

πŸ’… struct ieee80211_if_nan β€” NAN state, bestie

Okay so this is a page straight out of the Kernel API Manual, and honestly? It's giving "niche but iconic." It's struct ieee80211_if_nan, and it holds the ✨ NAN state ✨. Yeah. That's the whole vibe. NAN state. Not energy. Not a single thing else. State. πŸ¦‹


🌸 NAME 🌸

struct ieee80211_if_nan β€” literally just the NAN state. That's it, that's the name section, periodt. πŸ’–


✨ SYNOPSIS ✨

Here's the struct in all its glory β€” copy it exact, don't touch a single character, she's fragile:

struct ieee80211_if_nan {
    struct cfg80211_nan_conf conf;
    bool started;
    struct {
      spinlock_t func_lock;
      struct idr function_inst_ids;
    } de;
    unsigned long removed_channels[BITS_TO_LONGS(
IEEE80211_NAN_MAX_CHANNELS)];
 };

Lowkey a little chaotic formatting-wise but we respect her πŸ™ˆ


πŸŽ€ Members πŸŽ€

Bestie, here's the breakdown of every single field, no skips, no cap:

  • conf β€” the current NAN configuration. The main character of the struct, tbh. πŸ’…
  • started β€” true iff NAN is started. Literally just a truth-teller. If it's true, she's running; if not, she's not. No in-between. πŸ”₯
  • de β€” Discovery Engine state. Important caveat: only valid if !WIPHY_NAN_FLAGS_USERSPACE_DE. So if that flag is set, this field is not it, bestie β€” don't trust it. 😭
    • de.func_lock β€” the lock for de.function_inst_ids. She's the bouncer at the door keeping things safe. 🫢
    • de.function_inst_ids β€” a bitmap of available instance_id's. Yup, a whole bitmap. Available ones. Iconic. ⭐
  • removed_channels β€” a bitmap of channels that should be removed from the NAN schedule once the deferred schedule update is completed. Read that again: once the deferred schedule update is completed. Not before. Do not come for them early. πŸ’€

πŸ‘‘ SEE ALSO πŸ‘‘

Everything else you might wanna go vibe with, all of these fr fr:

  • Kernel file ./net/mac80211/ieee80211_i.h enum
  • ieee80211_bss_corrupt_data_flags(9), enum
  • ieee80211_bss_valid_data_flags(9), enum
  • ieee80211_packet_rx_flags(9), enum
  • ieee80211_rx_flags(9), enum
  • ieee80211_if_ocb(9), struct
  • ieee80211_mesh_sync_ops(9), struct
  • mesh_table(9), struct
  • mesh_tx_cache(9), struct
  • ieee80211_sub_if_data_flags(9), enum
  • ieee80211_sdata_state_bits(9), enum
  • ieee80211_chanctx_mode(9), enum
  • ieee80211_chanctx_replace_state(9), enum
  • txq_info(9), struct
  • ieee80211_if_nan_data(9), struct
  • mac80211_scan_flags(9), enum
  • mac80211_scan_state(9), enum
  • ieee80211_parse_ch_switch_ie(9)
  • struct ieee80211_elems_parse_params(9)

🌈 And that's the whole page, bestie! This gem lives in ./net/mac80211, and the version you're looking at is dated October 2026. Go forth and NAN responsibly. Mwah. πŸ’œπŸŽ€πŸ¦‹

πŸ“¦ where this page comes from