瀏覽代碼

qcacld-3.0: Update regulatory info to cfg80211

Update the regulatory info to cfg80211 as well
if some channel information to be changed
by QCA_NL80211_VENDOR_SUBCMD_AVOID_FREQUENCY_EXT.

Change-Id: Ie485e9e2a57a04921e32d5f029b3c9535970186f
CRs-Fixed: 3335527
Chaoli Zhou 2 年之前
父節點
當前提交
563bc8f3f6
共有 1 個文件被更改,包括 10 次插入0 次删除
  1. 10 0
      core/hdd/src/wlan_hdd_regulatory.c

+ 10 - 0
core/hdd/src/wlan_hdd_regulatory.c

@@ -1903,17 +1903,27 @@ static void hdd_regulatory_dyn_cbk(struct wlan_objmgr_psoc *psoc,
 	struct hdd_context *hdd_ctx;
 	enum country_src cc_src;
 	uint8_t alpha2[REG_ALPHA2_LEN + 1];
+	bool nb_flag;
+	bool reg_flag;
 
 	pdev_priv = wlan_pdev_get_ospriv(pdev);
 	wiphy = pdev_priv->wiphy;
 	hdd_ctx = wiphy_priv(wiphy);
 
+	nb_flag = ucfg_mlme_get_coex_unsafe_chan_nb_user_prefer(hdd_ctx->psoc);
+	reg_flag = ucfg_mlme_get_coex_unsafe_chan_reg_disable(hdd_ctx->psoc);
+
+	if (avoid_freq_ind && nb_flag && reg_flag)
+		goto sync_chanlist;
+
 	if (avoid_freq_ind) {
 		hdd_ch_avoid_ind(hdd_ctx, &avoid_freq_ind->chan_list,
 				 &avoid_freq_ind->freq_list);
 		return;
 	}
 
+sync_chanlist:
+
 	hdd_debug("process channel list update from regulatory");
 	hdd_regulatory_chanlist_dump(chan_list);