Explorar el Código

qcacmn: Move uncommon regulatory APIs out of cmndev

The API reg_is_freq_txable() is not used by_REG_CLIENT devices and
should be moved out of converged code.

Move reg_is_freq_txable() and corresponding dispatcher API
wlan_reg_is_freq_txable() to unconverged code.

Change-Id: I1031a20d40ebcf30326c14901d413669206a8433
CRs-Fixed: 3568932
Vignesh U hace 2 años
padre
commit
4da1bf7d8c

+ 0 - 18
umac/regulatory/core/src/reg_services_common.c

@@ -10034,24 +10034,6 @@ reg_is_sup_chan_entry_afc_done(struct wlan_objmgr_pdev *pdev,
 	return !(super_chan_ent->chan_flags_arr[in_6g_pwr_mode] &
 		 REGULATORY_CHAN_AFC_NOT_DONE);
 }
-
-bool
-reg_is_6ghz_freq_txable(struct wlan_objmgr_pdev *pdev,
-			qdf_freq_t freq,
-			enum supported_6g_pwr_types in_6ghz_pwr_mode)
-{
-	bool is_freq_enabled;
-	enum reg_afc_dev_deploy_type reg_afc_deploy_type;
-
-	is_freq_enabled = reg_is_freq_enabled(pdev, freq, in_6ghz_pwr_mode);
-	if (!is_freq_enabled)
-		return false;
-
-	reg_get_afc_dev_deploy_type(pdev, &reg_afc_deploy_type);
-
-	return (reg_afc_deploy_type != AFC_DEPLOYMENT_OUTDOOR) ||
-		reg_is_afc_done(pdev, freq);
-}
 #endif
 
 #ifdef CONFIG_BAND_6GHZ

+ 1 - 25
umac/regulatory/core/src/reg_services_common.h

@@ -2135,6 +2135,7 @@ QDF_STATUS
 reg_find_txpower_from_6g_list(qdf_freq_t freq,
 			      struct regulatory_channel *chan_list,
 			      int16_t *reg_eirp);
+
 #else
 static inline QDF_STATUS
 reg_set_cur_6g_ap_pwr_type(struct wlan_objmgr_pdev *pdev,
@@ -2960,23 +2961,6 @@ bool reg_is_sup_chan_entry_afc_done(struct wlan_objmgr_pdev *pdev,
 				    enum channel_enum chan_idx,
 				    enum supported_6g_pwr_types in_6g_pwr_mode);
 
-/**
- * reg_is_6ghz_freq_txable() - Check if the given 6 GHz frequency is tx-able.
- * @pdev: Pointer to pdev
- * @freq: Frequency in MHz
- * @in_6ghz_pwr_mode: Input AP power type
- *
- * An SP channel is tx-able if the channel is present in the AFC response.
- * In case of non-OUTDOOR mode, a channel is always tx-able (Assuming it is
- * enabled by regulatory).
- *
- * Return: True if the frequency is tx-able, else false.
- */
-bool
-reg_is_6ghz_freq_txable(struct wlan_objmgr_pdev *pdev,
-			qdf_freq_t freq,
-			enum supported_6g_pwr_types in_6ghz_pwr_mode);
-
 /**
  * reg_set_afc_power_event_received() - Set power event received flag with
  * given val.
@@ -2996,14 +2980,6 @@ reg_is_sup_chan_entry_afc_done(struct wlan_objmgr_pdev *pdev,
 	return false;
 }
 
-static inline bool
-reg_is_6ghz_freq_txable(struct wlan_objmgr_pdev *pdev,
-			qdf_freq_t freq,
-			enum supported_6g_pwr_types in_6ghz_pwr_mode)
-{
-	return false;
-}
-
 static inline QDF_STATUS
 reg_set_afc_power_event_received(struct wlan_objmgr_pdev *pdev, bool val)
 {

+ 0 - 25
umac/regulatory/dispatcher/inc/wlan_reg_services_api.h

@@ -871,23 +871,6 @@ wlan_reg_get_afc_dev_deploy_type(struct wlan_objmgr_pdev *pdev,
 bool
 wlan_reg_is_sta_connect_allowed(struct wlan_objmgr_pdev *pdev,
 				enum reg_6g_ap_type root_ap_pwr_mode);
-
-/**
- * wlan_reg_is_6ghz_freq_txable() - Check if the given frequency is tx-able.
- * @pdev: Pointer to pdev
- * @freq: Frequency in MHz
- * @in_6ghz_pwr_mode: Input AP power type
- *
- * An SP channel is tx-able if the channel is present in the AFC response.
- * In case of non-OUTDOOR mode a channel is always tx-able (Assuming it is
- * enabled by regulatory).
- *
- * Return: True if the frequency is tx-able, else false.
- */
-bool
-wlan_reg_is_6ghz_freq_txable(struct wlan_objmgr_pdev *pdev,
-			     qdf_freq_t freq,
-			     enum supported_6g_pwr_types in_6ghz_pwr_mode);
 #else
 static inline bool
 wlan_reg_is_afc_power_event_received(struct wlan_objmgr_pdev *pdev)
@@ -914,14 +897,6 @@ wlan_reg_is_sta_connect_allowed(struct wlan_objmgr_pdev *pdev,
 {
 	return true;
 }
-
-static inline bool
-wlan_reg_is_6ghz_freq_txable(struct wlan_objmgr_pdev *pdev,
-			     qdf_freq_t freq,
-			     enum supported_6g_pwr_types in_6ghz_pwr_mode)
-{
-	return false;
-}
 #endif
 
 #if defined(WLAN_FEATURE_11BE) && defined(CONFIG_REG_CLIENT)

+ 0 - 10
umac/regulatory/dispatcher/src/wlan_reg_services_api.c

@@ -179,16 +179,6 @@ wlan_reg_get_6g_afc_mas_chan_list(struct wlan_objmgr_pdev *pdev,
 }
 
 qdf_export_symbol(wlan_reg_get_6g_afc_mas_chan_list);
-
-bool
-wlan_reg_is_6ghz_freq_txable(struct wlan_objmgr_pdev *pdev,
-			     qdf_freq_t freq,
-			     enum supported_6g_pwr_types in_6ghz_pwr_mode)
-{
-	return reg_is_6ghz_freq_txable(pdev, freq, in_6ghz_pwr_mode);
-}
-
-qdf_export_symbol(wlan_reg_is_6ghz_freq_txable);
 #endif
 
 uint16_t wlan_reg_get_bw_value(enum phy_ch_width bw)