Files
RedBear-OS/local
vasilito 9458000df1 redbear-iwlwifi: Rust Mini-MLD layer (mld.rs) — replaces C linux_mld.c logic
Phase 6.2: the MLD driver logic is now Rust, not C. The legacy C
linux_mld.c remains only as a thin transport-level helper (init/parse
functions for C structs used by linux_port.c); all MLD state management,
notification dispatch, TX/scan/sta management, and MLO RX parsing is
now in proper Rust.

src/mld.rs (744 lines):
  - Complete firmware command ID table: all 7 command groups with
    WIDE_ID encoding, 50+ command/notification IDs from Linux fw/api
  - OpMode selection: BZ→iwlmld, others→iwlmvm (Linux iwl-drv.c)
  - MldState: fw_running, radio_kill, scan, TX queue array[512],
    notification counters (AtomicU32)
  - NotifResult: decoded notification (handled/is_rx_frame/signal/rate/
    wide_id/group/cmd/kind)
  - handle_notification(): full WIDE_ID dispatch — all legacy + grouped
    notifications, RX MPDU via parse_rx_mpdu, counted by type
  - parse_rx_mpdu(): MLO RX MPDU parser — link_id from mac_phy_band,
    AMSDU flags, signal/rate via FFI to legacy C Mini-MVM parser
    (no duplicate parser per upstream-first rule)
  - MldState::firmware_init(): records init sequence
  - MldState::start/stop_scan(): scan state management
  - MldState::add/remove_sta(): station ID validation
  - MldState::alloc/free_txq(): TVQM queue allocation
  - FFI to C: rb_iwl_mvm_detect_signal/rate_to_mcs via unsafe extern
  - 11 unit tests covering: opmode selection, WIDE_ID encoding, state
    init, firmware init, TXQ alloc/free, scan management, station
    management, legacy + grouped + unknown notification dispatch,
    notif_kind coverage

All 19 tests pass (11 MLD + 7 existing + 1 integration). The module
is integrated via 'mod mld;' in main.rs.
2026-07-25 00:11:14 +09:00
..