qcacmn: update chan avoid ind for wmi_wlan_freq_avoid_event_id
If coex_unsafe_chan_nb_user_prefer ini is not set then
avoid_freq_ind becoming NULL for "wmi_wlan_freq_avoid_event_id"
which results in sending regulatory update event to user space
and reduces PNO scan timeline.
This change is to update ch_avoid_ind for
wmi_wlan_freq_avoid_event_id.
Fixes regression : 7192d90810
("qcacmn: update unsafe channel
list for SAP for freq extcmd")
Change-Id: I57ff334e9cf47468c30bc6884a9ead0a65a92b23
CRs-Fixed: 3119140
This commit is contained in:

committed by
Madan Koyyalamudi

父節點
ed41e85970
當前提交
76b13083fb
@@ -94,6 +94,26 @@ static void reg_call_chan_change_cbks(struct wlan_objmgr_psoc *psoc,
|
||||
}
|
||||
|
||||
#ifdef FEATURE_WLAN_CH_AVOID_EXT
|
||||
static inline void
|
||||
reg_fill_freq_ext_payload(struct reg_sched_payload **payload,
|
||||
struct wlan_regulatory_psoc_priv_obj *psoc_priv_obj)
|
||||
{
|
||||
(*payload)->ch_avoid_ind =
|
||||
!!psoc_priv_obj->ch_avoid_ext_ind;
|
||||
qdf_mem_copy(&(*payload)->avoid_info.freq_list,
|
||||
&psoc_priv_obj->avoid_freq_ext_list,
|
||||
sizeof(psoc_priv_obj->avoid_freq_ext_list));
|
||||
|
||||
psoc_priv_obj->ch_avoid_ext_ind = false;
|
||||
}
|
||||
#else
|
||||
static inline void
|
||||
reg_fill_freq_ext_payload(struct reg_sched_payload **payload,
|
||||
struct wlan_regulatory_psoc_priv_obj *psoc_priv_obj)
|
||||
{
|
||||
}
|
||||
#endif
|
||||
|
||||
/**
|
||||
* reg_alloc_and_fill_payload() - Alloc and fill payload structure.
|
||||
* @psoc: Pointer to global psoc structure.
|
||||
@@ -117,47 +137,21 @@ static void reg_alloc_and_fill_payload(struct wlan_objmgr_psoc *psoc,
|
||||
(*payload)->psoc = psoc;
|
||||
(*payload)->pdev = pdev;
|
||||
if (reg_check_coex_unsafe_nb_user_prefer(psoc)) {
|
||||
reg_fill_freq_ext_payload(payload, psoc_priv_obj);
|
||||
} else {
|
||||
(*payload)->ch_avoid_ind =
|
||||
!!psoc_priv_obj->ch_avoid_ext_ind;
|
||||
!!psoc_priv_obj->ch_avoid_ind;
|
||||
qdf_mem_copy(&(*payload)->avoid_info.freq_list,
|
||||
&psoc_priv_obj->avoid_freq_ext_list,
|
||||
sizeof(psoc_priv_obj->avoid_freq_ext_list));
|
||||
psoc_priv_obj->ch_avoid_ext_ind = false;
|
||||
&psoc_priv_obj->avoid_freq_list,
|
||||
sizeof(psoc_priv_obj->avoid_freq_list));
|
||||
|
||||
psoc_priv_obj->ch_avoid_ind = false;
|
||||
}
|
||||
qdf_mem_copy(&(*payload)->avoid_info.chan_list,
|
||||
&psoc_priv_obj->unsafe_chan_list,
|
||||
sizeof(psoc_priv_obj->unsafe_chan_list));
|
||||
}
|
||||
}
|
||||
#else
|
||||
static void reg_alloc_and_fill_payload(struct wlan_objmgr_psoc *psoc,
|
||||
struct wlan_objmgr_pdev *pdev,
|
||||
struct reg_sched_payload **payload)
|
||||
{
|
||||
struct wlan_regulatory_psoc_priv_obj *psoc_priv_obj;
|
||||
|
||||
psoc_priv_obj = reg_get_psoc_obj(psoc);
|
||||
if (!psoc_priv_obj) {
|
||||
reg_err("reg psoc private obj is NULL");
|
||||
*payload = NULL;
|
||||
return;
|
||||
}
|
||||
|
||||
*payload = qdf_mem_malloc(sizeof(**payload));
|
||||
if (*payload) {
|
||||
(*payload)->psoc = psoc;
|
||||
(*payload)->pdev = pdev;
|
||||
(*payload)->ch_avoid_ind = !!psoc_priv_obj->ch_avoid_ind;
|
||||
qdf_mem_copy(&(*payload)->avoid_info.freq_list,
|
||||
&psoc_priv_obj->avoid_freq_list,
|
||||
sizeof(psoc_priv_obj->avoid_freq_list));
|
||||
psoc_priv_obj->ch_avoid_ind = false;
|
||||
}
|
||||
qdf_mem_copy(&(*payload)->avoid_info.chan_list,
|
||||
&psoc_priv_obj->unsafe_chan_list,
|
||||
sizeof(psoc_priv_obj->unsafe_chan_list));
|
||||
}
|
||||
#endif
|
||||
|
||||
/**
|
||||
* reg_chan_change_flush_cbk_sb() - Flush south bound channel change callbacks.
|
||||
|
Reference in New Issue
Block a user