Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 4ec44a7d authored by Abhishek Singh's avatar Abhishek Singh Committed by nshrivas
Browse files

qcacld-3.0: Optimize logs in connect req in HDD and CSR

Remove redundant logs and optimize the logs for connect in
HDD and CSR.

Change-Id: I2d2d63aaaff814d91018e95a30869b81c1349a80
CRs-Fixed: 2615902
parent 57f6b62f
Loading
Loading
Loading
Loading
+7 −27
Original line number Diff line number Diff line
/*
 * Copyright (c) 2012-2019 The Linux Foundation. All rights reserved.
 * Copyright (c) 2012-2020 The Linux Foundation. All rights reserved.
 *
 * Permission to use, copy, modify, and/or distribute this software for
 * any purpose with or without fee is hereby granted, provided that the
@@ -895,7 +895,6 @@ action_oui_search(struct action_oui_psoc_priv *psoc_priv,
	qdf_mutex_acquire(&oui_priv->extension_lock);
	if (qdf_list_empty(extension_list)) {
		qdf_mutex_release(&oui_priv->extension_lock);
		action_oui_debug("OUI List Empty");
		return false;
	}

@@ -911,44 +910,25 @@ action_oui_search(struct action_oui_psoc_priv *psoc_priv,
		 * to other checks skipping the OUI and vendor data checks
		 */

		if (!(extension->info_mask & ACTION_OUI_INFO_OUI)) {
			action_oui_debug("Wildcard OUI found");
		if (!(extension->info_mask & ACTION_OUI_INFO_OUI))
			wildcard_oui = true;
		}

		oui_ptr = action_oui_get_oui_ptr(extension, attr);

		if (!oui_ptr  && !wildcard_oui) {
			action_oui_debug("No matching IE found for OUI");
			QDF_TRACE_HEX_DUMP(QDF_MODULE_ID_PE,
					   QDF_TRACE_LEVEL_DEBUG,
					   extension->oui,
					   extension->oui_length);
		if (!oui_ptr  && !wildcard_oui)
			goto next;
		}

		action_oui_debug("IE found for OUI");
		QDF_TRACE_HEX_DUMP(QDF_MODULE_ID_PE,
				   QDF_TRACE_LEVEL_DEBUG,
				   extension->oui,
				   extension->oui_length);

		if (extension->data_length && !wildcard_oui &&
		    !check_for_vendor_oui_data(extension, oui_ptr)) {
			action_oui_debug("Vendor IE Data mismatch");
		    !check_for_vendor_oui_data(extension, oui_ptr))
			goto next;
		}


		if ((extension->info_mask & ACTION_OUI_INFO_MAC_ADDRESS) &&
		    !check_for_vendor_ap_mac(extension, attr)) {
			action_oui_debug("Vendor IE MAC Mismatch");
		    !check_for_vendor_ap_mac(extension, attr))
			goto next;
		}

		if (!check_for_vendor_ap_capabilities(extension, attr)) {
			action_oui_debug("Vendor IE capabilties mismatch");
		if (!check_for_vendor_ap_capabilities(extension, attr))
			goto next;
		}

		action_oui_debug("Vendor AP/STA found for OUI");
		QDF_TRACE_HEX_DUMP(QDF_MODULE_ID_PE, QDF_TRACE_LEVEL_DEBUG,
+1 −3
Original line number Diff line number Diff line
@@ -141,8 +141,6 @@ QDF_STATUS ucfg_action_oui_send(struct wlan_objmgr_psoc *psoc)
	QDF_STATUS status = QDF_STATUS_E_INVAL;
	uint32_t id;

	ACTION_OUI_ENTER();

	if (!psoc) {
		action_oui_err("psoc is NULL");
		goto exit;
@@ -161,7 +159,7 @@ QDF_STATUS ucfg_action_oui_send(struct wlan_objmgr_psoc *psoc)
	}

exit:
	ACTION_OUI_EXIT();

	return status;
}

