diff --git a/core/hdd/src/wlan_hdd_assoc.c b/core/hdd/src/wlan_hdd_assoc.c index 2206a5244632..8f2177b59ee3 100644 --- a/core/hdd/src/wlan_hdd_assoc.c +++ b/core/hdd/src/wlan_hdd_assoc.c @@ -1535,6 +1535,13 @@ static void hdd_conn_remove_connect_info(struct hdd_station_ctx *sta_ctx) sta_ctx->conn_info.proxy_arp_service = 0; qdf_mem_zero(&sta_ctx->conn_info.ssid, sizeof(tCsrSSIDInfo)); + + /* + * Reset the ptk, gtk status flags to avoid using current connection + * status in further connections. + */ + sta_ctx->conn_info.gtk_installed = false; + sta_ctx->conn_info.ptk_installed = false; } /** diff --git a/core/hdd/src/wlan_hdd_cfg80211.c b/core/hdd/src/wlan_hdd_cfg80211.c index 2a5234174e0b..30d551cf5b32 100644 --- a/core/hdd/src/wlan_hdd_cfg80211.c +++ b/core/hdd/src/wlan_hdd_cfg80211.c @@ -17775,6 +17775,13 @@ static int wlan_hdd_cfg80211_connect_start(struct hdd_adapter *adapter, qdf_mem_zero(&hdd_sta_ctx->conn_info.conn_flag, sizeof(hdd_sta_ctx->conn_info.conn_flag)); + /* + * Reset the ptk, gtk status flags to avoid using old/previous + * connection status. + */ + hdd_sta_ctx->conn_info.gtk_installed = false; + hdd_sta_ctx->conn_info.ptk_installed = false; + roam_profile = hdd_roam_profile(adapter); if (roam_profile) { struct hdd_station_ctx *sta_ctx;