Skip to contentSkip to conversation

FAILED: patch "[PATCH] wifi: cfg80211: fix CQM for non-range use" failed to apply to 6.6-stable tree

PATCH [email protected] 1 participant 1 message Dec 3, 2023

Subsystems (2)
lore
Share & tools
lore

[email protected]

author maintainer
#0 lore raw

The patch below does not apply to the 6.6-stable tree.
If someone wants it applied there, or to any other stable or longterm tree, then please email the backport, including the original git commit id to <[email protected]>.

To reproduce the conflict and resubmit, you may use the following commands:

git fetch https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git/ linux-6.6.y
git checkout FETCH_HEAD
git cherry-pick -x 7e7efdda6adb385fbdfd6f819d76bc68c923c394
# <resolve conflicts, build, test, etc.>
git commit -s
git send-email --to '<[email protected]>' --in-reply-to '2023120319-cubicle-showdown-d666@gregkh' --subject-prefix 'PATCH 6.6.y' HEAD^..

Possible dependencies:

7e7efdda6adb ("wifi: cfg80211: fix CQM for non-range use") 7d6904bf26b9 ("Merge wireless into wireless-next")

thanks,

greg k-h

------------------ original commit in Linus's tree ------------------

From 7e7efdda6adb385fbdfd6f819d76bc68c923c394 Mon Sep 17 00:00:00 2001
From: Johannes Berg <[email protected]>
Date: Mon, 6 Nov 2023 23:17:16 +0100
Subject: [PATCH] wifi: cfg80211: fix CQM for non-range use

My prior race fix here broke CQM when ranges aren't used, as the reporting worker now requires the cqm_config to be set in the wdev, but isn't set when there's no range configured.

Rather than continuing to special-case the range version, set the cqm_config always and configure accordingly, also tracking if range was used or not to be able to clear the configuration appropriately with the same API, which was actually not right if both were implemented by a driver for some reason, as is the case with mac80211 (though there the implementations are equivalent so it doesn't matter.)

Also, the original multiple-RSSI commit lost checking for the callback, so might have potentially crashed if a driver had neither implementation, and userspace tried to use it despite not being advertised as supported.

Fixes 4a4b8169501b ("cfg80211: Accept multiple RSSI thresholds for CQM")
Fixes 37c20b2effe9 ("wifi: cfg80211: fix cqm_config access race")
net/wireless/core.h +1 -0
index 4c692c7faf30..cb61d33d4f1e 100644
@@ -293,6 +293,7 @@ struct cfg80211_cqm_config {
 	u32 rssi_hyst;
 	s32 last_rssi_event_value;
 	enum nl80211_cqm_rssi_threshold_event last_rssi_event_type;
+	bool use_range_api;
 	int n_rssi_thresholds;
 	s32 rssi_thresholds[] __counted_by(n_rssi_thresholds);
 };
net/wireless/nl80211.c +31 -19

87 lines not on this page · raw message