qcacmn: Restart SAP with CSA/ECSA when gWlanMccToSccSwitchMod=3
Restart SAP with CSA/ECSA when ini variable gWlanMccToSccSwitchMod=3. Currently ini variable setting gWlanMccToSccSwitchMod=2 was causing SAP to restart with CSA. Change-Id: I9a4b68cd154fa63325d146510832c2410f2dc244 CRs-Fixed: 2058567
This commit is contained in:

committed by
snandini

parent
656ec600ac
commit
4b70998fcb
@@ -782,7 +782,7 @@ struct policy_mgr_hdd_cbacks {
|
|||||||
QDF_STATUS (*wlan_hdd_get_channel_for_sap_restart)(
|
QDF_STATUS (*wlan_hdd_get_channel_for_sap_restart)(
|
||||||
struct wlan_objmgr_psoc *psoc,
|
struct wlan_objmgr_psoc *psoc,
|
||||||
uint8_t vdev_id, uint8_t *channel,
|
uint8_t vdev_id, uint8_t *channel,
|
||||||
uint8_t *sec_ch, bool is_restart_sap);
|
uint8_t *sec_ch);
|
||||||
enum policy_mgr_con_mode (*get_mode_for_non_connected_vdev)(
|
enum policy_mgr_con_mode (*get_mode_for_non_connected_vdev)(
|
||||||
struct wlan_objmgr_psoc *psoc,
|
struct wlan_objmgr_psoc *psoc,
|
||||||
uint8_t vdev_id);
|
uint8_t vdev_id);
|
||||||
|
@@ -599,27 +599,6 @@ static bool policy_mgr_is_restart_sap_allowed(
|
|||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
|
||||||
* policy_mgr_is_sap_channel_change_without_restart() - Check if
|
|
||||||
* SAP channel change allowed without restart
|
|
||||||
* @mcc_to_scc_switch: MCC to SCC switch enabled user config
|
|
||||||
*
|
|
||||||
* Check if SAP channel change allowed without restart
|
|
||||||
*
|
|
||||||
* Restart: true or false
|
|
||||||
*/
|
|
||||||
static bool policy_mgr_is_sap_channel_change_without_restart(
|
|
||||||
uint32_t mcc_to_scc_switch) {
|
|
||||||
if (mcc_to_scc_switch ==
|
|
||||||
QDF_MCC_TO_SCC_SWITCH_FORCE_WITHOUT_DISCONNECTION ||
|
|
||||||
mcc_to_scc_switch ==
|
|
||||||
QDF_MCC_TO_SCC_SWITCH_WITH_FAVORITE_CHANNEL) {
|
|
||||||
policy_mgr_info("SAP chan change without restart allowed");
|
|
||||||
return true;
|
|
||||||
}
|
|
||||||
return false;
|
|
||||||
}
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* policy_mgr_check_sta_ap_concurrent_ch_intf() - Restart SAP in STA-AP case
|
* policy_mgr_check_sta_ap_concurrent_ch_intf() - Restart SAP in STA-AP case
|
||||||
* @data: Pointer check concurrent channel work data
|
* @data: Pointer check concurrent channel work data
|
||||||
@@ -637,8 +616,6 @@ void policy_mgr_check_sta_ap_concurrent_ch_intf(void *data)
|
|||||||
QDF_STATUS status;
|
QDF_STATUS status;
|
||||||
uint8_t channel, sec_ch;
|
uint8_t channel, sec_ch;
|
||||||
uint8_t operating_channel, vdev_id;
|
uint8_t operating_channel, vdev_id;
|
||||||
bool restart_sap;
|
|
||||||
|
|
||||||
|
|
||||||
pm_ctx = policy_mgr_get_context(psoc);
|
pm_ctx = policy_mgr_get_context(psoc);
|
||||||
if (!pm_ctx) {
|
if (!pm_ctx) {
|
||||||
@@ -661,9 +638,6 @@ void policy_mgr_check_sta_ap_concurrent_ch_intf(void *data)
|
|||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
restart_sap = policy_mgr_is_sap_channel_change_without_restart(
|
|
||||||
mcc_to_scc_switch) ? false : true;
|
|
||||||
|
|
||||||
if (!pm_ctx->hdd_cbacks.wlan_hdd_get_channel_for_sap_restart) {
|
if (!pm_ctx->hdd_cbacks.wlan_hdd_get_channel_for_sap_restart) {
|
||||||
policy_mgr_err("SAP restart get channel callback in NULL");
|
policy_mgr_err("SAP restart get channel callback in NULL");
|
||||||
return;
|
return;
|
||||||
@@ -671,7 +645,7 @@ void policy_mgr_check_sta_ap_concurrent_ch_intf(void *data)
|
|||||||
qdf_mutex_acquire(&pm_ctx->qdf_conc_list_lock);
|
qdf_mutex_acquire(&pm_ctx->qdf_conc_list_lock);
|
||||||
status = pm_ctx->hdd_cbacks.
|
status = pm_ctx->hdd_cbacks.
|
||||||
wlan_hdd_get_channel_for_sap_restart(psoc, vdev_id,
|
wlan_hdd_get_channel_for_sap_restart(psoc, vdev_id,
|
||||||
&channel, &sec_ch, restart_sap);
|
&channel, &sec_ch);
|
||||||
qdf_mutex_release(&pm_ctx->qdf_conc_list_lock);
|
qdf_mutex_release(&pm_ctx->qdf_conc_list_lock);
|
||||||
if (status != QDF_STATUS_SUCCESS) {
|
if (status != QDF_STATUS_SUCCESS) {
|
||||||
policy_mgr_err("Failed to switch SAP channel");
|
policy_mgr_err("Failed to switch SAP channel");
|
||||||
|
Reference in New Issue
Block a user