mirror of
https://github.com/BobTheBlinker/android_kernel_motorola_sm6375.git
synced 2026-10-24 13:44:26 -04:00
qcacmn: Don't move SAP if SCC on lte coex channel is allowed
If STA+SAP is doing SCC & g_sta_sap_scc_on_lte_coex_chan is set, don't move SAP to a different channel when LTE channel avoidance event comes. Change-Id: I3dfdbb6d59769a8ff9b3b2e6d828feee94630569 CRs-Fixed: 2268993
This commit is contained in:
parent
2854295433
commit
9b1636dcd4
2 changed files with 44 additions and 0 deletions
|
|
@ -2426,4 +2426,14 @@ bool policy_mgr_sta_sap_scc_on_lte_coex_chan(
|
|||
bool policy_mgr_is_valid_for_channel_switch(struct wlan_objmgr_psoc *psoc,
|
||||
uint8_t channel);
|
||||
|
||||
/**
|
||||
* policy_mgr_is_sta_sap_scc() - check whether SAP is doing SCC with
|
||||
* STA
|
||||
* @psoc: poniter to psoc
|
||||
* @sap_ch: operating channel of SAP interface
|
||||
* This function checks whether SAP is doing SCC with STA
|
||||
*
|
||||
* Return: true or false
|
||||
*/
|
||||
bool policy_mgr_is_sta_sap_scc(struct wlan_objmgr_psoc *psoc, uint8_t sap_ch);
|
||||
#endif /* __WLAN_POLICY_MGR_API_H */
|
||||
|
|
|
|||
|
|
@ -3141,3 +3141,37 @@ bool policy_mgr_is_valid_for_channel_switch(struct wlan_objmgr_psoc *psoc,
|
|||
policy_mgr_debug("Invalid channel for channel switch");
|
||||
return false;
|
||||
}
|
||||
|
||||
bool policy_mgr_is_sta_sap_scc(struct wlan_objmgr_psoc *psoc, uint8_t sap_ch)
|
||||
{
|
||||
uint32_t conn_index;
|
||||
bool is_scc = false;
|
||||
struct policy_mgr_psoc_priv_obj *pm_ctx;
|
||||
|
||||
pm_ctx = policy_mgr_get_context(psoc);
|
||||
if (!pm_ctx) {
|
||||
policy_mgr_err("Invalid Context");
|
||||
return is_scc;
|
||||
}
|
||||
|
||||
if (!policy_mgr_mode_specific_connection_count(
|
||||
psoc, PM_STA_MODE, NULL)) {
|
||||
policy_mgr_debug("There is no STA+SAP conc");
|
||||
return is_scc;
|
||||
}
|
||||
|
||||
qdf_mutex_acquire(&pm_ctx->qdf_conc_list_lock);
|
||||
for (conn_index = 0; conn_index < MAX_NUMBER_OF_CONC_CONNECTIONS;
|
||||
conn_index++) {
|
||||
if (pm_conc_connection_list[conn_index].in_use &&
|
||||
(pm_conc_connection_list[conn_index].mode ==
|
||||
PM_STA_MODE) &&
|
||||
(sap_ch == pm_conc_connection_list[conn_index].chan)) {
|
||||
is_scc = true;
|
||||
break;
|
||||
}
|
||||
}
|
||||
qdf_mutex_release(&pm_ctx->qdf_conc_list_lock);
|
||||
|
||||
return is_scc;
|
||||
}
|
||||
|
|
|
|||
Loading…
Reference in a new issue