[PATCH 00/18] Rework NDC negotiation

Andrei Otcheretianski andrei.otcheretianski at intel.com
Mon Oct 12 08:46:34 PDT 2026


Previously the established NDC wasn't really tracked and the whole NDC
negotiation wasn't done correctly. Multi-channel NDCs were not properly
rejected, even though the code assumes single channel in several places.
Single NDC was never enforced neither. This was good enough to connect a
single peer, but more advanced scenarios were broken.
In addition, mac80211 implemented channel evacuation logic and would
occassionally evacuate the negoatiated NDC channel if it was required
for BSS, breaking existing NDLs. To fix that we need to mark the NDC
channel as non_evac (and thus at least we need to track the negotiated
NDC). This patch series enforces a sole single channel NDC shared with
all the peers and marks that channel as non evacuable.

Note, even though there are no strong dependencies here, this series 
apply cleanly on top of the recently submitted NAN bugfixes and
the instant communication support. It can be certainly reversed, but
some files will conflict.
Channel evacuation support, requires nl80211.h synchronization with
the latest wireless-next.

Andrei Otcheretianski (18):
  NAN: Counter or reject a peer NDC that spans multiple channels
  NAN: Factor out conversion of a channel entry to a channel
  NAN: Match availability channels by their control channel
  tests: hwsim: Verify NDP setup against the peer schedule channels
  NAN: Validate the NDC carried in a received Confirm
  NAN: Validate the NDC carried in an accepted response
  NAN: Factor out writing of the NDC attribute
  NAN: Store and report NDCs advertised by peers
  NAN: Track the NDC established for the data path
  NAN: Reuse the established NDC across all NDLs
  NAN: Advertise the established NDC in SDFs
  tests: hwsim: Verify single NDC establishment and reuse across NDLs
  driver_nl80211: Support NAN set non-evac channels command
  wpa_supplicant: Mark NDC channels as non-evac
  tests: hwsim: Verify that the NDC channel is not evacuated
  NAN: Keep the NDC across local schedule updates
  NAN: Drop dead error checks on the peer schedule dumps
  NAN: Enlarge the SDF reserve for extra attributes

 src/common/nan_de.c               |   2 +-
 src/drivers/driver.h              |  18 ++
 src/drivers/driver_nl80211.c      |  70 ++++-
 src/nan/nan.c                     | 223 ++++++++-----
 src/nan/nan.h                     |  25 +-
 src/nan/nan_i.h                   |  27 +-
 src/nan/nan_module_test_cases.c   |   4 +
 src/nan/nan_ndl.c                 | 342 +++++++++++++++++---
 src/nan/nan_util.c                | 460 ++++++++++++++++-----------
 tests/hwsim/test_nan.py           | 413 ++++++++++++++++++++++++
 wpa_supplicant/driver_i.h         |   9 +
 wpa_supplicant/nan_supplicant.c   | 501 ++++++++++++++++++++++++++----
 wpa_supplicant/wpa_supplicant_i.h |  13 +
 13 files changed, 1733 insertions(+), 374 deletions(-)

-- 
2.53.0




More information about the Hostap mailing list