qcacld-3.0: Handle FW not support SBS

If FW doesn't support SBS, return QDF_STATUS_E_NOSUPPORT
to allow connect request in current HW mode.

Change-Id: Ie960fe993ea95cf40dd43fb56c71edd94efda63b
CRs-Fixed: 2370206
This commit is contained in:
Liangwei Dong 2018-12-24 02:45:05 -05:00 committed by nshrivas
parent 8343a9b621
commit b007863932

View File

@ -925,21 +925,20 @@ QDF_STATUS policy_mgr_validate_dbs_switch(
return status;
}
if (hw_mode.sbs_cap) {
if ((action == PM_SBS) || (action == PM_SBS_DOWNGRADE)) {
if (!policy_mgr_is_hw_sbs_capable(psoc)) {
/* No action */
policy_mgr_notice("firmware is not sbs capable");
return QDF_STATUS_E_NOSUPPORT;
}
/* current mode is already SBS nothing to be
* done
*/
policy_mgr_notice("current mode is already SBS");
return QDF_STATUS_E_ALREADY;
} else {
return QDF_STATUS_SUCCESS;
if ((action == PM_SBS) || (action == PM_SBS_DOWNGRADE)) {
if (!policy_mgr_is_hw_sbs_capable(psoc)) {
/* No action */
policy_mgr_notice("firmware is not sbs capable");
return QDF_STATUS_E_NOSUPPORT;
}
/* current mode is already SBS nothing to be
* done
*/
if (hw_mode.sbs_cap && action == PM_SBS) {
policy_mgr_notice("current mode is already SBS");
return QDF_STATUS_E_ALREADY;
}
return QDF_STATUS_SUCCESS;
}
if (!hw_mode.dbs_cap) {