qcacld-3.0: Add support for flush PMKSA in fw

Currently, driver sends add/delete pmksa entry to fw
whenever supplicant sends set/delete pmksa to driver.

Add support to flush all PMKSA entries as well.

Change-Id: I044a25b071cab5c156b41bcaab338328b5439d64
CRs-Fixed: 2094257
This commit is contained in:
Vignesh Viswanathan 2017-10-11 20:38:47 +05:30 • committed by Varun Reddy Yeturu
commit e8a26b2ade
2 changed files with 8 additions and 0 deletions

View file

@ -18770,6 +18770,8 @@ static int __wlan_hdd_cfg80211_flush_pmksa(struct wiphy *wiphy,
hdd_err("Cannot flush PMKIDCache");
status = -EINVAL;
}
sme_set_del_pmkid_cache(halHandle, adapter->sessionId, NULL, false);
EXIT();
return status;
}

View file

@ -15578,8 +15578,13 @@ QDF_STATUS sme_set_del_pmkid_cache(tHalHandle hal, uint8_t session_id,
return QDF_STATUS_E_NOMEM;
}
qdf_mem_set(pmk_cache, sizeof(*pmk_cache), 0);
pmk_cache->session_id = session_id;
if (!pmk_cache_info)
goto send_flush_cmd;
if (!pmk_cache_info->ssid_len) {
pmk_cache->cat_flag = WMI_PMK_CACHE_CAT_FLAG_BSSID;
WMI_CHAR_ARRAY_TO_MAC_ADDR(pmk_cache_info->BSSID.bytes,
@ -15607,6 +15612,7 @@ QDF_STATUS sme_set_del_pmkid_cache(tHalHandle hal, uint8_t session_id,
qdf_mem_copy(pmk_cache->pmk, pmk_cache_info->pmk,
pmk_cache->pmk_len);
send_flush_cmd:
msg.type = SIR_HAL_SET_DEL_PMKID_CACHE;
msg.reserved = 0;
msg.bodyptr = pmk_cache;