HE: Remove vht_ prefix from bw/seg0/seg1_idx in CSA fallback
These are used for both VHT and HE, so remove the misleading prefix. Signed-off-by: Shashidhar Lakkavalli <slakkavalli@datto.com> Signed-off-by: John Crispin <john@phrozen.org>
This commit is contained in:
parent
f200631c35
commit
f428332d32
1 changed files with 10 additions and 10 deletions
|
@ -3393,29 +3393,29 @@ void
|
|||
hostapd_switch_channel_fallback(struct hostapd_iface *iface,
|
||||
const struct hostapd_freq_params *freq_params)
|
||||
{
|
||||
int vht_seg0_idx = 0, vht_seg1_idx = 0, vht_bw = CHANWIDTH_USE_HT;
|
||||
int seg0_idx = 0, seg1_idx = 0, bw = CHANWIDTH_USE_HT;
|
||||
|
||||
wpa_printf(MSG_DEBUG, "Restarting all CSA-related BSSes");
|
||||
|
||||
if (freq_params->center_freq1)
|
||||
vht_seg0_idx = 36 + (freq_params->center_freq1 - 5180) / 5;
|
||||
seg0_idx = 36 + (freq_params->center_freq1 - 5180) / 5;
|
||||
if (freq_params->center_freq2)
|
||||
vht_seg1_idx = 36 + (freq_params->center_freq2 - 5180) / 5;
|
||||
seg1_idx = 36 + (freq_params->center_freq2 - 5180) / 5;
|
||||
|
||||
switch (freq_params->bandwidth) {
|
||||
case 0:
|
||||
case 20:
|
||||
case 40:
|
||||
vht_bw = CHANWIDTH_USE_HT;
|
||||
bw = CHANWIDTH_USE_HT;
|
||||
break;
|
||||
case 80:
|
||||
if (freq_params->center_freq2)
|
||||
vht_bw = CHANWIDTH_80P80MHZ;
|
||||
bw = CHANWIDTH_80P80MHZ;
|
||||
else
|
||||
vht_bw = CHANWIDTH_80MHZ;
|
||||
bw = CHANWIDTH_80MHZ;
|
||||
break;
|
||||
case 160:
|
||||
vht_bw = CHANWIDTH_160MHZ;
|
||||
bw = CHANWIDTH_160MHZ;
|
||||
break;
|
||||
default:
|
||||
wpa_printf(MSG_WARNING, "Unknown CSA bandwidth: %d",
|
||||
|
@ -3426,9 +3426,9 @@ hostapd_switch_channel_fallback(struct hostapd_iface *iface,
|
|||
iface->freq = freq_params->freq;
|
||||
iface->conf->channel = freq_params->channel;
|
||||
iface->conf->secondary_channel = freq_params->sec_channel_offset;
|
||||
iface->conf->vht_oper_centr_freq_seg0_idx = vht_seg0_idx;
|
||||
iface->conf->vht_oper_centr_freq_seg1_idx = vht_seg1_idx;
|
||||
iface->conf->vht_oper_chwidth = vht_bw;
|
||||
iface->conf->vht_oper_centr_freq_seg0_idx = seg0_idx;
|
||||
iface->conf->vht_oper_centr_freq_seg1_idx = seg1_idx;
|
||||
iface->conf->vht_oper_chwidth = bw;
|
||||
iface->conf->ieee80211n = freq_params->ht_enabled;
|
||||
iface->conf->ieee80211ac = freq_params->vht_enabled;
|
||||
|
||||
|
|
Loading…
Reference in a new issue