qcacld-3.0: Set proper sec channel offset if CSA Wide BW IE is present
If CSA Wide BW IE is present the sec channel offset is always set to
csa_params->sec_chan_offset which is always 0 and thus for next CSA the
BW will always be set to 20 MHz.
To fix this set proper sec channel offset if CSA Wide BW IE is present.
Change-Id: I813b04683cbce3f4f933562c23511de92ce4bcef
CRs-Fixed: 2062475
diff --git a/core/mac/src/pe/lim/lim_send_sme_rsp_messages.c b/core/mac/src/pe/lim/lim_send_sme_rsp_messages.c
index e1faecc..61c3b0b 100644
--- a/core/mac/src/pe/lim/lim_send_sme_rsp_messages.c
+++ b/core/mac/src/pe/lim/lim_send_sme_rsp_messages.c
@@ -2188,7 +2188,16 @@
lim_process_csa_wbw_ie(mac_ctx, csa_params,
chnl_switch_info, session_entry);
lim_ch_switch->sec_ch_offset =
- csa_params->sec_chan_offset;
+ PHY_SINGLE_CHANNEL_CENTERED;
+ if (chnl_switch_info->newChanWidth) {
+ if (csa_params->channel <
+ csa_params->new_ch_freq_seg1)
+ lim_ch_switch->sec_ch_offset =
+ PHY_DOUBLE_CHANNEL_LOW_PRIMARY;
+ else
+ lim_ch_switch->sec_ch_offset =
+ PHY_DOUBLE_CHANNEL_HIGH_PRIMARY;
+ }
} else if (csa_params->ies_present_flag
& lim_xcsa_ie_present) {
chan_space =