Skip to content

Commit 471e717

Browse files
committed
wifi: ath11k: fix sleeping-in-atomic in ath11k_mac_op_set_bitrate_mask()
JIRA: https://issues.redhat.com/browse/RHEL-114891 CVE: CVE-2025-39732 commit 65c12b1 Author: Baochen Qiang <quic_bqiang@quicinc.com> Date: Tue Jun 3 10:25:28 2025 +0800 wifi: ath11k: fix sleeping-in-atomic in ath11k_mac_op_set_bitrate_mask() ath11k_mac_disable_peer_fixed_rate() is passed as the iterator to ieee80211_iterate_stations_atomic(). Note in this case the iterator is required to be atomic, however ath11k_mac_disable_peer_fixed_rate() does not follow it as it might sleep. Consequently below warning is seen: BUG: sleeping function called from invalid context at wmi.c:304 Call Trace: <TASK> dump_stack_lvl __might_resched.cold ath11k_wmi_cmd_send ath11k_wmi_set_peer_param ath11k_mac_disable_peer_fixed_rate ieee80211_iterate_stations_atomic ath11k_mac_op_set_bitrate_mask.cold Change to ieee80211_iterate_stations_mtx() to fix this issue. Tested-on: WCN6855 hw2.0 PCI WLAN.HSP.1.1-03125-QCAHSPSWPL_V1_V2_SILICONZ_LITE-3.6510.30 Fixes: d5c6515 ("ath11k: driver for Qualcomm IEEE 802.11ax devices") Signed-off-by: Baochen Qiang <quic_bqiang@quicinc.com> Link: https://patch.msgid.link/20250603-ath11k-use-non-atomic-iterator-v1-1-d75762068d56@quicinc.com Signed-off-by: Jeff Johnson <jeff.johnson@oss.qualcomm.com> Signed-off-by: Jose Ignacio Tornos Martinez <jtornosm@redhat.com>
1 parent 4dce6a8 commit 471e717

File tree

1 file changed

+6
-6
lines changed
  • drivers/net/wireless/ath/ath11k

1 file changed

+6
-6
lines changed

drivers/net/wireless/ath/ath11k/mac.c

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -8744,9 +8744,9 @@ ath11k_mac_op_set_bitrate_mask(struct ieee80211_hw *hw,
87448744
arvif->vdev_id, ret);
87458745
return ret;
87468746
}
8747-
ieee80211_iterate_stations_atomic(ar->hw,
8748-
ath11k_mac_disable_peer_fixed_rate,
8749-
arvif);
8747+
ieee80211_iterate_stations_mtx(ar->hw,
8748+
ath11k_mac_disable_peer_fixed_rate,
8749+
arvif);
87508750
} else if (ath11k_mac_bitrate_mask_get_single_nss(ar, arvif, band, mask,
87518751
&single_nss)) {
87528752
rate = WMI_FIXED_RATE_NONE;
@@ -8813,9 +8813,9 @@ ath11k_mac_op_set_bitrate_mask(struct ieee80211_hw *hw,
88138813
}
88148814

88158815
mutex_lock(&ar->conf_mutex);
8816-
ieee80211_iterate_stations_atomic(ar->hw,
8817-
ath11k_mac_disable_peer_fixed_rate,
8818-
arvif);
8816+
ieee80211_iterate_stations_mtx(ar->hw,
8817+
ath11k_mac_disable_peer_fixed_rate,
8818+
arvif);
88198819

88208820
arvif->bitrate_mask = *mask;
88218821
ieee80211_iterate_stations_atomic(ar->hw,

0 commit comments

Comments
 (0)