Re: [PATCH v4] wifi: mac80211: fix monitor mode frame capture for real chanctx drivers
From: Johannes Berg
Date: Wed Jun 03 2026 - 08:30:54 EST
On Tue, 2026-05-19 at 16:57 -0700, Devin Wittmayer wrote:
>
> Cc: stable@xxxxxxxxxxxxxxx # 6.9+
No. It's known to crash drivers on some versions, so it should
explicitly opt out of stable by
Cc: <stable+noautosel@xxxxxxxxxx> # causes some older drivers to crash
> - if (chanctx_conf)
> + if (chanctx_conf) {
> chandef = &chanctx_conf->def;
> - else if (local->emulate_chanctx)
> - chandef = &local->hw.conf.chandef;
> - else
> - goto fail_rcu;
> + } else {
> + struct ieee80211_chanctx *ctx;
> +
> + ctx = list_first_or_null_rcu(&local->chanctx_list,
> + struct ieee80211_chanctx, list);
> + if (!ctx ||
> + rcu_access_pointer(ctx->list.next) != &local->chanctx_list)
> + goto fail_rcu;
This results in a sparse warning, maybe my loop approach was better
after all.
johannes