qcacld-3.0: SAP in CAC, block concurrency
At the time of starting / stopping 2nd or 3rd connection, Host sends WMI_PDEV_SET_HW_CMDID command to FW to change HW mode to DBS / Single-Mac based on concurrency rule. FW upon receiving this command turns off TXRX chainmask which means that radar pulses might get missed for 20ms - 50ms during CAC period. To fix this, Host should block new connection when existing SAP is performing CAC on DFS channel. Change-Id: I51eb117afa763a6ef54211808875419026c9075b CRs-Fixed: 2533717
This commit is contained in:
@@ -1309,6 +1309,7 @@ struct policy_mgr_hdd_cbacks {
|
|||||||
enum QDF_OPMODE (*hdd_get_device_mode)(uint32_t session_id);
|
enum QDF_OPMODE (*hdd_get_device_mode)(uint32_t session_id);
|
||||||
bool (*hdd_wapi_security_sta_exist)(void);
|
bool (*hdd_wapi_security_sta_exist)(void);
|
||||||
bool (*hdd_is_chan_switch_in_progress)(void);
|
bool (*hdd_is_chan_switch_in_progress)(void);
|
||||||
|
bool (*hdd_is_cac_in_progress)(void);
|
||||||
void (*wlan_hdd_set_sap_csa_reason)(struct wlan_objmgr_psoc *psoc,
|
void (*wlan_hdd_set_sap_csa_reason)(struct wlan_objmgr_psoc *psoc,
|
||||||
uint8_t vdev_id, uint8_t reason);
|
uint8_t vdev_id, uint8_t reason);
|
||||||
};
|
};
|
||||||
|
@@ -165,6 +165,17 @@ QDF_STATUS policy_mgr_pdev_set_hw_mode(struct wlan_objmgr_psoc *psoc,
|
|||||||
return QDF_STATUS_E_FAILURE;
|
return QDF_STATUS_E_FAILURE;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/* Don't send WMI_PDEV_SET_HW_MODE_CMDID to FW if existing SAP / GO is
|
||||||
|
* in CAC-in-progress state. Host is blocking this command as FW is
|
||||||
|
* having design limitation and FW don't expect this command when CAC
|
||||||
|
* is in progress state.
|
||||||
|
*/
|
||||||
|
if (pm_ctx->hdd_cbacks.hdd_is_cac_in_progress &&
|
||||||
|
pm_ctx->hdd_cbacks.hdd_is_cac_in_progress()) {
|
||||||
|
policy_mgr_err("SAP CAC_IN_PROGRESS state, drop WMI_PDEV_SET_HW_MODE_CMDID");
|
||||||
|
return QDF_STATUS_E_FAILURE;
|
||||||
|
}
|
||||||
|
|
||||||
msg.hw_mode_index = hw_mode_index;
|
msg.hw_mode_index = hw_mode_index;
|
||||||
msg.set_hw_mode_cb = (void *)policy_mgr_pdev_set_hw_mode_cb;
|
msg.set_hw_mode_cb = (void *)policy_mgr_pdev_set_hw_mode_cb;
|
||||||
msg.reason = reason;
|
msg.reason = reason;
|
||||||
|
@@ -1464,6 +1464,7 @@ void pm_dbs_opportunistic_timer_handler(void *data)
|
|||||||
uint32_t session_id;
|
uint32_t session_id;
|
||||||
struct wlan_objmgr_psoc *psoc = (struct wlan_objmgr_psoc *)data;
|
struct wlan_objmgr_psoc *psoc = (struct wlan_objmgr_psoc *)data;
|
||||||
enum policy_mgr_conn_update_reason reason;
|
enum policy_mgr_conn_update_reason reason;
|
||||||
|
struct policy_mgr_psoc_priv_obj *pm_ctx = policy_mgr_get_context(psoc);
|
||||||
|
|
||||||
if (!psoc) {
|
if (!psoc) {
|
||||||
policy_mgr_err("Invalid Context");
|
policy_mgr_err("Invalid Context");
|
||||||
@@ -1473,8 +1474,14 @@ void pm_dbs_opportunistic_timer_handler(void *data)
|
|||||||
/* if we still need it */
|
/* if we still need it */
|
||||||
action = policy_mgr_need_opportunistic_upgrade(psoc, &reason);
|
action = policy_mgr_need_opportunistic_upgrade(psoc, &reason);
|
||||||
policy_mgr_debug("action:%d", action);
|
policy_mgr_debug("action:%d", action);
|
||||||
if (!action)
|
if (!action) {
|
||||||
return;
|
return;
|
||||||
|
} else if (pm_ctx->hdd_cbacks.hdd_is_cac_in_progress &&
|
||||||
|
pm_ctx->hdd_cbacks.hdd_is_cac_in_progress()) {
|
||||||
|
policy_mgr_debug("SAP is in CAC_IN_PROGRESS state, restarting");
|
||||||
|
policy_mgr_restart_opportunistic_timer(psoc, false);
|
||||||
|
return;
|
||||||
|
}
|
||||||
session_id = pm_get_vdev_id_of_first_conn_idx(psoc);
|
session_id = pm_get_vdev_id_of_first_conn_idx(psoc);
|
||||||
policy_mgr_next_actions(psoc, session_id, action,
|
policy_mgr_next_actions(psoc, session_id, action,
|
||||||
reason);
|
reason);
|
||||||
|
@@ -610,6 +610,8 @@ QDF_STATUS policy_mgr_register_hdd_cb(struct wlan_objmgr_psoc *psoc,
|
|||||||
hdd_cbacks->hdd_wapi_security_sta_exist;
|
hdd_cbacks->hdd_wapi_security_sta_exist;
|
||||||
pm_ctx->hdd_cbacks.hdd_is_chan_switch_in_progress =
|
pm_ctx->hdd_cbacks.hdd_is_chan_switch_in_progress =
|
||||||
hdd_cbacks->hdd_is_chan_switch_in_progress;
|
hdd_cbacks->hdd_is_chan_switch_in_progress;
|
||||||
|
pm_ctx->hdd_cbacks.hdd_is_cac_in_progress =
|
||||||
|
hdd_cbacks->hdd_is_cac_in_progress;
|
||||||
|
|
||||||
return QDF_STATUS_SUCCESS;
|
return QDF_STATUS_SUCCESS;
|
||||||
}
|
}
|
||||||
@@ -628,6 +630,8 @@ QDF_STATUS policy_mgr_deregister_hdd_cb(struct wlan_objmgr_psoc *psoc)
|
|||||||
pm_ctx->hdd_cbacks.wlan_hdd_get_channel_for_sap_restart = NULL;
|
pm_ctx->hdd_cbacks.wlan_hdd_get_channel_for_sap_restart = NULL;
|
||||||
pm_ctx->hdd_cbacks.get_mode_for_non_connected_vdev = NULL;
|
pm_ctx->hdd_cbacks.get_mode_for_non_connected_vdev = NULL;
|
||||||
pm_ctx->hdd_cbacks.hdd_get_device_mode = NULL;
|
pm_ctx->hdd_cbacks.hdd_get_device_mode = NULL;
|
||||||
|
pm_ctx->hdd_cbacks.hdd_is_chan_switch_in_progress = NULL;
|
||||||
|
pm_ctx->hdd_cbacks.hdd_is_cac_in_progress = NULL;
|
||||||
|
|
||||||
return QDF_STATUS_SUCCESS;
|
return QDF_STATUS_SUCCESS;
|
||||||
}
|
}
|
||||||
|
Reference in New Issue
Block a user