+10 −36
Original line number Diff line number Diff line
@@ -266,9 +266,12 @@ void hdd_conn_set_connection_state(struct hdd_adapter *adapter,
	uint32_t time_buffer_size;

	/* save the new connection state */
	hdd_debug("Changed conn state from old:%d to new:%d for dev %s",
	if (conn_state == hdd_sta_ctx->conn_info.conn_state)
		return;

	hdd_nofl_debug("connection state changed %d --> %d for dev %s (vdev %d)",
		       hdd_sta_ctx->conn_info.conn_state, conn_state,
		  adapter->dev->name);
		       adapter->dev->name, adapter->vdev_id);

	hdd_tsf_notify_wlan_state_change(adapter,
					 hdd_sta_ctx->conn_info.conn_state,
@@ -5078,7 +5081,7 @@ enum csr_akm_type hdd_translate_rsn_to_csr_auth_type(uint8_t auth_suite[4])
		hdd_translate_fils_rsn_to_csr_auth(auth_suite, &auth_type);
		hdd_translate_sae_rsn_to_csr_auth(auth_suite, &auth_type);
	}
	hdd_debug("auth_type: %d", auth_type);

	return auth_type;
}

@@ -5105,7 +5108,7 @@ enum csr_akm_type hdd_translate_wpa_to_csr_auth_type(uint8_t auth_suite[4])
	{
		hdd_translate_fils_rsn_to_csr_auth(auth_suite, &auth_type);
	}
	hdd_debug("auth_type: %d", auth_type);

	return auth_type;
}

@@ -5138,7 +5141,6 @@ hdd_translate_rsn_to_csr_encryption_type(uint8_t cipher_suite[4])
	else
		cipher_type = eCSR_ENCRYPT_TYPE_FAILED;

	hdd_debug("cipher_type: %d", cipher_type);
	return cipher_type;
}

@@ -5167,7 +5169,6 @@ hdd_translate_wpa_to_csr_encryption_type(uint8_t cipher_suite[4])
	else
		cipher_type = eCSR_ENCRYPT_TYPE_FAILED;

	hdd_debug("cipher_type: %d", cipher_type);
	return cipher_type;
}

@@ -5251,13 +5252,7 @@ static int32_t hdd_process_genie(struct hdd_adapter *adapter,
				parse_status);
			return -EINVAL;
		}
		hdd_debug("gp_cipher_suite_present: %d",
			 dot11_rsn_ie.gp_cipher_suite_present);
		/* Copy out the encryption and authentication types */
		hdd_debug("pairwise cipher suite count: %d",
			 dot11_rsn_ie.pwise_cipher_suite_count);
		hdd_debug("authentication suite count: %d",
			 dot11_rsn_ie.akm_suite_cnt);

		/* dot11_rsn_ie.akm_suite_cnt */
		/* Just translate the FIRST one */
		*auth_type =
@@ -5298,11 +5293,7 @@ static int32_t hdd_process_genie(struct hdd_adapter *adapter,
				parse_status);
			return -EINVAL;
		}
		/* Copy out the encryption and authentication types */
		hdd_debug("WPA unicast cipher suite count: %d",
			 dot11_wpa_ie.unicast_cipher_count);
		hdd_debug("WPA authentication suite count: %d",
			 dot11_wpa_ie.auth_suite_count);

		/* dot11_wpa_ie.auth_suite_count */
		/* Just translate the FIRST one */
		*auth_type =
