Переглянути джерело

qcacmn: Target_if changes for QCN9100 bringup

Initial changes for bring up of QCN9100 in
target_if layer

Change-Id: I216cb52001b6e0c87a1c4b45990aad0ea83b4933
Pavankumar Nandeshwar 4 роки тому
батько
коміт
42c974a68d

+ 2 - 0
target_if/cfr/src/target_if_cfr.c

@@ -365,6 +365,7 @@ int target_if_cfr_init_pdev(struct wlan_objmgr_psoc *psoc,
 		return cfr_wifi2_0_init_pdev(psoc, pdev);
 	} else if ((target_type == TARGET_TYPE_QCA6018) ||
 		   (target_type == TARGET_TYPE_QCN9000) ||
+		   (target_type == TARGET_TYPE_QCN9100) ||
 		   (target_type == TARGET_TYPE_QCA5018)) {
 		pa->is_cfr_capable = cfr_sc->is_cfr_capable;
 		return cfr_enh_init_pdev(psoc, pdev);
@@ -393,6 +394,7 @@ int target_if_cfr_deinit_pdev(struct wlan_objmgr_psoc *psoc,
 		return cfr_wifi2_0_deinit_pdev(psoc, pdev);
 	} else if ((target_type == TARGET_TYPE_QCA6018) ||
 		   (target_type == TARGET_TYPE_QCN9000) ||
+		   (target_type == TARGET_TYPE_QCN9100) ||
 		   (target_type == TARGET_TYPE_QCA5018)) {
 		return cfr_enh_deinit_pdev(psoc, pdev);
 	} else

+ 8 - 0
target_if/core/inc/target_if.h

@@ -530,6 +530,14 @@ bool target_is_tgt_type_adrastea(uint32_t target_type);
  */
 bool target_is_tgt_type_qcn9000(uint32_t target_type);
 
+/**
+ * target_is_tgt_type_qcn9100() - Check if the target type is QCN9100 (Spruce)
+ * @target_type: target type to be checked.
+ *
+ * Return: true if the target_type is QCN9100, else false.
+ */
+bool target_is_tgt_type_qcn9100(uint32_t target_type);
+
 /**
  * target_psoc_set_wlan_init_status() - set info wlan_init_status
  * @psoc_info:          pointer to structure target_psoc_info

+ 8 - 0
target_if/core/src/target_if_main.c

@@ -408,6 +408,9 @@ static void target_if_target_tx_ops_register(
 	target_tx_ops->tgt_is_tgt_type_qcn9000 =
 		target_is_tgt_type_qcn9000;
 
+	target_tx_ops->tgt_is_tgt_type_qcn9100 =
+		target_is_tgt_type_qcn9100;
+
 	target_tx_ops->tgt_get_tgt_type =
 		lmac_get_tgt_type;
 
@@ -680,6 +683,11 @@ bool target_is_tgt_type_qcn9000(uint32_t target_type)
 	return target_type == TARGET_TYPE_QCN9000;
 }
 
+bool target_is_tgt_type_qcn9100(uint32_t target_type)
+{
+	return target_type == TARGET_TYPE_QCN9100;
+}
+
 QDF_STATUS
 target_pdev_is_scan_radio_supported(struct wlan_objmgr_pdev *pdev,
 				    bool *is_scan_radio_supported)

+ 1 - 0
target_if/init_deinit/src/service_ready_util.c

@@ -891,6 +891,7 @@ QDF_STATUS init_deinit_validate_160_80p80_fw_caps(
 
 	if ((tgt_hdl->info.target_type == TARGET_TYPE_QCA8074) ||
 	    (tgt_hdl->info.target_type == TARGET_TYPE_QCA8074V2) ||
+	    (tgt_hdl->info.target_type == TARGET_TYPE_QCN9100) ||
 	    (tgt_hdl->info.target_type == TARGET_TYPE_QCA6290)) {
 		/**
 		 * Return true for now. This is not available in

+ 6 - 1
target_if/spectral/target_if_spectral.c

@@ -2160,6 +2160,7 @@ target_if_spectral_len_adj_swar_init(struct spectral_fft_bin_len_adj_swar *swar,
 {
 	if (target_type == TARGET_TYPE_QCA8074V2 ||
 	    target_type == TARGET_TYPE_QCN9000 ||
+	    target_type == TARGET_TYPE_QCN9100 ||
 	    target_type == TARGET_TYPE_QCA5018 ||
 	    target_type == TARGET_TYPE_QCA6750 ||
 	    target_type == TARGET_TYPE_QCA6490)
@@ -2174,6 +2175,7 @@ target_if_spectral_len_adj_swar_init(struct spectral_fft_bin_len_adj_swar *swar,
 	if (target_type == TARGET_TYPE_QCA8074 ||
 	    target_type == TARGET_TYPE_QCA8074V2 ||
 	    target_type == TARGET_TYPE_QCA6018 ||
+	    target_type == TARGET_TYPE_QCN9100 ||
 	    target_type == TARGET_TYPE_QCA5018 ||
 	    target_type == TARGET_TYPE_QCN9000 ||
 	    target_type == TARGET_TYPE_QCA6490) {
@@ -2184,7 +2186,8 @@ target_if_spectral_len_adj_swar_init(struct spectral_fft_bin_len_adj_swar *swar,
 		swar->null_fftbin_adj = 0;
 	}
 
-	if (target_type == TARGET_TYPE_QCA8074V2)
+	if ((target_type == TARGET_TYPE_QCA8074V2) ||
+	    (target_type == TARGET_TYPE_QCN9100))
 		swar->packmode_fftbin_size_adj = 1;
 	else
 		swar->packmode_fftbin_size_adj = 0;
@@ -2379,6 +2382,7 @@ target_if_pdev_spectral_init(struct wlan_objmgr_pdev *pdev)
 	    target_type == TARGET_TYPE_QCA6018 ||
 	    target_type == TARGET_TYPE_QCA5018 ||
 	    target_type == TARGET_TYPE_QCA6390 ||
+	    target_type == TARGET_TYPE_QCN9100 ||
 	    target_type == TARGET_TYPE_QCA6490 ||
 	    target_type == TARGET_TYPE_QCN9000 ||
 	    target_type == TARGET_TYPE_QCA6750)
@@ -2392,6 +2396,7 @@ target_if_pdev_spectral_init(struct wlan_objmgr_pdev *pdev)
 	    (target_type == TARGET_TYPE_QCA8074V2) ||
 	    (target_type == TARGET_TYPE_QCA6018) ||
 	    (target_type == TARGET_TYPE_QCA5018) ||
+	    (target_type == TARGET_TYPE_QCN9100) ||
 	    (target_type == TARGET_TYPE_QCN9000) ||
 	    (target_type == TARGET_TYPE_QCA6290) ||
 	    (target_type == TARGET_TYPE_QCA6390) ||

+ 8 - 2
umac/dfs/core/src/misc/dfs.c

@@ -978,8 +978,14 @@ bool dfs_is_true_160mhz_supported(struct wlan_dfs *dfs)
 	}
 	target_type = lmac_get_target_type(dfs->dfs_pdev_obj);
 	tgt_tx_ops = &tx_ops->target_tx_ops;
-	if (tgt_tx_ops->tgt_is_tgt_type_qcn9000)
-		return tgt_tx_ops->tgt_is_tgt_type_qcn9000(target_type);
+	if (tgt_tx_ops->tgt_is_tgt_type_qcn9000 &&
+	    tgt_tx_ops->tgt_is_tgt_type_qcn9000(target_type))
+		return true;
+
+	if (tgt_tx_ops->tgt_is_tgt_type_qcn9100 &&
+	    tgt_tx_ops->tgt_is_tgt_type_qcn9100(target_type))
+		return true;
+
 	return false;
 }
 

+ 2 - 0
umac/global_umac_dispatcher/lmac_if/inc/wlan_lmac_if_def.h

@@ -974,6 +974,7 @@ struct wlan_lmac_if_dfs_tx_ops {
  * @tgt_is_tgt_type_qca9888: To check QCA9888 target type.
  * @tgt_is_tgt_type_adrastea: To check QCS40X target type.
  * @tgt_is_tgt_type_qcn9000: To check QCN9000 (Pine) target type.
+ * @tgt_is_tgt_type_qcn9100: To check QCN9100 (Spruce) target type.
  * @tgt_get_tgt_type:        Get target type
  * @tgt_get_tgt_version:     Get target version
  * @tgt_get_tgt_revision:    Get target revision
@@ -985,6 +986,7 @@ struct wlan_lmac_if_target_tx_ops {
 	bool (*tgt_is_tgt_type_qca9888)(uint32_t);
 	bool (*tgt_is_tgt_type_adrastea)(uint32_t);
 	bool (*tgt_is_tgt_type_qcn9000)(uint32_t);
+	bool (*tgt_is_tgt_type_qcn9100)(uint32_t);
 	uint32_t (*tgt_get_tgt_type)(struct wlan_objmgr_psoc *psoc);
 	uint32_t (*tgt_get_tgt_version)(struct wlan_objmgr_psoc *psoc);
 	uint32_t (*tgt_get_tgt_revision)(struct wlan_objmgr_psoc *psoc);