qcacld-3.0: Dont allow SAP on indoor channel
In case of STA + SAP concurrency and STA is on indoor channel. Dont allow SAP to turn on, irrespective of DBS, MCC or SCC mode of concurrency, if STA + SAP concurrency not allowed on indoor channel. Change-Id: I79582f88e81cb2c95d2da2480d1e3d7a8b86906f CRs-Fixed: 2967952
This commit is contained in:

committed by
Madan Koyyalamudi

parent
bb211cfdfe
commit
1c4c73d081
@@ -3047,6 +3047,22 @@ QDF_STATUS policy_mgr_valid_sap_conc_channel_check(
|
|||||||
uint32_t sap_ch_freq, uint8_t sap_vdev_id,
|
uint32_t sap_ch_freq, uint8_t sap_vdev_id,
|
||||||
struct ch_params *ch_params);
|
struct ch_params *ch_params);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* policy_mgr_sap_allowed_on_indoor_freq() - Check whether STA+SAP concurrency
|
||||||
|
* allowed on indoor channel or not
|
||||||
|
* @psoc: pointer to PSOC object information
|
||||||
|
* @pdev: pointer to PDEV object information
|
||||||
|
* @sap_ch_freq: initial channel frequency for SAP
|
||||||
|
*
|
||||||
|
* This function checks whether SAP is allowed to turn on in case of STA+SAP
|
||||||
|
* concurrency if STA is on indoor channel.
|
||||||
|
*
|
||||||
|
* Return: false if SAP not allowed to come up on a indoor channel
|
||||||
|
*/
|
||||||
|
bool policy_mgr_sap_allowed_on_indoor_freq(struct wlan_objmgr_psoc *psoc,
|
||||||
|
struct wlan_objmgr_pdev *pdev,
|
||||||
|
uint32_t sap_ch_freq);
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* policy_mgr_get_alternate_channel_for_sap() - Get an alternate
|
* policy_mgr_get_alternate_channel_for_sap() - Get an alternate
|
||||||
* channel to move the SAP to
|
* channel to move the SAP to
|
||||||
|
@@ -36,6 +36,7 @@
|
|||||||
#include "wlan_mlme_api.h"
|
#include "wlan_mlme_api.h"
|
||||||
#include "sap_api.h"
|
#include "sap_api.h"
|
||||||
#include "wlan_mlme_api.h"
|
#include "wlan_mlme_api.h"
|
||||||
|
#include "wlan_mlme_ucfg_api.h"
|
||||||
|
|
||||||
enum policy_mgr_conc_next_action (*policy_mgr_get_current_pref_hw_mode_ptr)
|
enum policy_mgr_conc_next_action (*policy_mgr_get_current_pref_hw_mode_ptr)
|
||||||
(struct wlan_objmgr_psoc *psoc);
|
(struct wlan_objmgr_psoc *psoc);
|
||||||
@@ -2210,6 +2211,23 @@ static QDF_STATUS policy_mgr_check_6ghz_sap_conc(
|
|||||||
return QDF_STATUS_SUCCESS;
|
return QDF_STATUS_SUCCESS;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
bool policy_mgr_sap_allowed_on_indoor_freq(struct wlan_objmgr_psoc *psoc,
|
||||||
|
struct wlan_objmgr_pdev *pdev,
|
||||||
|
uint32_t sap_ch_freq)
|
||||||
|
{
|
||||||
|
bool include_indoor_channel = 0;
|
||||||
|
|
||||||
|
ucfg_mlme_get_indoor_channel_support(psoc, &include_indoor_channel);
|
||||||
|
|
||||||
|
if (!include_indoor_channel &&
|
||||||
|
wlan_reg_is_freq_indoor(pdev, sap_ch_freq)) {
|
||||||
|
policy_mgr_debug("No more operation on indoor channel");
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
|
||||||
|
return true;
|
||||||
|
}
|
||||||
|
|
||||||
QDF_STATUS policy_mgr_valid_sap_conc_channel_check(
|
QDF_STATUS policy_mgr_valid_sap_conc_channel_check(
|
||||||
struct wlan_objmgr_psoc *psoc, uint32_t *con_ch_freq,
|
struct wlan_objmgr_psoc *psoc, uint32_t *con_ch_freq,
|
||||||
uint32_t sap_ch_freq, uint8_t sap_vdev_id,
|
uint32_t sap_ch_freq, uint8_t sap_vdev_id,
|
||||||
@@ -2315,11 +2333,13 @@ QDF_STATUS policy_mgr_valid_sap_conc_channel_check(
|
|||||||
return QDF_STATUS_E_FAILURE;
|
return QDF_STATUS_E_FAILURE;
|
||||||
}
|
}
|
||||||
} else {
|
} else {
|
||||||
if (!(policy_mgr_sta_sap_scc_on_lte_coex_chan
|
if ((!(policy_mgr_sta_sap_scc_on_lte_coex_chan
|
||||||
(psoc)) && !(policy_mgr_is_safe_channel
|
(psoc)) && !(policy_mgr_is_safe_channel
|
||||||
(psoc, ch_freq))) {
|
(psoc, ch_freq))) ||
|
||||||
policy_mgr_warn("Can't have concurrency due to unsafe channel %d",
|
!policy_mgr_sap_allowed_on_indoor_freq(psoc,
|
||||||
ch_freq);
|
pm_ctx->pdev, sap_ch_freq)) {
|
||||||
|
policy_mgr_warn("Can't have concurrency due to unsafe/indoor channel:%d, sap_ch_freq:%d",
|
||||||
|
ch_freq, sap_ch_freq);
|
||||||
return QDF_STATUS_E_FAILURE;
|
return QDF_STATUS_E_FAILURE;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
Reference in New Issue
Block a user