From: Ping-Ke Shih <pkshih@realtek.com>
To: ph4ntom-rev <owner@ph4ntom-rev.uz>,
"linux-wireless@vger.kernel.org" <linux-wireless@vger.kernel.org>
Cc: "kvalo@kernel.org" <kvalo@kernel.org>
Subject: RE: [PATCH RFC net-next 0/2] wifi: rtw89: fix monitor mode RX filtering and enable raw packet injection
Date: Mon, 2 Nov 2026 02:11:47 +0000 [thread overview]
Message-ID: <b41e89b40fc640879b9d71b86311f900@realtek.com> (raw)
In-Reply-To: <1a196d6dfbc.35537d221913104450.3720060455831933789@zoho.com>
ph4ntom-rev <owner@ph4ntom-rev.uz> wrote:
> Hi Ping-Ke, Kalle, and linux-wireless maintainers,
>
> This RFC patchset addresses long-standing limitations in rtw89 regarding
> IEEE 802.11 monitor interfaces (NL80211_IFTYPE_MONITOR) and raw frame
> transmission / diagnostic injection (IEEE80211_TX_CTL_INJECTED) on Realtek
> 802.11ax PCIe hardware (specifically verified on RTL8852AE [10ec:8852]).
I can only see this cover letter. Did I miss something?
https://lore.kernel.org/linux-wireless/1a196d6dfbc.35537d221913104450.3720060455831933789@zoho.com/
>
> While rtw89 includes scaffolding for monitor mode (pure_monitor_mode_vif
> and rtw89_core_tx_update_injection), standalone monitor operation hits
> four distinct host-driver obstacles rather than a firmware limitation:
>
> 1. MAC Promiscuous RX Drops:
> Band 0 MAC registers (R_AX_RX_FLTR_OPT 0xCE20, R_AX_CTRL_FLTR 0xCE24,
> and R_AX_DATA_FLTR 0xCE2C) default to filtering out Control frames (ACK,
> RTS, CTS, BlockAck) and non-matching BSSID Data before reaching host
> DMA rings. Setting promiscuous mask 0x55555555 and syncing CRC32 drops
> with FIF_FCSFAIL unlocks all 16 IEEE 802.11 Control and Management
> subtypes across channel switches.
The commit a371139d8be9 ("wifi: rtw89: SNIFFER_MODE bit along IEEE80211_CONF_MONITOR")
added a missing bit B_AX_SNIFFER_MODE, which I suppose it can capture
packets promiscuously. Can you try it?
>
> 2. NULL vif Dereference on Monitor TX:
> In rtw89_ops_tx() and rtw89_core_tx_write(), vif_to_rtwvif(vif) is
> evaluated unconditionally in local declarations before checking whether
> info->control.vif is NULL. Injected Radiotap frames from mac80211 pass
> a NULL control.vif, triggering an immediate kernel oops.
Please add a guard. But I have never encountered the oops. Could you
share the steps?
>
> 3. Injection Descriptor Rate Handling:
> When Radiotap headers omit an explicit bitrate, mac80211 sets
> rates[0].idx = -1. In rtw89_core_tx_update_injection(), casting this to
> u8 yields an invalid rate index 255 and leaves desc_info->en_wd_info
> unset for non-management frames. We map negative indices to a valid
> OFDM 6.0 Mbps fallback (RTW89_HW_RATE_OFDM6), enable hardware rate
> override (use_rate, dis_data_fb), and bound retries (tx_cnt_lmt = 1)
> when IEEE80211_TX_CTL_NO_ACK is set.
OK.
>
> 4. Firmware Scheduler MACID Stalling:
> When mac80211 allocates a standalone monitor VIF, a mac_id is assigned,
> but default CMAC/DMAC tables are never populated and no H2C join is
> issued, leaving the MACID context paused in the firmware scheduler.
> Attempting to join as RTW89_SELF_ROLE_CLIENT triggers firmware 5-second
> beacon-loss timeouts. However, registering a non-associated AP context
> (RTW89_SELF_ROLE_AP with RTW89_NET_TYPE_NO_LINK) initializes the MACID
> queues without generating AP beacons or tracking client beacons. Clearing
> R_AX_MACID_SLEEP_0 (0xC2C0) and sending rtw89_fw_h2c_macid_pause(..., false)
> cleanly unpauses hardware transmit queues.
I'd check this in detail with RFC patch.
next prev parent reply other threads:[~2026-11-02 2:12 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-11-01 11:20 [PATCH RFC net-next 0/2] wifi: rtw89: fix monitor mode RX filtering and enable raw packet injection ph4ntom-rev
2026-11-02 2:11 ` Ping-Ke Shih [this message]
2026-11-02 9:00 ` ph4ntom-rev
2026-11-03 0:54 ` Ping-Ke Shih
2026-11-03 2:44 ` ph4ntom-rev
2026-11-03 15:08 ` [PATCH v2 1/2] wifi: rtw89: fix RX filter configuration for monitor mode ph4ntom-rev
2026-11-03 15:08 ` [PATCH v2 2/2] wifi: rtw89: support raw frame injection on standalone monitor interface ph4ntom-rev
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=b41e89b40fc640879b9d71b86311f900@realtek.com \
--to=pkshih@realtek.com \
--cc=kvalo@kernel.org \
--cc=linux-wireless@vger.kernel.org \
--cc=owner@ph4ntom-rev.uz \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox