qcacld-3.0: Fix DFS CAC start event missing
At present check SAP on DFS is based on primary channel, it doesn't work for 160M case. Use "sap_operating_on_dfs" to do the check before deliver CAC Start event. Change-Id: I3896dc2738da16b9bff0d54826191d0edcc251a4 CRs-Fixed: 2929729
This commit is contained in:

committed by
Madan Koyyalamudi

parent
84c0ae58ae
commit
765b466f12
@@ -1926,12 +1926,10 @@ static QDF_STATUS sap_cac_start_notify(mac_handle_t mac_handle)
|
|||||||
uint8_t intf = 0;
|
uint8_t intf = 0;
|
||||||
struct mac_context *mac = MAC_CONTEXT(mac_handle);
|
struct mac_context *mac = MAC_CONTEXT(mac_handle);
|
||||||
QDF_STATUS qdf_status = QDF_STATUS_E_FAILURE;
|
QDF_STATUS qdf_status = QDF_STATUS_E_FAILURE;
|
||||||
qdf_freq_t ch_freq;
|
|
||||||
|
|
||||||
for (intf = 0; intf < SAP_MAX_NUM_SESSION; intf++) {
|
for (intf = 0; intf < SAP_MAX_NUM_SESSION; intf++) {
|
||||||
struct sap_context *sap_context =
|
struct sap_context *sap_context =
|
||||||
mac->sap.sapCtxList[intf].sap_context;
|
mac->sap.sapCtxList[intf].sap_context;
|
||||||
struct csr_roam_profile *profile;
|
|
||||||
|
|
||||||
if (((QDF_SAP_MODE == mac->sap.sapCtxList[intf].sapPersona)
|
if (((QDF_SAP_MODE == mac->sap.sapCtxList[intf].sapPersona)
|
||||||
||
|
||
|
||||||
@@ -1939,10 +1937,9 @@ static QDF_STATUS sap_cac_start_notify(mac_handle_t mac_handle)
|
|||||||
&& mac->sap.sapCtxList[intf].sap_context &&
|
&& mac->sap.sapCtxList[intf].sap_context &&
|
||||||
(false == sap_context->isCacStartNotified)) {
|
(false == sap_context->isCacStartNotified)) {
|
||||||
/* Don't start CAC for non-dfs channel, its violation */
|
/* Don't start CAC for non-dfs channel, its violation */
|
||||||
profile = &sap_context->csr_roamProfile;
|
if (!sap_operating_on_dfs(
|
||||||
ch_freq = profile->op_freq;
|
mac,
|
||||||
if (!wlan_reg_is_dfs_for_freq(mac->pdev,
|
mac->sap.sapCtxList[intf].sap_context))
|
||||||
ch_freq))
|
|
||||||
continue;
|
continue;
|
||||||
sap_debug("sapdfs: Signaling eSAP_DFS_CAC_START to HDD for sapctx[%pK]",
|
sap_debug("sapdfs: Signaling eSAP_DFS_CAC_START to HDD for sapctx[%pK]",
|
||||||
sap_context);
|
sap_context);
|
||||||
@@ -2008,7 +2005,6 @@ static QDF_STATUS sap_cac_end_notify(mac_handle_t mac_handle,
|
|||||||
uint8_t intf;
|
uint8_t intf;
|
||||||
struct mac_context *mac = MAC_CONTEXT(mac_handle);
|
struct mac_context *mac = MAC_CONTEXT(mac_handle);
|
||||||
QDF_STATUS qdf_status = QDF_STATUS_E_FAILURE;
|
QDF_STATUS qdf_status = QDF_STATUS_E_FAILURE;
|
||||||
uint32_t freq;
|
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* eSAP_DFS_CHANNEL_CAC_END:
|
* eSAP_DFS_CHANNEL_CAC_END:
|
||||||
@@ -2019,7 +2015,6 @@ static QDF_STATUS sap_cac_end_notify(mac_handle_t mac_handle,
|
|||||||
for (intf = 0; intf < SAP_MAX_NUM_SESSION; intf++) {
|
for (intf = 0; intf < SAP_MAX_NUM_SESSION; intf++) {
|
||||||
struct sap_context *sap_context =
|
struct sap_context *sap_context =
|
||||||
mac->sap.sapCtxList[intf].sap_context;
|
mac->sap.sapCtxList[intf].sap_context;
|
||||||
struct csr_roam_profile *profile;
|
|
||||||
|
|
||||||
if (((QDF_SAP_MODE == mac->sap.sapCtxList[intf].sapPersona)
|
if (((QDF_SAP_MODE == mac->sap.sapCtxList[intf].sapPersona)
|
||||||
||
|
||
|
||||||
@@ -2029,12 +2024,9 @@ static QDF_STATUS sap_cac_end_notify(mac_handle_t mac_handle,
|
|||||||
sap_is_dfs_cac_wait_state(sap_context)) {
|
sap_is_dfs_cac_wait_state(sap_context)) {
|
||||||
sap_context = mac->sap.sapCtxList[intf].sap_context;
|
sap_context = mac->sap.sapCtxList[intf].sap_context;
|
||||||
/* Don't check CAC for non-dfs channel */
|
/* Don't check CAC for non-dfs channel */
|
||||||
profile = &sap_context->csr_roamProfile;
|
if (!sap_operating_on_dfs(
|
||||||
freq = profile->op_freq;
|
mac,
|
||||||
if (CHANNEL_STATE_DFS !=
|
mac->sap.sapCtxList[intf].sap_context))
|
||||||
wlan_reg_get_5g_bonded_channel_state_for_freq(mac->pdev,
|
|
||||||
freq,
|
|
||||||
profile->ch_params.ch_width))
|
|
||||||
continue;
|
continue;
|
||||||
|
|
||||||
/* If this is an end notification of a pre cac, the
|
/* If this is an end notification of a pre cac, the
|
||||||
|
Reference in New Issue
Block a user