mirror of
https://github.com/torvalds/linux.git
synced 2026-11-07 06:17:02 +01:00
wifi: mac80211: set SP in reg connectivity with any channel
The regulatory connectivity element is informational and for debug, per spec, but that didn't stop some situations/tests from requiring certain bits to be set, notably the SP bit to be set if any channel is available for AFC client behaviour, even if that seems to reduce the utility of the bit. Set the bit accordingly by initialising the flags to NO_AFC and then masking for all enabled channels. Signed-off-by: Johannes Berg <johannes.berg@intel.com> Reviewed-by: Emmanuel Grumbach <emmanuel.grumbach@intel.com> Signed-off-by: Miri Korenblit <miriam.rachel.korenblit@intel.com> Link: https://patch.msgid.link/20260930120507.2ba7e2905019.I6d589cf60434ba9d3e007fe4537c8c8e2aeb7415@changeid Signed-off-by: Johannes Berg <johannes.berg@intel.com>
This commit is contained in:
parent
1a86b4fac9
commit
c8189e0929
|
|
@ -2731,13 +2731,13 @@ int ieee80211_put_he_cap(struct sk_buff *skb,
|
|||
void ieee80211_put_reg_conn(struct ieee80211_sub_if_data *sdata,
|
||||
struct sk_buff *skb)
|
||||
{
|
||||
u32 flags = IEEE80211_CHAN_NO_6GHZ_AFC_CLIENT;
|
||||
struct ieee80211_local *local = sdata->local;
|
||||
u8 reg_conn = IEEE80211_REG_CONN_LPI_VALID |
|
||||
IEEE80211_REG_CONN_LPI_VALUE |
|
||||
IEEE80211_REG_CONN_SP_VALID;
|
||||
struct ieee80211_supported_band *sband;
|
||||
bool available_channels = false;
|
||||
u32 flags = 0;
|
||||
int i;
|
||||
|
||||
sband = local->hw.wiphy->bands[NL80211_BAND_6GHZ];
|
||||
|
|
@ -2747,7 +2747,7 @@ void ieee80211_put_reg_conn(struct ieee80211_sub_if_data *sdata,
|
|||
for (i = 0; i < sband->n_channels; i++) {
|
||||
if (sband->channels[i].flags & IEEE80211_CHAN_DISABLED)
|
||||
continue;
|
||||
flags |= sband->channels[i].flags;
|
||||
flags &= sband->channels[i].flags;
|
||||
available_channels = true;
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Reference in New Issue
Block a user