qcacld-3.0: Add global MAC filters to filter beacon/probe frames in PE
Add filter structures in global mac context and apply the filter for
beacon/probe frames received in pe_handle_mgmt_frames before posting
the frames to PE queue.
Change-Id: Ic0e574705764c1bb247977a4c86e394b47941f5b
CRs-Fixed: 2226223
diff --git a/core/mac/src/pe/lim/lim_process_sme_req_messages.c b/core/mac/src/pe/lim/lim_process_sme_req_messages.c
index 8ccba3c..83d21c5 100644
--- a/core/mac/src/pe/lim/lim_process_sme_req_messages.c
+++ b/core/mac/src/pe/lim/lim_process_sme_req_messages.c
@@ -1,9 +1,6 @@
/*
* Copyright (c) 2012-2018 The Linux Foundation. All rights reserved.
*
- * Previously licensed under the ISC license by Qualcomm Atheros, Inc.
- *
- *
* Permission to use, copy, modify, and/or distribute this software for
* any purpose with or without fee is hereby granted, provided that the
* above copyright notice and this permission notice appear in all
@@ -20,12 +17,6 @@
*/
/*
- * This file was originally distributed by Qualcomm Atheros, Inc.
- * under proprietary terms before Copyright ownership was assigned
- * to the Linux Foundation.
- */
-
-/*
* This file lim_process_sme_req_messages.cc contains the code
* for processing SME request messages.
* Author: Chandra Modumudi
@@ -643,6 +634,11 @@
ret_code = eSIR_SME_RESOURCES_UNAVAILABLE;
goto free;
}
+
+ /* Update the beacon/probe filter in mac_ctx */
+ lim_set_bcn_probe_filter(mac_ctx, session,
+ &sme_start_bss_req->ssId,
+ sme_start_bss_req->channelId);
}
if (QDF_NDI_MODE != sme_start_bss_req->bssPersona) {
@@ -676,9 +672,6 @@
/* Store the session related params in newly created session */
session->pLimStartBssReq = sme_start_bss_req;
- /* Store PE session_id in session Table */
- session->peSessionId = session_id;
-
/* Store SME session Id in sessionTable */
session->smeSessionId = sme_start_bss_req->sessionId;
@@ -1328,17 +1321,21 @@
pe_err("Session Can not be created");
ret_code = eSIR_SME_RESOURCES_UNAVAILABLE;
goto end;
- } else
+ } else {
pe_debug("SessionId:%d New session created",
session_id);
+ }
+
+ /* Update the beacon/probe filter in mac_ctx */
+ lim_set_bcn_probe_filter(mac_ctx, session,
+ &sme_join_req->ssId,
+ bss_desc->channelId);
}
session->max_amsdu_num = sme_join_req->max_amsdu_num;
/*
* Store Session related parameters
- * Store PE session Id in session Table
*/
- session->peSessionId = session_id;
/* store the smejoin req handle in session table */
session->pLimJoinReq = sme_join_req;