@@ -5405,7 +5396,6 @@ static void hdd_update_values_mfp_cap(
 */
static void hdd_set_mfp_enable(struct csr_roam_profile *roam_profile)
{
	hdd_debug("MFPEnabled %d", roam_profile->MFPEnabled);
	/*
	 * Reset MFPEnabled if testmode RSNE passed doesn't have MFPR
	 * or MFPC bit set
@@ -5538,9 +5528,6 @@ int hdd_set_genie_to_csr(struct hdd_adapter *adapter,

		hdd_update_values_mfp_cap(roam_profile, mfp_required,
					  mfp_capable);

		hdd_debug("CSR AuthType = %d, EncryptionType = %d mcEncryptionType = %d",
			 *rsn_auth_type, rsn_encrypt_type, mc_rsn_encrypt_type);
	}

	if (QDF_STATUS_SUCCESS != wlan_set_vdev_crypto_prarams_from_ie(
@@ -5621,9 +5608,6 @@ int hdd_set_csr_auth_type(struct hdd_adapter *adapter,

	roam_profile = hdd_roam_profile(adapter);
	roam_profile->AuthType.numEntries = 1;
	hdd_debug("auth_type = %d rsn_auth_type %d wpa_versions %d key_mgmt : 0x%x",
		  sta_ctx->conn_info.auth_type, rsn_auth_type,
		  sta_ctx->wpa_versions, key_mgmt);

	switch (sta_ctx->conn_info.auth_type) {
	case eCSR_AUTH_TYPE_OPEN_SYSTEM:
@@ -5642,11 +5626,9 @@ int hdd_set_csr_auth_type(struct hdd_adapter *adapter,
			if ((rsn_auth_type == eCSR_AUTH_TYPE_CCKM_WPA) &&
			    ((key_mgmt & HDD_AUTH_KEY_MGMT_802_1X)
			     == HDD_AUTH_KEY_MGMT_802_1X)) {
				hdd_debug("set authType to CCKM WPA. AKM also 802.1X.");
				roam_profile->AuthType.authType[0] =
					eCSR_AUTH_TYPE_CCKM_WPA;
			} else if (rsn_auth_type == eCSR_AUTH_TYPE_CCKM_WPA) {
				hdd_debug("Last chance to set authType to CCKM WPA.");
				roam_profile->AuthType.authType[0] =
					eCSR_AUTH_TYPE_CCKM_WPA;
			} else
@@ -5670,11 +5652,9 @@ int hdd_set_csr_auth_type(struct hdd_adapter *adapter,
			if ((rsn_auth_type == eCSR_AUTH_TYPE_CCKM_RSN) &&
			    ((key_mgmt & HDD_AUTH_KEY_MGMT_802_1X)
			     == HDD_AUTH_KEY_MGMT_802_1X)) {
				hdd_debug("set authType to CCKM RSN. AKM also 802.1X.");
				roam_profile->AuthType.authType[0] =
					eCSR_AUTH_TYPE_CCKM_RSN;
			} else if (rsn_auth_type == eCSR_AUTH_TYPE_CCKM_RSN) {
				hdd_debug("Last chance to set authType to CCKM RSN.");
				roam_profile->AuthType.authType[0] =
					eCSR_AUTH_TYPE_CCKM_RSN;
			} else
@@ -5712,9 +5692,6 @@ int hdd_set_csr_auth_type(struct hdd_adapter *adapter,
				rsn_auth_type)) {
				roam_profile->AuthType.authType[0] =
					rsn_auth_type;
				hdd_debug("updated profile authtype as %d",
					rsn_auth_type);

			} else if ((rsn_auth_type == eCSR_AUTH_TYPE_OWE) &&
				  ((key_mgmt & HDD_AUTH_KEY_MGMT_802_1X)
				  == HDD_AUTH_KEY_MGMT_802_1X)) {
@@ -5791,9 +5768,6 @@ int hdd_set_csr_auth_type(struct hdd_adapter *adapter,
		break;
	}

	hdd_debug("Set roam Authtype to %d",
		 roam_profile->AuthType.authType[0]);

	return 0;
}

+85 −172

File changed.

Preview size limit exceeded, changes collapsed.

+3 −5
Original line number Diff line number Diff line
@@ -7647,7 +7647,6 @@ void hdd_set_disconnect_status(struct hdd_adapter *adapter, bool status)
	qdf_mutex_acquire(&adapter->disconnection_status_lock);
	adapter->disconnection_in_progress = status;
	qdf_mutex_release(&adapter->disconnection_status_lock);
	hdd_debug("setting disconnection status: %d", status);
}

#ifdef FEATURE_RUNTIME_PM
@@ -13446,10 +13445,8 @@ void wlan_hdd_disable_roaming(struct hdd_adapter *cur_adapter,
	struct csr_roam_profile *roam_profile;
	struct hdd_station_ctx *sta_ctx;

	if (!policy_mgr_is_sta_active_connection_exists(hdd_ctx->psoc)) {
		hdd_debug("No active sta session");
	if (!policy_mgr_is_sta_active_connection_exists(hdd_ctx->psoc))
		return;
	}

	hdd_for_each_adapter(hdd_ctx, adapter) {
		roam_profile = hdd_roam_profile(adapter);
@@ -15858,7 +15855,8 @@ bool hdd_is_roaming_in_progress(struct hdd_context *hdd_ctx)
		return false;
	}

	hdd_debug("roaming_in_progress = %d", hdd_ctx->roaming_in_progress);
	if (hdd_ctx->roaming_in_progress)
		hdd_debug("Roaming is in progress");

	return hdd_ctx->roaming_in_progress;
}
Loading