qcacld-3.0: Add BSS status caching
Add BSS status caching to get the BSS Information
when disconnect happens.
Change-Id: I41b74700b161277bc454d8bb8978f4e1e92faea8
CRs-Fixed: 1013475
diff --git a/core/mac/src/pe/include/lim_session.h b/core/mac/src/pe/include/lim_session.h
index 8f3f118..aeb7d5f 100644
--- a/core/mac/src/pe/include/lim_session.h
+++ b/core/mac/src/pe/include/lim_session.h
@@ -479,6 +479,10 @@
/* Supported NSS is intersection of self and peer NSS */
bool supported_nss_1x1;
bool is_ext_caps_present;
+ tDot11fIEHTCaps ht_caps;
+ tDot11fIEVHTCaps vht_caps;
+ tDot11fIEHTInfo ht_operation;
+ tDot11fIEVHTOperation vht_operation;
} tPESession, *tpPESession;
/*-------------------------------------------------------------------------
diff --git a/core/mac/src/pe/lim/lim_process_assoc_rsp_frame.c b/core/mac/src/pe/lim/lim_process_assoc_rsp_frame.c
index c6d9d70..573a288 100644
--- a/core/mac/src/pe/lim/lim_process_assoc_rsp_frame.c
+++ b/core/mac/src/pe/lim/lim_process_assoc_rsp_frame.c
@@ -973,6 +973,12 @@
ie_len,
beacon);
+ session_entry->vht_caps = beacon->VHTCaps;
+ session_entry->ht_caps = beacon->HTCaps;
+ session_entry->hs20vendor_ie = beacon->hs20vendor_ie;
+ session_entry->ht_operation = beacon->HTInfo;
+ session_entry->vht_operation = beacon->VHTOperation;
+
if (mac_ctx->lim.gLimProtectionControl !=
WNI_CFG_FORCE_POLICY_PROTECTION_DISABLE)
lim_decide_sta_protection_on_assoc(mac_ctx, beacon,
diff --git a/core/mac/src/pe/lim/lim_send_sme_rsp_messages.c b/core/mac/src/pe/lim/lim_send_sme_rsp_messages.c
index eab9439..9f6413f 100644
--- a/core/mac/src/pe/lim/lim_send_sme_rsp_messages.c
+++ b/core/mac/src/pe/lim/lim_send_sme_rsp_messages.c
@@ -388,6 +388,24 @@
#endif
}
}
+
+/**
+ * lim_add_bss_info() - copy data from session entry to join rsp
+ * @session_entry: PE Session Info
+ * @sme_join_rsp: Join response buffer to be filled up
+ *
+ * Return: None
+ */
+void lim_add_bss_info(tpPESession session_entry,
+ tpSirSmeJoinRsp sme_join_rsp)
+{
+ sme_join_rsp->hs20vendor_ie = session_entry->hs20vendor_ie;
+ sme_join_rsp->vht_caps = session_entry->vht_caps;
+ sme_join_rsp->ht_caps = session_entry->ht_caps;
+ sme_join_rsp->ht_operation = session_entry->ht_operation;
+ sme_join_rsp->vht_operation = session_entry->vht_operation;
+}
+
/**
* lim_send_sme_join_reassoc_rsp() - Send Response to Upper Layers
* @mac_ctx: Pointer to Global MAC structure
@@ -489,7 +507,7 @@
#ifdef FEATURE_WLAN_ESE
sme_join_rsp->tspecIeLen = 0;
#endif
-
+ lim_add_bss_info(session_entry, sme_join_rsp);
lim_handle_join_rsp_status(mac_ctx, session_entry, result_code,
sme_join_rsp);