Răsfoiți Sursa

qcacmn: Fetch fw cap to support p2p + p2p concurrency

Fetch fw capability to support p2p+p2p concurrency and
store cap info in 29th bit of soc_fw_ext_caps.

Change-Id: Id8e4c0310f8db503a2997e8aed5a6f1ce813dcc7
CRs-Fixed: 3032068
sheenam monga 3 ani în urmă
părinte
comite
a554290f06

+ 19 - 0
target_if/init_deinit/src/init_event_handler.c

@@ -42,6 +42,24 @@ static void init_deinit_set_send_init_cmd(struct wlan_objmgr_psoc *psoc,
 	init_deinit_prepare_send_init_cmd(psoc, tgt_hdl);
 }
 
+#ifdef WLAN_FEATURE_P2P_P2P_STA
+static void
+init_deinit_update_p2p_p2p_conc_support(struct wmi_unified *wmi_handle,
+					struct wlan_objmgr_psoc *psoc)
+{
+	if (wmi_service_enabled(wmi_handle, wmi_service_p2p_p2p_cc_support))
+		wlan_psoc_nif_fw_ext_cap_set(psoc,
+					     WLAN_SOC_EXT_P2P_P2P_CONC_SUPPORT);
+	else
+		target_if_debug("P2P + P2P conc disabled");
+}
+#else
+static inline void
+init_deinit_update_p2p_p2p_conc_support(struct wmi_unified *wmi_handle,
+					struct wlan_objmgr_psoc *psoc)
+{}
+#endif
+
 static int init_deinit_service_ready_event_handler(ol_scn_t scn_handle,
 							uint8_t *event,
 							uint32_t data_len)
@@ -213,6 +231,7 @@ static int init_deinit_service_ready_event_handler(ol_scn_t scn_handle,
 					       WLAN_SOC_CEXT_WMI_MGMT_REF);
 		target_if_debug("WMI mgmt service disabled");
 	}
+	init_deinit_update_p2p_p2p_conc_support(wmi_handle, psoc);
 
 	err_code = init_deinit_handle_host_mem_req(psoc, tgt_hdl, event);
 	if (err_code != QDF_STATUS_SUCCESS)

+ 2 - 0
umac/cmn_services/obj_mgr/inc/wlan_objmgr_psoc_obj.h

@@ -152,6 +152,8 @@
 #define WLAN_SOC_RTT_AP_INITIATOR_BURSTED_MODE_SUPPORTED 0x08000000
 	/* ext cc event supported by fw */
 #define WLAN_SOC_EXT_EVENT_SUPPORTED      0x010000000
+	/* check 29th bit for p2p + p2p conc support by fw */
+#define WLAN_SOC_EXT_P2P_P2P_CONC_SUPPORT 0x20000000
 
 /* feature_flags */
 	/* CONF: ATH FF enabled */