wlan:pmf: Fix to send Protected SA Query from hostapd_cli

SAP was sending unprotected SA Query when triggered by
hostapd_cli even if the connection is PMF.
This change set provides the fix so that
1. SA Query is protected in case of PMF connection.
2. SA Query is unprotected in case of non-PMF connection.
3. SA Query is dropped if SAP is not connected to the given STA.

CRs-Fixed: 685220

Change-Id: I2eb1c9b543e1bf67d84498ac695c297cedc45120
diff --git a/CORE/HDD/src/wlan_hdd_p2p.c b/CORE/HDD/src/wlan_hdd_p2p.c
index b73904f..cb60db4 100644
--- a/CORE/HDD/src/wlan_hdd_p2p.c
+++ b/CORE/HDD/src/wlan_hdd_p2p.c
@@ -879,9 +879,6 @@
     tActionFrmType actionFrmType;
     bool noack = 0;
     int status;
-#ifdef WLAN_FEATURE_11W
-    tANI_U8 *pTxFrmBuf = (tANI_U8 *) buf; // For SA Query, we have to set protect bit
-#endif
 
 #if (LINUX_VERSION_CODE >= KERNEL_VERSION(2,6,38))
     hdd_adapter_t *goAdapter;
@@ -1197,17 +1194,7 @@
                 hddLog(LOG1, "%s: HDD_GO_NEG_REQ_ACK_PENDING.", __func__);
             }
         }
-#ifdef WLAN_FEATURE_11W
-        if ((type == SIR_MAC_MGMT_FRAME) &&
-                (subType == SIR_MAC_MGMT_ACTION) &&
-                (buf[WLAN_HDD_PUBLIC_ACTION_FRAME_OFFSET] == WLAN_HDD_SA_QUERY_ACTION_FRAME))
-        {
-            VOS_TRACE( VOS_MODULE_ID_HDD, VOS_TRACE_LEVEL_ERROR,
-                     "%s: Calling sme_sendAction. For Category %s", __func__, "SA Query");
-            // Since this is an SA Query Action Frame, we have to protect it
-            WLAN_HDD_SET_WEP_FRM_FC(pTxFrmBuf[1]);
-        }
-#endif
+
         if (eHAL_STATUS_SUCCESS !=
                sme_sendAction( WLAN_HDD_GET_HAL_CTX(pAdapter),
                                sessionId, buf, len, wait, noack))