mirror of
https://github.com/BobTheBlinker/android_kernel_motorola_sm6375.git
synced 2026-10-12 07:37:31 -04:00
qcacld-3.0: Add ini option for action frame based channel switch
qcacld-2.0 to qcacld-3.0 propagation Add ini option to enable/disable action frame based channel switch. Change-Id: I340464a18ef0b5cf09f481a23b01edcf04904e34 CRs-Fixed: 2082563
This commit is contained in:
parent
71c779adea
commit
e2920bda2b
9 changed files with 47 additions and 5 deletions
|
|
@ -10674,6 +10674,26 @@ enum l1ss_sleep_allowed {
|
|||
#define CFG_ENABLE_REG_OFFLOAD_MAX (1)
|
||||
#define CFG_ENABLE_REG_OFFLOAD_DEFAULT (1)
|
||||
|
||||
/*
|
||||
* <ini>
|
||||
* g_sap_chanswitch_beacon_cnt - channel switch beacon count
|
||||
* @Min: 1
|
||||
* @Max: 5
|
||||
* @Default: 5
|
||||
*
|
||||
* This ini is used to configure channel switch beacon count
|
||||
*
|
||||
* Related: none
|
||||
*
|
||||
* Usage: External
|
||||
*
|
||||
* </ini>
|
||||
*/
|
||||
#define CFG_SAP_CH_SWITCH_BEACON_CNT "g_sap_chanswitch_beacon_cnt"
|
||||
#define CFG_SAP_CH_SWITCH_BEACON_CNT_MIN (1)
|
||||
#define CFG_SAP_CH_SWITCH_BEACON_CNT_MAX (5)
|
||||
#define CFG_SAP_CH_SWITCH_BEACON_CNT_DEFAULT (5)
|
||||
|
||||
/*
|
||||
* <ini>
|
||||
* g_fils_max_chan_guard_time - Set maximum channel guard time(ms)
|
||||
|
|
@ -11789,6 +11809,8 @@ struct hdd_config {
|
|||
bool sta_prefer_80MHz_over_160MHz;
|
||||
uint8_t sap_max_inactivity_override;
|
||||
bool fw_timeout_crash;
|
||||
/* beacon count before channel switch */
|
||||
uint8_t sap_chanswitch_beacon_cnt;
|
||||
uint32_t rx_wakelock_timeout;
|
||||
uint32_t max_sched_scan_plan_interval;
|
||||
uint32_t max_sched_scan_plan_iterations;
|
||||
|
|
|
|||
|
|
@ -4227,6 +4227,12 @@ struct reg_table_entry g_registry_table[] = {
|
|||
CFG_RX_WAKELOCK_TIMEOUT_DEFAULT,
|
||||
CFG_RX_WAKELOCK_TIMEOUT_MIN,
|
||||
CFG_RX_WAKELOCK_TIMEOUT_MAX),
|
||||
REG_VARIABLE(CFG_SAP_CH_SWITCH_BEACON_CNT, WLAN_PARAM_Integer,
|
||||
struct hdd_config, sap_chanswitch_beacon_cnt,
|
||||
VAR_FLAGS_OPTIONAL | VAR_FLAGS_RANGE_CHECK_ASSUME_DEFAULT,
|
||||
CFG_SAP_CH_SWITCH_BEACON_CNT_DEFAULT,
|
||||
CFG_SAP_CH_SWITCH_BEACON_CNT_MIN,
|
||||
CFG_SAP_CH_SWITCH_BEACON_CNT_MAX),
|
||||
REG_VARIABLE(CFG_MAX_SCHED_SCAN_PLAN_INT_NAME, WLAN_PARAM_Integer,
|
||||
struct hdd_config, max_sched_scan_plan_interval,
|
||||
VAR_FLAGS_OPTIONAL | VAR_FLAGS_RANGE_CHECK_ASSUME_DEFAULT,
|
||||
|
|
|
|||
|
|
@ -7521,6 +7521,8 @@ int wlan_hdd_cfg80211_start_bss(hdd_adapter_t *pHostapdAdapter,
|
|||
pConfig->dfs_cac_offload = pHddCtx->dfs_cac_offload;
|
||||
|
||||
pConfig->disableDFSChSwitch = iniConfig->disableDFSChSwitch;
|
||||
pConfig->sap_chanswitch_beacon_cnt =
|
||||
iniConfig->sap_chanswitch_beacon_cnt;
|
||||
|
||||
/* channel is already set in the set_channel Call back */
|
||||
/* pConfig->channel = pCommitConfig->channel; */
|
||||
|
|
|
|||
|
|
@ -3984,6 +3984,7 @@ typedef struct sSirDfsCsaIeRequest {
|
|||
uint8_t csaIeRequired;
|
||||
uint8_t bssid[QDF_MAC_ADDR_SIZE];
|
||||
struct ch_params ch_params;
|
||||
uint8_t ch_switch_beacon_cnt;
|
||||
} tSirDfsCsaIeRequest, *tpSirDfsCsaIeRequest;
|
||||
|
||||
/* Indication from lower layer indicating the completion of first beacon send
|
||||
|
|
|
|||
|
|
@ -67,7 +67,6 @@
|
|||
((LIntrvl * LIM_TIM_WAIT_COUNT_FACTOR) > LIM_MIN_TIM_WAIT_COUNT ? \
|
||||
(LIntrvl * LIM_TIM_WAIT_COUNT_FACTOR) : LIM_MIN_TIM_WAIT_COUNT)
|
||||
|
||||
#define LIM_MAX_CSA_IE_UPDATES (5)
|
||||
|
||||
/* enums exported by LIM are as follows */
|
||||
|
||||
|
|
|
|||
|
|
@ -5804,7 +5804,7 @@ static void send_extended_chan_switch_action_frame(tpAniSirGlobal mac_ctx,
|
|||
uint16_t op_class;
|
||||
uint8_t switch_mode = 0, i;
|
||||
tpDphHashNode psta;
|
||||
|
||||
uint8_t switch_count;
|
||||
|
||||
op_class = wlan_reg_dmn_get_opclass_from_channel(
|
||||
mac_ctx->scan.countryCodeCurrent,
|
||||
|
|
@ -5815,6 +5815,8 @@ static void send_extended_chan_switch_action_frame(tpAniSirGlobal mac_ctx,
|
|||
(mac_ctx->sap.SapDfsInfo.disable_dfs_ch_switch == false))
|
||||
switch_mode = 1;
|
||||
|
||||
switch_count = session_entry->gLimChannelSwitch.switchCount;
|
||||
|
||||
if (LIM_IS_AP_ROLE(session_entry)) {
|
||||
for (i = 0; i <= mac_ctx->lim.maxStation; i++) {
|
||||
psta =
|
||||
|
|
@ -5824,13 +5826,13 @@ static void send_extended_chan_switch_action_frame(tpAniSirGlobal mac_ctx,
|
|||
mac_ctx,
|
||||
psta->staAddr,
|
||||
switch_mode, op_class, new_channel,
|
||||
LIM_MAX_CSA_IE_UPDATES, session_entry);
|
||||
switch_count, session_entry);
|
||||
}
|
||||
} else if (LIM_IS_STA_ROLE(session_entry)) {
|
||||
lim_send_extended_chan_switch_action_frame(mac_ctx,
|
||||
session_entry->bssId,
|
||||
switch_mode, op_class, new_channel,
|
||||
LIM_MAX_CSA_IE_UPDATES, session_entry);
|
||||
switch_count, session_entry);
|
||||
}
|
||||
|
||||
}
|
||||
|
|
@ -5881,7 +5883,8 @@ static void lim_process_sme_dfs_csa_ie_request(tpAniSirGlobal mac_ctx,
|
|||
|
||||
/* Channel switch announcement needs to be included in beacon */
|
||||
session_entry->dfsIncludeChanSwIe = true;
|
||||
session_entry->gLimChannelSwitch.switchCount = LIM_MAX_CSA_IE_UPDATES;
|
||||
session_entry->gLimChannelSwitch.switchCount =
|
||||
dfs_csa_ie_req->ch_switch_beacon_cnt;
|
||||
session_entry->gLimChannelSwitch.ch_width =
|
||||
dfs_csa_ie_req->ch_params.ch_width;
|
||||
session_entry->gLimChannelSwitch.sec_ch_offset =
|
||||
|
|
|
|||
|
|
@ -628,6 +628,8 @@ typedef struct sap_Config {
|
|||
struct hdd_channel_info *channel_info;
|
||||
uint32_t channel_info_count;
|
||||
bool dfs_cac_offload;
|
||||
/* beacon count before channel switch */
|
||||
uint8_t sap_chanswitch_beacon_cnt;
|
||||
} tsap_Config_t;
|
||||
|
||||
#ifdef FEATURE_WLAN_AP_AP_ACS_OPTIMIZE
|
||||
|
|
@ -734,6 +736,8 @@ typedef struct sSapDfsInfo {
|
|||
*/
|
||||
uint8_t disable_dfs_ch_switch;
|
||||
uint16_t tx_leakage_threshold;
|
||||
/* beacon count before channel switch */
|
||||
uint8_t sap_ch_switch_beacon_cnt;
|
||||
} tSapDfsInfo;
|
||||
|
||||
typedef struct tagSapCtxList {
|
||||
|
|
|
|||
|
|
@ -947,6 +947,9 @@ QDF_STATUS wlansap_start_bss(void *pCtx, /* pwextCtx */
|
|||
*/
|
||||
pmac->sap.SapDfsInfo.disable_dfs_ch_switch =
|
||||
pConfig->disableDFSChSwitch;
|
||||
pmac->sap.SapDfsInfo.sap_ch_switch_beacon_cnt =
|
||||
pConfig->sap_chanswitch_beacon_cnt;
|
||||
|
||||
pmac->sap.sapCtxList[pSapCtx->sessionId].pSapContext = pSapCtx;
|
||||
pmac->sap.sapCtxList[pSapCtx->sessionId].sapPersona =
|
||||
pSapCtx->csr_roamProfile.csrPersona;
|
||||
|
|
|
|||
|
|
@ -19162,6 +19162,8 @@ QDF_STATUS csr_roam_send_chan_sw_ie_request(tpAniSirGlobal mac_ctx,
|
|||
|
||||
msg->targetChannel = target_channel;
|
||||
msg->csaIeRequired = csa_ie_reqd;
|
||||
msg->ch_switch_beacon_cnt =
|
||||
mac_ctx->sap.SapDfsInfo.sap_ch_switch_beacon_cnt;
|
||||
qdf_mem_copy(msg->bssid, bssid.bytes, QDF_MAC_ADDR_SIZE);
|
||||
qdf_mem_copy(&msg->ch_params, ch_params, sizeof(struct ch_params));
|
||||
|
||||
|
|
|
|||
Loading…
Reference in a new issue