|
@@ -5690,7 +5690,7 @@ int wlan_hdd_cfg80211_start_bss(struct hdd_adapter *adapter,
|
|
|
bool bval = false;
|
|
|
bool enable_dfs_scan = true;
|
|
|
bool deliver_start_evt = true;
|
|
|
- struct s_ext_cap *p_ext_cap;
|
|
|
+ struct s_ext_cap p_ext_cap = {0};
|
|
|
enum reg_phymode reg_phy_mode, updated_phy_mode;
|
|
|
struct sap_context *sap_ctx;
|
|
|
struct wlan_objmgr_vdev *vdev;
|
|
@@ -5837,13 +5837,16 @@ int wlan_hdd_cfg80211_start_bss(struct hdd_adapter *adapter,
|
|
|
if (ie) {
|
|
|
bool target_bigtk_support = false;
|
|
|
|
|
|
- p_ext_cap = (struct s_ext_cap *)(&ie[2]);
|
|
|
- hdd_err("beacon protection %d",
|
|
|
- p_ext_cap->beacon_protection_enable);
|
|
|
+ memcpy(&p_ext_cap, &ie[2], (ie[1] > sizeof(p_ext_cap)) ?
|
|
|
+ sizeof(p_ext_cap) : ie[1]);
|
|
|
+
|
|
|
+ hdd_debug("beacon protection %d",
|
|
|
+ p_ext_cap.beacon_protection_enable);
|
|
|
+
|
|
|
ucfg_mlme_get_bigtk_support(hdd_ctx->psoc,
|
|
|
&target_bigtk_support);
|
|
|
if (target_bigtk_support &&
|
|
|
- p_ext_cap->beacon_protection_enable)
|
|
|
+ p_ext_cap.beacon_protection_enable)
|
|
|
mlme_set_bigtk_support(vdev, true);
|
|
|
}
|
|
|
|