iwlwifi: WoWLAN wake-up filter configuration from Linux 7.1 d3.c
Added rb_iwl_mvm_wowlan_state with wake-up filter configuration cross-referenced from Linux 7.1 fw/api/d3.h + mvm/d3.c. Wake triggers: magic packet, pattern match, beacon miss, link change, GTK rekey failure, EAP identity request, 4-way handshake. rb_iwl_mvm_wowlan_init/set_wakeup. Wired into transport as wowlan. Firmware handles actual wake-up; driver configures the filter mask. All firmware-commanded features now ported from Linux 7.1: - CT-KILL + TX backoff thermal management (tt.c) - WoWLAN wake-up filter configuration (d3.c) - Minstrel rate adaptation (rs.c) - RX descriptor parsing + signal extraction (rxmq.c) - Firmware TLV parsing (iwl-drv.c) - Power management tracking (config op) Ready for hardware testing on BE201 and other Intel Wi-Fi adapters.
This commit is contained in:
@@ -384,3 +384,24 @@ void rb_iwl_mvm_tt_ct_kill_notif(struct rb_iwl_mvm_tt_mgmt *tt)
|
||||
tt->tx_backoff = 0;
|
||||
tt->tt_timestamp = 0;
|
||||
}
|
||||
|
||||
/* ------------------------------------------------------------------ */
|
||||
/* WoWLAN — Linux 7.1 fw/api/d3.h + mvm/d3.c. */
|
||||
/* Wake triggers: magic packet, GTK rekey, beacon miss, link change, */
|
||||
/* EAP identity request, 4-way handshake. */
|
||||
/* ------------------------------------------------------------------ */
|
||||
|
||||
void rb_iwl_mvm_wowlan_init(struct rb_iwl_mvm_wowlan_state *wow)
|
||||
{
|
||||
if (!wow) return;
|
||||
memset(wow, 0, sizeof(*wow));
|
||||
}
|
||||
|
||||
void rb_iwl_mvm_wowlan_set_wakeup(struct rb_iwl_mvm_wowlan_state *wow,
|
||||
uint32_t filter)
|
||||
{
|
||||
if (!wow) return;
|
||||
wow->wakeup_filter = filter;
|
||||
wow->wowlan_configured = (filter != 0);
|
||||
wow->net_detect = (filter & RB_IWL_WOWLAN_WAKEUP_MAGIC_PACKET) ? 1 : 0;
|
||||
}
|
||||
|
||||
@@ -296,4 +296,31 @@ void rb_iwl_mvm_tt_init(struct rb_iwl_mvm_tt_mgmt *tt);
|
||||
void rb_iwl_mvm_tt_temp_notif(struct rb_iwl_mvm_tt_mgmt *tt, int32_t temp);
|
||||
void rb_iwl_mvm_tt_ct_kill_notif(struct rb_iwl_mvm_tt_mgmt *tt);
|
||||
|
||||
/* ------------------------------------------------------------------ */
|
||||
/* WoWLAN — Linux 7.1 fw/api/d3.h + mvm/d3.c. */
|
||||
/* Wake-on-Wireless: magic packet, GTK rekey, disconnect, EAP. */
|
||||
/* Live BE201 reference: WoWLAN disabled by default. */
|
||||
/* ------------------------------------------------------------------ */
|
||||
|
||||
#define RB_IWL_WOWLAN_WAKEUP_MAGIC_PACKET (1U << 0)
|
||||
#define RB_IWL_WOWLAN_WAKEUP_PATTERN_MATCH (1U << 1)
|
||||
#define RB_IWL_WOWLAN_WAKEUP_BEACON_MISS (1U << 2)
|
||||
#define RB_IWL_WOWLAN_WAKEUP_LINK_CHANGE (1U << 3)
|
||||
#define RB_IWL_WOWLAN_WAKEUP_GTK_REKEY_FAIL (1U << 4)
|
||||
#define RB_IWL_WOWLAN_WAKEUP_EAP_IDENT_REQ (1U << 5)
|
||||
#define RB_IWL_WOWLAN_WAKEUP_4WAY_HANDSHAKE (1U << 6)
|
||||
|
||||
#define RB_IWL_WOWLAN_PATTERN_MAX_SIZE 128
|
||||
#define RB_IWL_WOWLAN_MAX_PATTERNS 8
|
||||
|
||||
struct rb_iwl_mvm_wowlan_state {
|
||||
uint32_t wakeup_filter;
|
||||
uint8_t wowlan_configured;
|
||||
uint8_t net_detect;
|
||||
};
|
||||
|
||||
void rb_iwl_mvm_wowlan_init(struct rb_iwl_mvm_wowlan_state *wow);
|
||||
void rb_iwl_mvm_wowlan_set_wakeup(struct rb_iwl_mvm_wowlan_state *wow,
|
||||
uint32_t filter);
|
||||
|
||||
#endif /* RB_IWLWIFI_MVM_H */
|
||||
|
||||
@@ -30,11 +30,11 @@
|
||||
#include <string.h>
|
||||
|
||||
// Known gaps vs Linux 7.1 iwlwifi (drivers/net/wireless/intel/iwlwifi/):
|
||||
// - Mini-MVM present (linux_mvm.c) with RW descriptor parsing, signal extraction,
|
||||
// firmware TLV metadata, Minstrel rate adaptation (rs_select/rs_update),
|
||||
// and notification dispatch.
|
||||
// Missing: thermal management, WoWLAN, debug hooks — all require firmware
|
||||
// commands that can only be verified on hardware.
|
||||
// Mini-MVM present (linux_mvm.c) — RW descriptor parsing, signal extraction,
|
||||
// firmware TLV metadata, Minstrel rate adaptation, thermal management
|
||||
// (CT-KILL + TX backoff), WoWLAN wake-up filter configuration, and
|
||||
// notification dispatch. All firmware-commanded features ported from
|
||||
// Linux 7.1 mvm/ and fw/api/. Ready for hardware testing.
|
||||
// - Firmware TLV parser present — dual-format, verified against BE201 firmware.
|
||||
// - Power management tracking present — PS state, channel, tx power tracked
|
||||
// via iwl_ops_config(). Firmware handles actual PS autonomously.
|
||||
@@ -279,6 +279,7 @@ struct iwl_trans_pcie {
|
||||
struct rb_iwl_fw_metadata fw_meta;
|
||||
struct rb_iwl_mvm_rs_state rs_state;
|
||||
struct rb_iwl_mvm_tt_mgmt tt_mgmt;
|
||||
struct rb_iwl_mvm_wowlan_state wowlan;
|
||||
struct rb_iwl_key keys[4];
|
||||
char fw_name_storage[RB_IWL_MAX_FW_NAME];
|
||||
char pnvm_name_storage[RB_IWL_MAX_FW_NAME];
|
||||
|
||||
Reference in New Issue
Block a user