Browse Source

qcacld-3.0: Fix logging level in __wlan_hdd_cfg80211_del_key()

Del_key is called by supplicant for every key index and driver
logs error if mac address is NULL. This adds 18 ms delay due
to the kmsg error print and causes supplicant to delay
processing the EAPOL-1 frame, which leads to AP retrying
EAPOL-1 frame.

So change error log level in __wlan_hdd_cfg80211_del_key to
debug and remove redundant vdev id validation which is already
done in the caller.

Change-Id: I2dffd480a8ac2021b4683c5c5583ef9483935b5d
CRs-Fixed: 3260194
Pragaspathi Thilagaraj 2 years ago
parent
commit
9573437444
1 changed files with 5 additions and 8 deletions
  1. 5 8
      core/hdd/src/wlan_hdd_cfg80211.c

+ 5 - 8
core/hdd/src/wlan_hdd_cfg80211.c

@@ -20608,7 +20608,6 @@ static int __wlan_hdd_cfg80211_del_key(struct wiphy *wiphy,
 				       bool pairwise, const u8 *mac_addr)
 {
 	struct hdd_context *hdd_ctx = wiphy_priv(wiphy);
-	struct hdd_adapter *adapter = WLAN_HDD_GET_PRIV_PTR(ndev);
 	struct wlan_objmgr_peer *peer;
 	struct qdf_mac_addr peer_mac;
 	enum wlan_peer_type peer_type;
@@ -20617,18 +20616,16 @@ static int __wlan_hdd_cfg80211_del_key(struct wiphy *wiphy,
 
 	hdd_enter();
 
-	if (wlan_hdd_validate_vdev_id(adapter->vdev_id))
-		return -EINVAL;
+	if (!mac_addr) {
+		hdd_debug("Peer mac address is NULL");
+		hdd_exit();
+		return 0;
+	}
 
 	ret = wlan_hdd_validate_context(hdd_ctx);
 	if (ret)
 		return ret;
 
-	if (!mac_addr) {
-		hdd_err("Peer mac address is NULL");
-		return 0;
-	}
-
 	qdf_mem_copy(peer_mac.bytes, mac_addr, QDF_MAC_ADDR_SIZE);
 	if (qdf_is_macaddr_zero(&peer_mac) ||
 	    qdf_is_macaddr_broadcast(&peer_mac)) {