qcacmn: Maintain FW ADFS support flags in dfs
Agile DFS support depends on the Firmware's aDFS support. This information is propagated to the HOST in the WMI ready event as a flag. This flag was not used by HOST before enabling agile DFS which resulted in preCAC being enabled for the FW that does not support them. Also, for certain chainmask configurations, aDFS should be enabled only if the current pdev is operating in non 160 BW. Introduce two new flags in the DFS object: 1. dfs_fw_adfs_support_160 2. dfs_fw_adfs_support_non_160 which specify FW support for ADFS for pdevs in 160 BW and non 160 BW respectively. Make appropriate changes in is_agile_precac_enabled check that includes fw support for the current operating bandwidth. Also rename "dfs_agile_precac_enable" to "dfs_agile_precac_ucfg" and "dfs_precac_enable" to dfs_legacy_precac_ucfg" in the dfs structure to properly indicate what those booleans represent. Change-Id: I202ead8ef109c707bfbda488064ecaa72a3f737f CRs-Fixed: 2521654
This commit is contained in:
@@ -772,3 +772,24 @@ bool tgt_dfs_is_stadfs_enabled(struct wlan_objmgr_pdev *pdev)
|
||||
|
||||
return dfs->dfs_is_stadfs_enabled;
|
||||
}
|
||||
|
||||
#ifdef QCA_SUPPORT_AGILE_DFS
|
||||
void tgt_dfs_set_fw_adfs_support(struct wlan_objmgr_pdev *pdev,
|
||||
bool fw_adfs_support_160,
|
||||
bool fw_adfs_support_non_160)
|
||||
{
|
||||
struct wlan_dfs *dfs;
|
||||
|
||||
dfs = wlan_pdev_get_dfs_obj(pdev);
|
||||
if (!dfs) {
|
||||
dfs_err(dfs, WLAN_DEBUG_DFS_ALWAYS, "dfs is NULL");
|
||||
return;
|
||||
}
|
||||
|
||||
dfs_set_fw_adfs_support(dfs,
|
||||
fw_adfs_support_160,
|
||||
fw_adfs_support_non_160);
|
||||
}
|
||||
|
||||
qdf_export_symbol(tgt_dfs_set_fw_adfs_support);
|
||||
#endif
|
||||
|
@@ -139,8 +139,8 @@ QDF_STATUS ucfg_dfs_set_precac_enable(struct wlan_objmgr_pdev *pdev,
|
||||
}
|
||||
qdf_export_symbol(ucfg_dfs_set_precac_enable);
|
||||
|
||||
QDF_STATUS ucfg_dfs_get_precac_enable(struct wlan_objmgr_pdev *pdev,
|
||||
int *buff)
|
||||
QDF_STATUS ucfg_dfs_get_legacy_precac_enable(struct wlan_objmgr_pdev *pdev,
|
||||
bool *buff)
|
||||
{
|
||||
struct wlan_dfs *dfs;
|
||||
|
||||
@@ -153,11 +153,12 @@ QDF_STATUS ucfg_dfs_get_precac_enable(struct wlan_objmgr_pdev *pdev,
|
||||
return QDF_STATUS_E_FAILURE;
|
||||
}
|
||||
|
||||
*buff = dfs_get_precac_enable(dfs);
|
||||
*buff = dfs_is_legacy_precac_enabled(dfs);
|
||||
|
||||
return QDF_STATUS_SUCCESS;
|
||||
}
|
||||
qdf_export_symbol(ucfg_dfs_get_precac_enable);
|
||||
|
||||
qdf_export_symbol(ucfg_dfs_get_legacy_precac_enable);
|
||||
|
||||
QDF_STATUS ucfg_dfs_get_agile_precac_enable(struct wlan_objmgr_pdev *pdev,
|
||||
bool *buff)
|
||||
@@ -178,7 +179,7 @@ QDF_STATUS ucfg_dfs_get_agile_precac_enable(struct wlan_objmgr_pdev *pdev,
|
||||
return QDF_STATUS_E_FAILURE;
|
||||
}
|
||||
|
||||
*buff = dfs_get_agile_precac_enable(dfs);
|
||||
*buff = dfs_is_agile_precac_enabled(dfs);
|
||||
|
||||
return QDF_STATUS_SUCCESS;
|
||||
}
|
||||
|
Reference in New Issue
Block a user