qca-wifi: Deliver PreCAC events to the user space

Deliver the PreCAC event PRECAC_STARTED when the zero cac timer and
the ADFS timer are started.

Deliver the PreCAC event PRECAC_COMPLETED when the dfs channels are
marked as PreCAC Done in the PreCAC tree.

Change-Id: I47b2ab6914df0bdaad7d426a88ae05b65155eeb0
CRs-Fixed: 2823532
Esse commit está contido em:
Vignesh U
2020-12-03 14:51:56 +05:30
commit 3dc03f2b08
2 arquivos alterados com 31 adições e 0 exclusões

Ver arquivo

@@ -1392,6 +1392,10 @@ void dfs_mark_precac_done_for_freq(struct wlan_dfs *dfs,
(precac_entry->bw/2))) {
dfs_mark_tree_node_as_cac_done_for_freq
(dfs, precac_entry, channels[i]);
utils_dfs_deliver_event(dfs->dfs_pdev_obj,
channels[i],
WLAN_EV_PCAC_COMPLETED);
break;
}
}

Ver arquivo

@@ -1110,6 +1110,10 @@ void dfs_start_agile_precac_timer(struct wlan_dfs *dfs,
enum phy_ch_width chwidth = adfs_param->precac_chwidth;
uint32_t min_precac_timeout, max_precac_timeout;
struct dfs_soc_priv_obj *dfs_soc_obj;
uint8_t n_sub_chans;
uint8_t i;
qdf_freq_t sub_chans[N_SUBCHANS_FOR_160BW];
dfs_soc_obj = dfs->dfs_soc_obj;
dfs_soc_obj->dfs_precac_timer_running = 1;
@@ -1141,6 +1145,17 @@ void dfs_start_agile_precac_timer(struct wlan_dfs *dfs,
* FW OCAC completion event and HOST timer firing at same time. */
if (min_precac_timeout)
min_precac_timeout += EXTRA_TIME_IN_MS;
n_sub_chans =
dfs_find_subchannels_for_center_freq(
adfs_param->precac_center_freq_1,
adfs_param->precac_center_freq_2,
adfs_param->precac_chwidth,
sub_chans);
for (i = 0; i < n_sub_chans; i++)
utils_dfs_deliver_event(dfs->dfs_pdev_obj,
sub_chans[i],
WLAN_EV_PCAC_STARTED);
qdf_timer_mod(&dfs_soc_obj->dfs_precac_timer, min_precac_timeout);
}
#endif
@@ -1160,6 +1175,9 @@ void dfs_start_precac_timer_for_freq(struct wlan_dfs *dfs,
int secondary_cac_timeout;
int precac_timeout;
struct dfs_soc_priv_obj *dfs_soc_obj;
uint8_t n_sub_chans;
qdf_freq_t sub_chans[N_SUBCHANS_FOR_160BW];
uint8_t i;
dfs_soc_obj = dfs->dfs_soc_obj;
dfs_soc_obj->cur_agile_dfs_index = dfs->dfs_psoc_idx;
@@ -1226,6 +1244,15 @@ void dfs_start_precac_timer_for_freq(struct wlan_dfs *dfs,
dfs_debug(dfs, WLAN_DEBUG_DFS,
"precactimeout = %d", (precac_timeout)*1000);
n_sub_chans = dfs_find_subchannels_for_center_freq(precac_chan_freq,
0,
CH_WIDTH_80MHZ,
sub_chans);
for (i = 0; i < n_sub_chans; i++)
utils_dfs_deliver_event(dfs->dfs_pdev_obj,\
sub_chans[i],
WLAN_EV_PCAC_STARTED);
qdf_timer_mod(&dfs_soc_obj->dfs_precac_timer, (precac_timeout) * 1000);
}
#endif