Explorar el Código

qcacld-3.0: Not register vendor specific public action frame

Since converged P2P component supports rx vendor specific public
action frame, not register in hdd layer again.

Change-Id: Ic0aaecffbffeb61ff4413d46c58a97c2bfb4ea84
CRs-Fixed: 2024394
Wu Gao hace 8 años
padre
commit
84d120c6e2
Se han modificado 2 ficheros con 62 adiciones y 2 borrados
  1. 52 0
      core/hdd/src/wlan_hdd_cfg80211.c
  2. 10 2
      core/mac/src/pe/lim/lim_process_action_frame.c

+ 52 - 0
core/hdd/src/wlan_hdd_cfg80211.c

@@ -10583,6 +10583,57 @@ void wlan_hdd_cfg80211_update_wiphy_caps(struct wiphy *wiphy)
 }
 
 /* This function registers for all frame which supplicant is interested in */
+#ifdef CONVERGED_P2P_ENABLE
+void wlan_hdd_cfg80211_register_frames(hdd_adapter_t *pAdapter)
+{
+	tHalHandle hHal = WLAN_HDD_GET_HAL_CTX(pAdapter);
+	/* Register for all P2P action, public action etc frames */
+	uint16_t type = (SIR_MAC_MGMT_FRAME << 2) | (SIR_MAC_MGMT_ACTION << 4);
+
+	ENTER();
+
+	/* Register frame indication call back */
+	sme_register_mgmt_frame_ind_callback(hHal, hdd_indicate_mgmt_frame);
+
+	/* Register for p2p ack indication */
+	sme_register_p2p_ack_ind_callback(hHal, hdd_send_action_cnf_cb);
+
+	/* Right now we are registering these frame when driver is getting
+	 * initialized. Once we will move to 2.6.37 kernel, in which we have
+	 * frame register ops, we will move this code as a part of that
+	 */
+
+	/* GAS Initial Request */
+	sme_register_mgmt_frame(hHal, SME_SESSION_ID_ANY, type,
+				(uint8_t *) GAS_INITIAL_REQ,
+				GAS_INITIAL_REQ_SIZE);
+
+	/* GAS Initial Response */
+	sme_register_mgmt_frame(hHal, SME_SESSION_ID_ANY, type,
+				(uint8_t *) GAS_INITIAL_RSP,
+				GAS_INITIAL_RSP_SIZE);
+
+	/* GAS Comeback Request */
+	sme_register_mgmt_frame(hHal, SME_SESSION_ID_ANY, type,
+				(uint8_t *) GAS_COMEBACK_REQ,
+				GAS_COMEBACK_REQ_SIZE);
+
+	/* GAS Comeback Response */
+	sme_register_mgmt_frame(hHal, SME_SESSION_ID_ANY, type,
+				(uint8_t *) GAS_COMEBACK_RSP,
+				GAS_COMEBACK_RSP_SIZE);
+
+	/* WNM BSS Transition Request frame */
+	sme_register_mgmt_frame(hHal, SME_SESSION_ID_ANY, type,
+				(uint8_t *) WNM_BSS_ACTION_FRAME,
+				WNM_BSS_ACTION_FRAME_SIZE);
+
+	/* WNM-Notification */
+	sme_register_mgmt_frame(hHal, pAdapter->sessionId, type,
+				(uint8_t *) WNM_NOTIFICATION_FRAME,
+				WNM_NOTIFICATION_FRAME_SIZE);
+}
+#else
 void wlan_hdd_cfg80211_register_frames(hdd_adapter_t *pAdapter)
 {
 	tHalHandle hHal = WLAN_HDD_GET_HAL_CTX(pAdapter);
@@ -10642,6 +10693,7 @@ void wlan_hdd_cfg80211_register_frames(hdd_adapter_t *pAdapter)
 				(uint8_t *) WNM_NOTIFICATION_FRAME,
 				WNM_NOTIFICATION_FRAME_SIZE);
 }
+#endif
 
 void wlan_hdd_cfg80211_deregister_frames(hdd_adapter_t *pAdapter)
 {

+ 10 - 2
core/mac/src/pe/lim/lim_process_action_frame.c

@@ -1895,9 +1895,10 @@ void lim_process_action_frame(tpAniSirGlobal mac_ctx,
 	uint32_t frame_len;
 	tpSirMacVendorSpecificFrameHdr vendor_specific;
 	uint8_t oui[] = { 0x00, 0x00, 0xf0 };
+#ifndef CONVERGED_P2P_ENABLE
 	tpSirMacVendorSpecificPublicActionFrameHdr pub_action;
 	uint8_t p2p_oui[] = { 0x50, 0x6F, 0x9A, 0x09 };
-
+#endif
 #ifdef WLAN_FEATURE_11W
 	if (lim_is_robust_mgmt_action_frame(action_hdr->category) &&
 	   lim_drop_unprotected_action_frame(mac_ctx, session,
@@ -2152,6 +2153,7 @@ void lim_process_action_frame(tpAniSirGlobal mac_ctx,
 	break;
 	case SIR_MAC_ACTION_PUBLIC_USAGE:
 		switch (action_hdr->actionID) {
+#ifndef CONVERGED_P2P_ENABLE
 		case SIR_MAC_ACTION_VENDOR_SPECIFIC:
 			pub_action =
 				(tpSirMacVendorSpecificPublicActionFrameHdr)
@@ -2182,6 +2184,7 @@ void lim_process_action_frame(tpAniSirGlobal mac_ctx,
 					pub_action->Oui[2], pub_action->Oui[3]);
 			}
 		break;
+#endif
 		/* Handle vendor specific action */
 		case SIR_MAC_ACTION_VENDOR_SPECIFIC_CATEGORY:
 		{
@@ -2367,7 +2370,7 @@ void lim_process_action_frame(tpAniSirGlobal mac_ctx,
  * @param  *pBd - A pointer to Buffer descriptor + associated PDUs
  * @return None
  */
-
+#ifndef CONVERGED_P2P_ENABLE
 void lim_process_action_frame_no_session(tpAniSirGlobal pMac, uint8_t *pBd)
 {
 	uint8_t *pBody = WMA_GET_RX_MPDU_DATA(pBd);
@@ -2431,3 +2434,8 @@ void lim_process_action_frame_no_session(tpAniSirGlobal pMac, uint8_t *pBd)
 
 	}
 }
+#else
+void lim_process_action_frame_no_session(tpAniSirGlobal pMac, uint8_t *pBd)
+{
+}
+#endif