qcacld-3.0: Replace lim_log() with pe_* log levels in lim_process_assoc_req_frame.c

Replace lim_log() with pe_* appropriate log levels in
lim_process_assoc_req_frame.c

Change-Id: Ic0c990b49394cce9028c43b7d46d82c0e30e43e1
CRs-Fixed: 1093093
This commit is contained in:
Nishank Aggarwal
2017-03-23 19:11:08 +05:30
committed by snandini
vanhempi 524ee9a803
commit 8935e442a8

Näytä tiedosto

@@ -74,8 +74,7 @@ static void lim_convert_supported_channels(tpAniSirGlobal mac_ctx,
if (assoc_req->supportedChannels.length >= if (assoc_req->supportedChannels.length >=
SIR_MAX_SUPPORTED_CHANNEL_LIST) { SIR_MAX_SUPPORTED_CHANNEL_LIST) {
lim_log(mac_ctx, LOGE, pe_err("Number of supported channels: %d is more than MAX",
FL("Number of supported channels:%d is more than MAX"),
assoc_req->supportedChannels.length); assoc_req->supportedChannels.length);
assoc_ind->supportedChannels.numChnl = 0; assoc_ind->supportedChannels.numChnl = 0;
return; return;
@@ -90,13 +89,10 @@ static void lim_convert_supported_channels(tpAniSirGlobal mac_ctx,
/* Get Number of Channels in a Subband */ /* Get Number of Channels in a Subband */
chn_count = assoc_req->supportedChannels.supportedChannels[i]; chn_count = assoc_req->supportedChannels.supportedChannels[i];
lim_log(mac_ctx, LOGD, pe_debug("Rcv assoc_req: chnl: %d numOfChnl: %d",
FL("Rcv assoc_req: chnl=%d, numOfChnl=%d "),
first_ch_no, chn_count); first_ch_no, chn_count);
if (index >= SIR_MAX_SUPPORTED_CHANNEL_LIST) { if (index >= SIR_MAX_SUPPORTED_CHANNEL_LIST) {
lim_log(mac_ctx, LOGW, pe_warn("Ch count > max supported: %d", chn_count);
FL("Ch count > max supported =%d "),
chn_count);
assoc_ind->supportedChannels.numChnl = 0; assoc_ind->supportedChannels.numChnl = 0;
return; return;
} }
@@ -116,9 +112,7 @@ static void lim_convert_supported_channels(tpAniSirGlobal mac_ctx,
= next_ch_no; = next_ch_no;
index++; index++;
if (index >= SIR_MAX_SUPPORTED_CHANNEL_LIST) { if (index >= SIR_MAX_SUPPORTED_CHANNEL_LIST) {
lim_log(mac_ctx, LOGW, pe_warn("Ch count > supported: %d", chn_count);
FL("Ch count > supported =%d "),
chn_count);
assoc_ind->supportedChannels.numChnl = 0; assoc_ind->supportedChannels.numChnl = 0;
return; return;
} }
@@ -126,8 +120,7 @@ static void lim_convert_supported_channels(tpAniSirGlobal mac_ctx,
} }
assoc_ind->supportedChannels.numChnl = (uint8_t) index; assoc_ind->supportedChannels.numChnl = (uint8_t) index;
lim_log(mac_ctx, LOGD, pe_debug("Send AssocInd to WSM: minPwr: %d maxPwr: %d numChnl: %d",
FL("Send AssocInd to WSM: minPwr %d, maxPwr %d, numChnl %d"),
assoc_ind->powerCap.minTxPower, assoc_ind->powerCap.minTxPower,
assoc_ind->powerCap.maxTxPower, assoc_ind->powerCap.maxTxPower,
assoc_ind->supportedChannels.numChnl); assoc_ind->supportedChannels.numChnl);
@@ -168,9 +161,8 @@ static bool lim_check_sta_in_pe_entries(tpAniSirGlobal mac_ctx, tpSirMacMgmtHdr
(sessionid != session->peSessionId)) (sessionid != session->peSessionId))
#endif #endif
) { ) {
lim_log(mac_ctx, LOGE, pe_err("Sending Disassoc and Deleting existing STA entry:"
FL("Sending Disassoc and Deleting existing STA entry: " MAC_ADDRESS_STR,
MAC_ADDRESS_STR),
MAC_ADDR_ARRAY(session->selfMacAddr)); MAC_ADDR_ARRAY(session->selfMacAddr));
lim_send_disassoc_mgmt_frame(mac_ctx, lim_send_disassoc_mgmt_frame(mac_ctx,
eSIR_MAC_UNSPEC_FAILURE_REASON, eSIR_MAC_UNSPEC_FAILURE_REASON,
@@ -213,7 +205,7 @@ static bool lim_chk_sa_da(tpAniSirGlobal mac_ctx, tpSirMacMgmtHdr hdr,
(uint8_t) (sizeof(tSirMacAddr)))) (uint8_t) (sizeof(tSirMacAddr))))
return true; return true;
lim_log(mac_ctx, LOGE, FL("Assoc Req rejected: wlan.sa = wlan.da")); pe_err("Assoc Req rejected: wlan.sa = wlan.da");
lim_send_assoc_rsp_mgmt_frame(mac_ctx, eSIR_MAC_UNSPEC_FAILURE_STATUS, lim_send_assoc_rsp_mgmt_frame(mac_ctx, eSIR_MAC_UNSPEC_FAILURE_STATUS,
1, hdr->sa, sub_type, 0, session); 1, hdr->sa, sub_type, 0, session);
return false; return false;
@@ -240,8 +232,7 @@ static bool lim_chk_tkip(tpAniSirGlobal mac_ctx, tpSirMacMgmtHdr hdr,
if (!(session->bTkipCntrMeasActive && LIM_IS_AP_ROLE(session))) if (!(session->bTkipCntrMeasActive && LIM_IS_AP_ROLE(session)))
return true; return true;
lim_log(mac_ctx, LOGE, pe_err("Assoc Req rejected: TKIP counter measure is active");
FL("Assoc Req rejected: TKIP counter measure is active"));
lim_send_assoc_rsp_mgmt_frame(mac_ctx, eSIR_MAC_MIC_FAILURE_REASON, 1, lim_send_assoc_rsp_mgmt_frame(mac_ctx, eSIR_MAC_MIC_FAILURE_REASON, 1,
hdr->sa, sub_type, 0, session); hdr->sa, sub_type, 0, session);
return false; return false;
@@ -280,9 +271,8 @@ static bool lim_chk_assoc_req_parse_error(tpAniSirGlobal mac_ctx,
if (status == eSIR_SUCCESS) if (status == eSIR_SUCCESS)
return true; return true;
lim_log(mac_ctx, LOGW, pe_warn("Assoc Req rejected: frame parsing error. source addr:"
FL("Assoc Req rejected: frame parsing error. source addr:" MAC_ADDRESS_STR, MAC_ADDR_ARRAY(hdr->sa));
MAC_ADDRESS_STR), MAC_ADDR_ARRAY(hdr->sa));
lim_send_assoc_rsp_mgmt_frame(mac_ctx, eSIR_MAC_UNSPEC_FAILURE_STATUS, lim_send_assoc_rsp_mgmt_frame(mac_ctx, eSIR_MAC_UNSPEC_FAILURE_STATUS,
1, hdr->sa, sub_type, 0, session); 1, hdr->sa, sub_type, 0, session);
return false; return false;
@@ -308,7 +298,7 @@ static bool lim_chk_capab(tpAniSirGlobal mac_ctx, tpSirMacMgmtHdr hdr,
uint16_t temp; uint16_t temp;
if (cfg_get_capability_info(mac_ctx, &temp, session) != eSIR_SUCCESS) { if (cfg_get_capability_info(mac_ctx, &temp, session) != eSIR_SUCCESS) {
lim_log(mac_ctx, LOGE, FL("could not retrieve Capabilities")); pe_err("could not retrieve Capabilities");
return false; return false;
} }
@@ -316,9 +306,8 @@ static bool lim_chk_capab(tpAniSirGlobal mac_ctx, tpSirMacMgmtHdr hdr,
if (lim_compare_capabilities(mac_ctx, assoc_req, if (lim_compare_capabilities(mac_ctx, assoc_req,
local_cap, session) == false) { local_cap, session) == false) {
lim_log(mac_ctx, LOGW, pe_warn("Rcvd %s Req with unsupported capab from"
FL("Rcvd %s Req with unsupported capab from" MAC_ADDRESS_STR,
MAC_ADDRESS_STR),
(LIM_ASSOC == sub_type) ? "Assoc" : "ReAssoc", (LIM_ASSOC == sub_type) ? "Assoc" : "ReAssoc",
MAC_ADDR_ARRAY(hdr->sa)); MAC_ADDR_ARRAY(hdr->sa));
/* /*
@@ -353,9 +342,8 @@ static bool lim_chk_ssid(tpAniSirGlobal mac_ctx, tpSirMacMgmtHdr hdr,
if (lim_cmp_ssid(&assoc_req->ssId, session) != true) if (lim_cmp_ssid(&assoc_req->ssId, session) != true)
return true; return true;
lim_log(mac_ctx, LOGE, pe_err("%s Req with ssid wrong(Rcvd: %.*s self: %.*s) from "
FL("%s Req with ssid wrong(Rcvd: %.*s self: %.*s) from " MAC_ADDRESS_STR,
MAC_ADDRESS_STR),
(LIM_ASSOC == sub_type) ? "Assoc" : "ReAssoc", (LIM_ASSOC == sub_type) ? "Assoc" : "ReAssoc",
assoc_req->ssId.length, assoc_req->ssId.ssId, assoc_req->ssId.length, assoc_req->ssId.ssId,
session->ssId.length, session->ssId.ssId, session->ssId.length, session->ssId.ssId,
@@ -411,9 +399,8 @@ static bool lim_chk_rates(tpAniSirGlobal mac_ctx, tpSirMacMgmtHdr hdr,
if (lim_check_rx_basic_rates(mac_ctx, basic_rates, session) == true) if (lim_check_rx_basic_rates(mac_ctx, basic_rates, session) == true)
return true; return true;
lim_log(mac_ctx, LOGW, pe_warn("Assoc Req rejected: unsupported rates, soruce addr: %s"
FL("Assoc Req rejected: unsupported rates, soruce addr: %s" MAC_ADDRESS_STR,
MAC_ADDRESS_STR),
(LIM_ASSOC == sub_type) ? "Assoc" : "ReAssoc", (LIM_ASSOC == sub_type) ? "Assoc" : "ReAssoc",
MAC_ADDR_ARRAY(hdr->sa)); MAC_ADDR_ARRAY(hdr->sa));
/* /*
@@ -445,9 +432,8 @@ static bool lim_chk_11g_only(tpAniSirGlobal mac_ctx, tpSirMacMgmtHdr hdr,
if (LIM_IS_AP_ROLE(session) && if (LIM_IS_AP_ROLE(session) &&
(session->dot11mode == WNI_CFG_DOT11_MODE_11G_ONLY) && (session->dot11mode == WNI_CFG_DOT11_MODE_11G_ONLY) &&
(assoc_req->HTCaps.present)) { (assoc_req->HTCaps.present)) {
lim_log(mac_ctx, LOGE, pe_err("SOFTAP was in 11G only mode, rejecting legacy STA: "
FL("SOFTAP was in 11G only mode, rejecting legacy STA: " MAC_ADDRESS_STR,
MAC_ADDRESS_STR),
MAC_ADDR_ARRAY(hdr->sa)); MAC_ADDR_ARRAY(hdr->sa));
lim_send_assoc_rsp_mgmt_frame(mac_ctx, lim_send_assoc_rsp_mgmt_frame(mac_ctx,
eSIR_MAC_CAPABILITIES_NOT_SUPPORTED_STATUS, eSIR_MAC_CAPABILITIES_NOT_SUPPORTED_STATUS,
@@ -476,9 +462,8 @@ static bool lim_chk_11n_only(tpAniSirGlobal mac_ctx, tpSirMacMgmtHdr hdr,
if (LIM_IS_AP_ROLE(session) && if (LIM_IS_AP_ROLE(session) &&
(session->dot11mode == WNI_CFG_DOT11_MODE_11N_ONLY) && (session->dot11mode == WNI_CFG_DOT11_MODE_11N_ONLY) &&
(!assoc_req->HTCaps.present)) { (!assoc_req->HTCaps.present)) {
lim_log(mac_ctx, LOGE, pe_err("SOFTAP was in 11N only mode, rejecting legacy STA: "
FL("SOFTAP was in 11N only mode, rejecting legacy STA: " MAC_ADDRESS_STR,
MAC_ADDRESS_STR),
MAC_ADDR_ARRAY(hdr->sa)); MAC_ADDR_ARRAY(hdr->sa));
lim_send_assoc_rsp_mgmt_frame(mac_ctx, lim_send_assoc_rsp_mgmt_frame(mac_ctx,
eSIR_MAC_CAPABILITIES_NOT_SUPPORTED_STATUS, eSIR_MAC_CAPABILITIES_NOT_SUPPORTED_STATUS,
@@ -520,8 +505,7 @@ static bool lim_chk_11ac_only(tpAniSirGlobal mac_ctx, tpSirMacMgmtHdr hdr,
lim_send_assoc_rsp_mgmt_frame(mac_ctx, lim_send_assoc_rsp_mgmt_frame(mac_ctx,
eSIR_MAC_CAPABILITIES_NOT_SUPPORTED_STATUS, eSIR_MAC_CAPABILITIES_NOT_SUPPORTED_STATUS,
1, hdr->sa, sub_type, 0, session); 1, hdr->sa, sub_type, 0, session);
lim_log(mac_ctx, LOGE, pe_err("SOFTAP was in 11AC only mode, reject");
FL("SOFTAP was in 11AC only mode, reject"));
return false; return false;
} }
return true; return true;
@@ -559,17 +543,15 @@ lim_process_for_spectrum_mgmt(tpAniSirGlobal mac_ctx, tpSirMacMgmtHdr hdr,
* missing, log the peers error * missing, log the peers error
*/ */
if (!assoc_req->powerCapabilityPresent) { if (!assoc_req->powerCapabilityPresent) {
lim_log(mac_ctx, LOGW, pe_warn("LIM Info: Missing Power capability IE in %s Req from "
FL("LIM Info: Missing Power capability IE in %s Req from " MAC_ADDRESS_STR,
MAC_ADDRESS_STR),
(LIM_ASSOC == sub_type) ? (LIM_ASSOC == sub_type) ?
"Assoc" : "ReAssoc", "Assoc" : "ReAssoc",
MAC_ADDR_ARRAY(hdr->sa)); MAC_ADDR_ARRAY(hdr->sa));
} }
if (!assoc_req->supportedChannelsPresent) { if (!assoc_req->supportedChannelsPresent) {
lim_log(mac_ctx, LOGW, pe_warn("LIM Info: Missing Supported channel IE in %s Req from "
FL("LIM Info: Missing Supported channel IE in %s Req from " MAC_ADDRESS_STR,
MAC_ADDRESS_STR),
(LIM_ASSOC == sub_type) ? (LIM_ASSOC == sub_type) ?
"Assoc" : "ReAssoc", "Assoc" : "ReAssoc",
MAC_ADDR_ARRAY(hdr->sa)); MAC_ADDR_ARRAY(hdr->sa));
@@ -580,9 +562,8 @@ lim_process_for_spectrum_mgmt(tpAniSirGlobal mac_ctx, tpSirMacMgmtHdr hdr,
lim_is_dot11h_power_capabilities_in_range( lim_is_dot11h_power_capabilities_in_range(
mac_ctx, assoc_req, session); mac_ctx, assoc_req, session);
if (eSIR_SUCCESS != status) { if (eSIR_SUCCESS != status) {
lim_log(mac_ctx, LOGW, pe_warn("LIM Info: MinTxPower(STA) > MaxTxPower(AP) in %s Req from "
FL("LIM Info: MinTxPower(STA) > MaxTxPower(AP) in %s Req from " MAC_ADDRESS_STR,
MAC_ADDRESS_STR),
(LIM_ASSOC == sub_type) ? (LIM_ASSOC == sub_type) ?
"Assoc" : "ReAssoc", "Assoc" : "ReAssoc",
MAC_ADDR_ARRAY(hdr->sa)); MAC_ADDR_ARRAY(hdr->sa));
@@ -590,9 +571,8 @@ lim_process_for_spectrum_mgmt(tpAniSirGlobal mac_ctx, tpSirMacMgmtHdr hdr,
status = lim_is_dot11h_supported_channels_valid( status = lim_is_dot11h_supported_channels_valid(
mac_ctx, assoc_req); mac_ctx, assoc_req);
if (eSIR_SUCCESS != status) { if (eSIR_SUCCESS != status) {
lim_log(mac_ctx, LOGW, pe_warn("LIM Info: wrong supported channels (STA) in %s Req from "
FL("LIM Info: wrong supported channels (STA) in %s Req from " MAC_ADDRESS_STR,
MAC_ADDRESS_STR),
(LIM_ASSOC == sub_type) ? (LIM_ASSOC == sub_type) ?
"Assoc" : "ReAssoc", "Assoc" : "ReAssoc",
MAC_ADDR_ARRAY(hdr->sa)); MAC_ADDR_ARRAY(hdr->sa));
@@ -637,9 +617,8 @@ static bool lim_chk_mcs(tpAniSirGlobal mac_ctx, tpSirMacMgmtHdr hdr,
{ {
if ((assoc_req->HTCaps.present) && (lim_check_mcs_set(mac_ctx, if ((assoc_req->HTCaps.present) && (lim_check_mcs_set(mac_ctx,
assoc_req->HTCaps.supportedMCSSet) == false)) { assoc_req->HTCaps.supportedMCSSet) == false)) {
lim_log(mac_ctx, LOGW, pe_warn("rcvd %s req with unsupported MCS Rate Set from "
FL("rcvd %s req with unsupported MCS Rate Set from " MAC_ADDRESS_STR,
MAC_ADDRESS_STR),
(LIM_ASSOC == sub_type) ? "Assoc" : "ReAssoc", (LIM_ASSOC == sub_type) ? "Assoc" : "ReAssoc",
MAC_ADDR_ARRAY(hdr->sa)); MAC_ADDR_ARRAY(hdr->sa));
/* /*
@@ -679,8 +658,7 @@ static bool lim_chk_is_11b_sta_supported(tpAniSirGlobal mac_ctx,
if (phy_mode == WNI_CFG_PHY_MODE_11G) { if (phy_mode == WNI_CFG_PHY_MODE_11G) {
if (wlan_cfg_get_int(mac_ctx, WNI_CFG_11G_ONLY_POLICY, if (wlan_cfg_get_int(mac_ctx, WNI_CFG_11G_ONLY_POLICY,
&cfg_11g_only) != eSIR_SUCCESS) { &cfg_11g_only) != eSIR_SUCCESS) {
lim_log(mac_ctx, LOGE, pe_err("couldn't get 11g-only flag");
FL("couldn't get 11g-only flag"));
return false; return false;
} }
@@ -694,8 +672,7 @@ static bool lim_chk_is_11b_sta_supported(tpAniSirGlobal mac_ctx,
eSIR_MAC_BASIC_RATES_NOT_SUPPORTED_STATUS, eSIR_MAC_BASIC_RATES_NOT_SUPPORTED_STATUS,
1, hdr->sa, sub_type, 0, session); 1, hdr->sa, sub_type, 0, session);
lim_log(mac_ctx, LOGW, pe_warn("Rejecting Re/Assoc req from 11b STA:");
FL("Rejecting Re/Assoc req from 11b STA: "));
lim_print_mac_addr(mac_ctx, hdr->sa, LOGW); lim_print_mac_addr(mac_ctx, hdr->sa, LOGW);
#ifdef WLAN_DEBUG #ifdef WLAN_DEBUG
@@ -725,8 +702,7 @@ static void lim_print_ht_cap(tpAniSirGlobal mac_ctx, tpPESession session,
if (assoc_req->HTCaps.present) { if (assoc_req->HTCaps.present) {
/* The station *does* support 802.11n HT capability... */ /* The station *does* support 802.11n HT capability... */
lim_log(mac_ctx, LOGD, pe_debug("AdvCodingCap:%d ChaWidthSet:%d PowerSave:%d greenField:%d shortGI20:%d shortGI40:%d txSTBC:%d rxSTBC:%d delayBA:%d maxAMSDUsize:%d DSSS/CCK:%d PSMP:%d stbcCntl:%d lsigTXProt:%d",
FL("AdvCodingCap:%d ChaWidthSet:%d PowerSave:%d greenField:%d shortGI20:%d shortGI40:%d txSTBC:%d rxSTBC:%d delayBA:%d maxAMSDUsize:%d DSSS/CCK:%d PSMP:%d stbcCntl:%d lsigTXProt:%d"),
assoc_req->HTCaps.advCodingCap, assoc_req->HTCaps.advCodingCap,
assoc_req->HTCaps.supportedChannelWidthSet, assoc_req->HTCaps.supportedChannelWidthSet,
assoc_req->HTCaps.mimoPowerSave, assoc_req->HTCaps.mimoPowerSave,
@@ -785,8 +761,7 @@ static bool lim_chk_n_process_wpa_rsn_ie(tpAniSirGlobal mac_ctx,
wps_ie = limGetWscIEPtr(mac_ctx, assoc_req->addIE.addIEdata, wps_ie = limGetWscIEPtr(mac_ctx, assoc_req->addIE.addIEdata,
assoc_req->addIE.length); assoc_req->addIE.length);
else else
lim_log(mac_ctx, LOGD, pe_debug("Assoc req addIEPresent: %d addIE length: %d",
FL("Assoc req addIEPresent = %d addIE length = %d"),
assoc_req->addIEPresent, assoc_req->addIE.length); assoc_req->addIEPresent, assoc_req->addIE.length);
/* when wps_ie is present, RSN/WPA IE is ignored */ /* when wps_ie is present, RSN/WPA IE is ignored */
@@ -795,9 +770,8 @@ static bool lim_chk_n_process_wpa_rsn_ie(tpAniSirGlobal mac_ctx,
if (LIM_IS_AP_ROLE(session) && if (LIM_IS_AP_ROLE(session) &&
session->pLimStartBssReq->privacy && session->pLimStartBssReq->privacy &&
session->pLimStartBssReq->rsnIE.length) { session->pLimStartBssReq->rsnIE.length) {
lim_log(mac_ctx, LOGE, pe_err("RSN enabled auth, Re/Assoc req from STA: "
FL("RSN enabled auth, Re/Assoc req from STA: " MAC_ADDRESS_STR,
MAC_ADDRESS_STR),
MAC_ADDR_ARRAY(hdr->sa)); MAC_ADDR_ARRAY(hdr->sa));
if (assoc_req->rsnPresent) { if (assoc_req->rsnPresent) {
if (assoc_req->rsn.length) { if (assoc_req->rsn.length) {
@@ -821,8 +795,7 @@ static bool lim_chk_n_process_wpa_rsn_ie(tpAniSirGlobal mac_ctx,
assoc_req->HTCaps.present, assoc_req->HTCaps.present,
pmf_connection); pmf_connection);
if (eSIR_SUCCESS != status) { if (eSIR_SUCCESS != status) {
lim_log(mac_ctx, LOGW, pe_warn("Re/Assoc rejected from: " MAC_ADDRESS_STR,
FL("Re/Assoc rejected from: " MAC_ADDRESS_STR),
MAC_ADDR_ARRAY( MAC_ADDR_ARRAY(
hdr->sa)); hdr->sa));
@@ -842,8 +815,7 @@ static bool lim_chk_n_process_wpa_rsn_ie(tpAniSirGlobal mac_ctx,
return false; return false;
} }
} else { } else {
lim_log(mac_ctx, LOGW, pe_warn("Re/Assoc rejected from: " MAC_ADDRESS_STR,
FL("Re/Assoc rejected from: " MAC_ADDRESS_STR),
MAC_ADDR_ARRAY( MAC_ADDR_ARRAY(
hdr->sa)); hdr->sa));
/* /*
@@ -858,9 +830,8 @@ static bool lim_chk_n_process_wpa_rsn_ie(tpAniSirGlobal mac_ctx,
return false; return false;
} }
} else { } else {
lim_log(mac_ctx, LOGW, pe_warn("Re/Assoc rejected from: "
FL("Re/Assoc rejected from: " MAC_ADDRESS_STR,
MAC_ADDRESS_STR),
MAC_ADDR_ARRAY(hdr->sa)); MAC_ADDR_ARRAY(hdr->sa));
/* /*
* rcvd Assoc req frame with RSN IE but * rcvd Assoc req frame with RSN IE but
@@ -890,9 +861,8 @@ static bool lim_chk_n_process_wpa_rsn_ie(tpAniSirGlobal mac_ctx,
session, session,
assoc_req->HTCaps.present); assoc_req->HTCaps.present);
if (eSIR_SUCCESS != status) { if (eSIR_SUCCESS != status) {
lim_log(mac_ctx, LOGW, pe_warn("Re/Assoc rejected from: "
FL("Re/Assoc rejected from: " MAC_ADDRESS_STR,
MAC_ADDRESS_STR),
MAC_ADDR_ARRAY( MAC_ADDR_ARRAY(
hdr->sa)); hdr->sa));
/* /*
@@ -906,9 +876,8 @@ static bool lim_chk_n_process_wpa_rsn_ie(tpAniSirGlobal mac_ctx,
return false; return false;
} }
} else { } else {
lim_log(mac_ctx, LOGW, pe_warn("Re/Assoc rejected from: "
FL("Re/Assoc rejected from: " MAC_ADDRESS_STR,
MAC_ADDRESS_STR),
MAC_ADDR_ARRAY(hdr->sa)); MAC_ADDR_ARRAY(hdr->sa));
/* /*
* rcvd Assoc req frame with invalid WPA * rcvd Assoc req frame with invalid WPA
@@ -928,7 +897,7 @@ static bool lim_chk_n_process_wpa_rsn_ie(tpAniSirGlobal mac_ctx,
*/ */
} /* end of if( ! assoc_req->wscInfo.present ) */ } /* end of if( ! assoc_req->wscInfo.present ) */
else { else {
lim_log(mac_ctx, LOGD, FL("Assoc req WSE IE is present")); pe_debug("Assoc req WSE IE is present");
} }
return true; return true;
} }
@@ -961,7 +930,7 @@ static bool lim_process_assoc_req_no_sta_ctx(tpAniSirGlobal mac_ctx,
* Maximum number of STAs that AP can handle reached. * Maximum number of STAs that AP can handle reached.
* Send Association response to peer MAC entity * Send Association response to peer MAC entity
*/ */
lim_log(mac_ctx, LOGE, FL("Max Sta count reached : %d"), pe_err("Max Sta count reached : %d",
mac_ctx->lim.maxStation); mac_ctx->lim.maxStation);
lim_reject_association(mac_ctx, hdr->sa, sub_type, false, lim_reject_association(mac_ctx, hdr->sa, sub_type, false,
(tAniAuthType) 0, 0, false, (tAniAuthType) 0, 0, false,
@@ -983,9 +952,8 @@ static bool lim_process_assoc_req_no_sta_ctx(tpAniSirGlobal mac_ctx,
eSIR_MAC_STA_NOT_PRE_AUTHENTICATED_REASON, eSIR_MAC_STA_NOT_PRE_AUTHENTICATED_REASON,
hdr->sa, session, false); hdr->sa, session, false);
lim_log(mac_ctx, LOGW, pe_warn("rcvd %s req, sessionid: %d, without pre-auth ctx"
FL("rcvd %s req, sessionid: %d, without pre-auth ctx" MAC_ADDRESS_STR,
MAC_ADDRESS_STR),
(LIM_ASSOC == sub_type) ? "Assoc" : "ReAssoc", (LIM_ASSOC == sub_type) ? "Assoc" : "ReAssoc",
session->peSessionId, MAC_ADDR_ARRAY(hdr->sa)); session->peSessionId, MAC_ADDR_ARRAY(hdr->sa));
return false; return false;
@@ -1032,15 +1000,13 @@ static bool lim_process_assoc_req_sta_ctx(tpAniSirGlobal mac_ctx,
#ifdef WLAN_DEBUG #ifdef WLAN_DEBUG
mac_ctx->lim.gLimNumAssocReqDropInvldState++; mac_ctx->lim.gLimNumAssocReqDropInvldState++;
#endif #endif
lim_log(mac_ctx, LOGD, pe_debug("received Assoc req in state: %X from",
FL("received Assoc req in state %X from "),
sta_ds->mlmStaContext.mlmState); sta_ds->mlmStaContext.mlmState);
} else { } else {
#ifdef WLAN_DEBUG #ifdef WLAN_DEBUG
mac_ctx->lim.gLimNumReassocReqDropInvldState++; mac_ctx->lim.gLimNumReassocReqDropInvldState++;
#endif #endif
lim_log(mac_ctx, LOGD, pe_debug("received ReAssoc req in state: %X from",
FL("received ReAssoc req in state %X from "),
sta_ds->mlmStaContext.mlmState); sta_ds->mlmStaContext.mlmState);
} }
lim_print_mac_addr(mac_ctx, hdr->sa, LOGD); lim_print_mac_addr(mac_ctx, hdr->sa, LOGD);
@@ -1052,9 +1018,8 @@ static bool lim_process_assoc_req_sta_ctx(tpAniSirGlobal mac_ctx,
/* STA sent assoc req frame while already in 'associated' state */ /* STA sent assoc req frame while already in 'associated' state */
#ifdef WLAN_FEATURE_11W #ifdef WLAN_FEATURE_11W
lim_log(mac_ctx, LOGD, pe_debug("Re/Assoc request from station that is already associated");
FL("Re/Assoc request from station that is already associated")); pe_debug("PMF enabled: %d, SA Query state: %d",
lim_log(mac_ctx, LOGD, FL("PMF enabled %d, SA Query state %d"),
sta_ds->rmfEnabled, sta_ds->pmfSaQueryState); sta_ds->rmfEnabled, sta_ds->pmfSaQueryState);
if (sta_ds->rmfEnabled) { if (sta_ds->rmfEnabled) {
switch (sta_ds->pmfSaQueryState) { switch (sta_ds->pmfSaQueryState) {
@@ -1082,8 +1047,7 @@ static bool lim_process_assoc_req_sta_ctx(tpAniSirGlobal mac_ctx,
/* start timer for SA Query retry */ /* start timer for SA Query retry */
if (tx_timer_activate(&sta_ds->pmfSaQueryTimer) if (tx_timer_activate(&sta_ds->pmfSaQueryTimer)
!= TX_SUCCESS) { != TX_SUCCESS) {
lim_log(mac_ctx, LOGE, pe_err("PMF SA Query timer start failed!");
FL("PMF SA Query timer start failed!"));
return false; return false;
} }
sta_ds->pmfSaQueryState = DPH_SA_QUERY_IN_PROGRESS; sta_ds->pmfSaQueryState = DPH_SA_QUERY_IN_PROGRESS;
@@ -1114,8 +1078,7 @@ static bool lim_process_assoc_req_sta_ctx(tpAniSirGlobal mac_ctx,
(!qdf_mem_cmp(&sta_ds->mlmStaContext.capabilityInfo, (!qdf_mem_cmp(&sta_ds->mlmStaContext.capabilityInfo,
&assoc_req->capabilityInfo, &assoc_req->capabilityInfo,
sizeof(tSirMacCapabilityInfo)))) { sizeof(tSirMacCapabilityInfo)))) {
lim_log(mac_ctx, LOGE, pe_err("Received Assoc req in state: %X STAid: %d",
FL(" Received Assoc req in state %X STAid=%d"),
sta_ds->mlmStaContext.mlmState, peer_idx); sta_ds->mlmStaContext.mlmState, peer_idx);
return false; return false;
} else { } else {
@@ -1124,8 +1087,7 @@ static bool lim_process_assoc_req_sta_ctx(tpAniSirGlobal mac_ctx,
* 'associated' state. Update STA capabilities and send * 'associated' state. Update STA capabilities and send
* Association response frame with same AID * Association response frame with same AID
*/ */
lim_log(mac_ctx, LOGD, pe_debug("Rcvd Assoc req from STA already connected");
FL("Rcvd Assoc req from STA already connected"));
sta_ds->mlmStaContext.capabilityInfo = sta_ds->mlmStaContext.capabilityInfo =
assoc_req->capabilityInfo; assoc_req->capabilityInfo;
if (sta_pre_auth_ctx && (sta_pre_auth_ctx->mlmState == if (sta_pre_auth_ctx && (sta_pre_auth_ctx->mlmState ==
@@ -1140,8 +1102,7 @@ static bool lim_process_assoc_req_sta_ctx(tpAniSirGlobal mac_ctx,
*update_ctx = true; *update_ctx = true;
if (dph_init_sta_state(mac_ctx, hdr->sa, peer_idx, true, if (dph_init_sta_state(mac_ctx, hdr->sa, peer_idx, true,
&session->dph.dphHashTable) == NULL) { &session->dph.dphHashTable) == NULL) {
lim_log(mac_ctx, LOGE, pe_err("could not Init STAid: %d", peer_idx);
FL("could not Init STAid=%d"), peer_idx);
return false; return false;
} }
} }
@@ -1179,8 +1140,7 @@ static bool lim_chk_wmm(tpAniSirGlobal mac_ctx, tpSirMacMgmtHdr hdr,
&(assoc_req->qosCapability), &(assoc_req->qosCapability),
0, false, NULL, &tspecIdx, session) != 0, false, NULL, &tspecIdx, session) !=
eSIR_SUCCESS) { eSIR_SUCCESS) {
lim_log(mac_ctx, LOGW, pe_warn("AdmitControl: TSPEC rejected");
FL("AdmitControl: TSPEC rejected"));
lim_send_assoc_rsp_mgmt_frame(mac_ctx, lim_send_assoc_rsp_mgmt_frame(mac_ctx,
eSIR_MAC_QAP_NO_BANDWIDTH_REASON, eSIR_MAC_QAP_NO_BANDWIDTH_REASON,
1, hdr->sa, sub_type, 0, session); 1, hdr->sa, sub_type, 0, session);
@@ -1191,8 +1151,7 @@ static bool lim_chk_wmm(tpAniSirGlobal mac_ctx, tpSirMacMgmtHdr hdr,
} }
} else if (lim_admit_control_add_sta(mac_ctx, hdr->sa, false) } else if (lim_admit_control_add_sta(mac_ctx, hdr->sa, false)
!= eSIR_SUCCESS) { != eSIR_SUCCESS) {
lim_log(mac_ctx, LOGW, pe_warn("AdmitControl: Sta rejected");
FL("AdmitControl: Sta rejected"));
lim_send_assoc_rsp_mgmt_frame(mac_ctx, lim_send_assoc_rsp_mgmt_frame(mac_ctx,
eSIR_MAC_QAP_NO_BANDWIDTH_REASON, 1, eSIR_MAC_QAP_NO_BANDWIDTH_REASON, 1,
hdr->sa, sub_type, 0, session); hdr->sa, sub_type, 0, session);
@@ -1202,7 +1161,7 @@ static bool lim_chk_wmm(tpAniSirGlobal mac_ctx, tpSirMacMgmtHdr hdr,
return false; return false;
} }
/* else all ok */ /* else all ok */
lim_log(mac_ctx, LOGD, FL("AdmitControl: Sta OK!")); pe_debug("AdmitControl: Sta OK!");
} }
return true; return true;
} }
@@ -1428,9 +1387,8 @@ static bool lim_update_sta_ds(tpAniSirGlobal mac_ctx, tpSirMacMgmtHdr hdr,
&assoc_req->he_cap) != eSIR_SUCCESS) &assoc_req->he_cap) != eSIR_SUCCESS)
{ {
/* Could not update hash table entry at DPH with rateset */ /* Could not update hash table entry at DPH with rateset */
lim_log(mac_ctx, LOGE, pe_err("Couldn't update hash entry for aid: %d MacAddr: "
FL("Couldn't update hash entry for aid=%d, MacAddr: " MAC_ADDRESS_STR,
MAC_ADDRESS_STR),
peer_idx, MAC_ADDR_ARRAY(hdr->sa)); peer_idx, MAC_ADDR_ARRAY(hdr->sa));
/* Release AID */ /* Release AID */
@@ -1440,11 +1398,10 @@ static bool lim_update_sta_ds(tpAniSirGlobal mac_ctx, tpSirMacMgmtHdr hdr,
sub_type, true, auth_type, peer_idx, false, sub_type, true, auth_type, peer_idx, false,
(tSirResultCodes)eSIR_MAC_UNSPEC_FAILURE_STATUS, (tSirResultCodes)eSIR_MAC_UNSPEC_FAILURE_STATUS,
session); session);
lim_log(mac_ctx, LOGE, pe_err("Delete dph hash entry");
FL(" Delete dph hash entry"));
if (dph_delete_hash_entry(mac_ctx, hdr->sa, sta_ds->assocId, if (dph_delete_hash_entry(mac_ctx, hdr->sa, sta_ds->assocId,
&session->dph.dphHashTable) != eSIR_SUCCESS) &session->dph.dphHashTable) != eSIR_SUCCESS)
lim_log(mac_ctx, LOGE, FL("error deleting hash entry")); pe_err("error deleting hash entry");
return false; return false;
} }
if (assoc_req->operMode.present) { if (assoc_req->operMode.present) {
@@ -1487,8 +1444,7 @@ static bool lim_update_sta_ds(tpAniSirGlobal mac_ctx, tpSirMacMgmtHdr hdr,
* Rcvd Re/Assoc Req from STA when UPASD is * Rcvd Re/Assoc Req from STA when UPASD is
* not supported. * not supported.
*/ */
lim_log(mac_ctx, LOGE, pe_err("UAPSD not supported, reply accordingly");
FL("UAPSD not supported, reply accordingly"));
/* update UAPSD and send it to LIM to add STA */ /* update UAPSD and send it to LIM to add STA */
sta_ds->qos.capability.qosInfo.acbe_uapsd = 0; sta_ds->qos.capability.qosInfo.acbe_uapsd = 0;
sta_ds->qos.capability.qosInfo.acbk_uapsd = 0; sta_ds->qos.capability.qosInfo.acbk_uapsd = 0;
@@ -1522,8 +1478,7 @@ static bool lim_update_sta_ds(tpAniSirGlobal mac_ctx, tpSirMacMgmtHdr hdr,
timer_id.fields.peerIdx = peer_idx; timer_id.fields.peerIdx = peer_idx;
if (wlan_cfg_get_int(mac_ctx, WNI_CFG_PMF_SA_QUERY_RETRY_INTERVAL, if (wlan_cfg_get_int(mac_ctx, WNI_CFG_PMF_SA_QUERY_RETRY_INTERVAL,
&retry_interval) != eSIR_SUCCESS) { &retry_interval) != eSIR_SUCCESS) {
lim_log(mac_ctx, LOGE, pe_err("Couldn't get PMF SA Query retry interval value");
FL("Couldn't get PMF SA Query retry interval value"));
lim_reject_association(mac_ctx, hdr->sa, sub_type, true, lim_reject_association(mac_ctx, hdr->sa, sub_type, true,
auth_type, peer_idx, false, auth_type, peer_idx, false,
(tSirResultCodes) eSIR_MAC_UNSPEC_FAILURE_STATUS, (tSirResultCodes) eSIR_MAC_UNSPEC_FAILURE_STATUS,
@@ -1538,8 +1493,7 @@ static bool lim_update_sta_ds(tpAniSirGlobal mac_ctx, tpSirMacMgmtHdr hdr,
timer_id.value, timer_id.value,
SYS_MS_TO_TICKS((retry_interval * 1024) / 1000), SYS_MS_TO_TICKS((retry_interval * 1024) / 1000),
0, TX_NO_ACTIVATE) != TX_SUCCESS) { 0, TX_NO_ACTIVATE) != TX_SUCCESS) {
lim_log(mac_ctx, LOGE, pe_err("could not create PMF SA Query timer");
FL("could not create PMF SA Query timer"));
lim_reject_association(mac_ctx, hdr->sa, sub_type, lim_reject_association(mac_ctx, hdr->sa, sub_type,
true, auth_type, peer_idx, false, true, auth_type, peer_idx, false,
(tSirResultCodes)eSIR_MAC_UNSPEC_FAILURE_STATUS, (tSirResultCodes)eSIR_MAC_UNSPEC_FAILURE_STATUS,
@@ -1553,7 +1507,7 @@ static bool lim_update_sta_ds(tpAniSirGlobal mac_ctx, tpSirMacMgmtHdr hdr,
(struct s_ext_cap *) assoc_req->ExtCap.bytes, mac_ctx); (struct s_ext_cap *) assoc_req->ExtCap.bytes, mac_ctx);
} else { } else {
sta_ds->timingMeasCap = 0; sta_ds->timingMeasCap = 0;
lim_log(mac_ctx, LOGD, FL("ExtCap not present")); pe_debug("ExtCap not present");
} }
return true; return true;
} }
@@ -1594,8 +1548,7 @@ static bool lim_update_sta_ctx(tpAniSirGlobal mac_ctx, tpPESession session,
*/ */
if (lim_add_sta(mac_ctx, sta_ds, false, session) != if (lim_add_sta(mac_ctx, sta_ds, false, session) !=
eSIR_SUCCESS) { eSIR_SUCCESS) {
lim_log(mac_ctx, LOGE, pe_err("could not Add STA with assocId: %d",
FL("could not Add STA with assocId=%d"),
sta_ds->assocId); sta_ds->assocId);
lim_reject_association(mac_ctx, sta_ds->staAddr, lim_reject_association(mac_ctx, sta_ds->staAddr,
sta_ds->mlmStaContext.subType, true, sta_ds->mlmStaContext.subType, true,
@@ -1626,8 +1579,7 @@ static bool lim_update_sta_ctx(tpAniSirGlobal mac_ctx, tpPESession session,
eLIM_MLM_WT_ASSOC_DEL_STA_RSP_STATE; eLIM_MLM_WT_ASSOC_DEL_STA_RSP_STATE;
if (lim_del_sta(mac_ctx, sta_ds, true, session) if (lim_del_sta(mac_ctx, sta_ds, true, session)
!= eSIR_SUCCESS) { != eSIR_SUCCESS) {
lim_log(mac_ctx, LOGE, pe_err("Couldn't DEL STA, assocId: %d staId: %d",
FL("Couldn't DEL STA, assocId=%d staId %d"),
sta_ds->assocId, sta_ds->staIndex); sta_ds->assocId, sta_ds->staIndex);
lim_reject_association(mac_ctx, sta_ds->staAddr, lim_reject_association(mac_ctx, sta_ds->staAddr,
sta_ds->mlmStaContext.subType, true, sta_ds->mlmStaContext.subType, true,
@@ -1651,8 +1603,7 @@ static bool lim_update_sta_ctx(tpAniSirGlobal mac_ctx, tpPESession session,
*/ */
if (lim_add_sta(mac_ctx, sta_ds, false, session) if (lim_add_sta(mac_ctx, sta_ds, false, session)
!= eSIR_SUCCESS) { != eSIR_SUCCESS) {
lim_log(mac_ctx, LOGE, pe_err("UPASD not supported, REASSOC Failed");
FL("UPASD not supported, REASSOC Failed"));
lim_reject_association(mac_ctx, sta_ds->staAddr, lim_reject_association(mac_ctx, sta_ds->staAddr,
sta_ds->mlmStaContext.subType, true, sta_ds->mlmStaContext.subType, true,
sta_ds->mlmStaContext.authType, sta_ds->mlmStaContext.authType,
@@ -1764,17 +1715,15 @@ void lim_process_assoc_req_frame(tpAniSirGlobal mac_ctx, uint8_t *rx_pkt_info,
hdr = WMA_GET_RX_MAC_HEADER(rx_pkt_info); hdr = WMA_GET_RX_MAC_HEADER(rx_pkt_info);
frame_len = WMA_GET_RX_PAYLOAD_LEN(rx_pkt_info); frame_len = WMA_GET_RX_PAYLOAD_LEN(rx_pkt_info);
lim_log(mac_ctx, LOGD, pe_debug("Rcvd: %s Req Frame sessionid: %d systemrole: %d MlmState: %d from: "
FL("Rcvd %s Req Frame, sessionid: %d systemrole %d MlmState %d from: " MAC_ADDRESS_STR,
MAC_ADDRESS_STR),
(LIM_ASSOC == sub_type) ? "Assoc" : "ReAssoc", (LIM_ASSOC == sub_type) ? "Assoc" : "ReAssoc",
session->peSessionId, GET_LIM_SYSTEM_ROLE(session), session->peSessionId, GET_LIM_SYSTEM_ROLE(session),
session->limMlmState, MAC_ADDR_ARRAY(hdr->sa)); session->limMlmState, MAC_ADDR_ARRAY(hdr->sa));
if (LIM_IS_STA_ROLE(session)) { if (LIM_IS_STA_ROLE(session)) {
lim_log(mac_ctx, LOGE, pe_err("Rcvd unexpected ASSOC REQ, sessionid: %d sys sub_type: %d for role: %d from: "
FL("Rcvd unexpected ASSOC REQ, sessionid: %d sys sub_type=%d for role=%d from: " MAC_ADDRESS_STR,
MAC_ADDRESS_STR),
session->peSessionId, sub_type, session->peSessionId, sub_type,
GET_LIM_SYSTEM_ROLE(session), GET_LIM_SYSTEM_ROLE(session),
MAC_ADDR_ARRAY(hdr->sa)); MAC_ADDR_ARRAY(hdr->sa));
@@ -1784,8 +1733,8 @@ void lim_process_assoc_req_frame(tpAniSirGlobal mac_ctx, uint8_t *rx_pkt_info,
return; return;
} }
if (session->limMlmState == eLIM_MLM_WT_DEL_BSS_RSP_STATE) { if (session->limMlmState == eLIM_MLM_WT_DEL_BSS_RSP_STATE) {
lim_log(mac_ctx, LOGE, FL("drop ASSOC REQ on sessionid: %d " pe_err("drop ASSOC REQ on sessionid: %d "
"role=%d from: "MAC_ADDRESS_STR" in limMlmState %d"), "role: %d from: "MAC_ADDRESS_STR" in limMlmState: %d",
session->peSessionId, session->peSessionId,
GET_LIM_SYSTEM_ROLE(session), GET_LIM_SYSTEM_ROLE(session),
MAC_ADDR_ARRAY(hdr->sa), MAC_ADDR_ARRAY(hdr->sa),
@@ -1804,9 +1753,8 @@ void lim_process_assoc_req_frame(tpAniSirGlobal mac_ctx, uint8_t *rx_pkt_info,
&session->dph.dphHashTable); &session->dph.dphHashTable);
if (NULL != sta_ds) { if (NULL != sta_ds) {
if (hdr->fc.retry > 0) { if (hdr->fc.retry > 0) {
lim_log(mac_ctx, LOGE, pe_err("STA is initiating Assoc Req after ACK lost. Do not process sessionid: %d sys sub_type=%d for role=%d from: "
FL("STA is initiating Assoc Req after ACK lost. Do not process sessionid: %d sys sub_type=%d for role=%d from: " MAC_ADDRESS_STR, session->peSessionId,
MAC_ADDRESS_STR), session->peSessionId,
sub_type, GET_LIM_SYSTEM_ROLE(session), sub_type, GET_LIM_SYSTEM_ROLE(session),
MAC_ADDR_ARRAY(hdr->sa)); MAC_ADDR_ARRAY(hdr->sa));
return; return;
@@ -1820,9 +1768,8 @@ void lim_process_assoc_req_frame(tpAniSirGlobal mac_ctx, uint8_t *rx_pkt_info,
sta_ds->assocId, sta_ds->staAddr, sta_ds->assocId, sta_ds->staAddr,
sta_ds->mlmStaContext.subType, sta_ds->mlmStaContext.subType,
sta_ds, session); sta_ds, session);
lim_log(mac_ctx, LOGE, pe_err("DUT already received an assoc request frame and STA is sending another assoc req.So, do not Process sessionid: %d sys sub_type: %d for role: %d from: "
FL("DUT already received an assoc request frame and STA is sending another assoc req.So, do not Process sessionid: %d sys sub_type=%d for role=%d from: " MAC_ADDRESS_STR,
MAC_ADDRESS_STR),
session->peSessionId, sub_type, session->peSessionId, sub_type,
session->limSystemRole, session->limSystemRole,
MAC_ADDR_ARRAY(hdr->sa)); MAC_ADDR_ARRAY(hdr->sa));
@@ -1841,9 +1788,8 @@ void lim_process_assoc_req_frame(tpAniSirGlobal mac_ctx, uint8_t *rx_pkt_info,
* Rcvd Re/Assoc Req frame from BC/MC address Log error and * Rcvd Re/Assoc Req frame from BC/MC address Log error and
* ignore it * ignore it
*/ */
lim_log(mac_ctx, LOGE, pe_err("Rcvd: %s Req, sessionid: %d from a BC/MC address"
FL("Rcvd %s Req, sessionid: %d from a BC/MC address" MAC_ADDRESS_STR,
MAC_ADDRESS_STR),
(LIM_ASSOC == sub_type) ? "Assoc" : "ReAssoc", (LIM_ASSOC == sub_type) ? "Assoc" : "ReAssoc",
session->peSessionId, MAC_ADDR_ARRAY(hdr->sa)); session->peSessionId, MAC_ADDR_ARRAY(hdr->sa));
return; return;
@@ -1865,8 +1811,7 @@ void lim_process_assoc_req_frame(tpAniSirGlobal mac_ctx, uint8_t *rx_pkt_info,
if (!cfg_get_vendor_ie_ptr_from_oui(mac_ctx, if (!cfg_get_vendor_ie_ptr_from_oui(mac_ctx,
&session->access_policy_vendor_ie[2], &session->access_policy_vendor_ie[2],
3, frm_body + LIM_ASSOC_REQ_IE_OFFSET, frame_len)) { 3, frm_body + LIM_ASSOC_REQ_IE_OFFSET, frame_len)) {
lim_log(mac_ctx, LOGE, pe_err("Vendor ie not present and access policy is %x, Rejected association",
FL("Vendor ie not present and access policy is %x, Rejected association"),
session->access_policy); session->access_policy);
lim_send_assoc_rsp_mgmt_frame(mac_ctx, lim_send_assoc_rsp_mgmt_frame(mac_ctx,
eSIR_MAC_UNSPEC_FAILURE_STATUS, 1, hdr->sa, eSIR_MAC_UNSPEC_FAILURE_STATUS, 1, hdr->sa,
@@ -1877,8 +1822,7 @@ void lim_process_assoc_req_frame(tpAniSirGlobal mac_ctx, uint8_t *rx_pkt_info,
/* Allocate memory for the Assoc Request frame */ /* Allocate memory for the Assoc Request frame */
assoc_req = qdf_mem_malloc(sizeof(*assoc_req)); assoc_req = qdf_mem_malloc(sizeof(*assoc_req));
if (NULL == assoc_req) { if (NULL == assoc_req) {
lim_log(mac_ctx, LOGE, pe_err("Allocate Memory failed in assoc_req");
FL("Allocate Memory failed in assoc_req"));
return; return;
} }
@@ -1889,8 +1833,7 @@ void lim_process_assoc_req_frame(tpAniSirGlobal mac_ctx, uint8_t *rx_pkt_info,
assoc_req->assocReqFrame = qdf_mem_malloc(frame_len); assoc_req->assocReqFrame = qdf_mem_malloc(frame_len);
if (NULL == assoc_req->assocReqFrame) { if (NULL == assoc_req->assocReqFrame) {
lim_log(mac_ctx, LOGE, pe_err("Memory alloc failed for the assoc req, len: %d",
FL("Memory alloc failed for the assoc req, len=%d"),
frame_len); frame_len);
goto error; goto error;
} }
@@ -1970,8 +1913,7 @@ void lim_process_assoc_req_frame(tpAniSirGlobal mac_ctx, uint8_t *rx_pkt_info,
goto error; goto error;
/* STA is Associated ! */ /* STA is Associated ! */
lim_log(mac_ctx, LOGE, pe_err("Received: %s Req successful from " MAC_ADDRESS_STR,
FL("Received %s Req successful from " MAC_ADDRESS_STR),
(LIM_ASSOC == sub_type) ? "Assoc" : "ReAssoc", (LIM_ASSOC == sub_type) ? "Assoc" : "ReAssoc",
MAC_ADDR_ARRAY(hdr->sa)); MAC_ADDR_ARRAY(hdr->sa));
@@ -1986,8 +1928,7 @@ void lim_process_assoc_req_frame(tpAniSirGlobal mac_ctx, uint8_t *rx_pkt_info,
if (!peer_idx) { if (!peer_idx) {
/* Could not assign AID. Reject association */ /* Could not assign AID. Reject association */
lim_log(mac_ctx, LOGE, pe_err("PeerIdx not avaialble. Reject associaton");
FL("PeerIdx not avaialble. Reject associaton"));
lim_reject_association(mac_ctx, hdr->sa, sub_type, lim_reject_association(mac_ctx, hdr->sa, sub_type,
true, auth_type, peer_idx, false, true, auth_type, peer_idx, false,
(tSirResultCodes)eSIR_MAC_UNSPEC_FAILURE_STATUS, (tSirResultCodes)eSIR_MAC_UNSPEC_FAILURE_STATUS,
@@ -2002,9 +1943,8 @@ void lim_process_assoc_req_frame(tpAniSirGlobal mac_ctx, uint8_t *rx_pkt_info,
if (sta_ds == NULL) { if (sta_ds == NULL) {
/* Could not add hash table entry at DPH */ /* Could not add hash table entry at DPH */
lim_log(mac_ctx, LOGE, pe_err("couldn't add hash entry at DPH for aid: %d MacAddr:"
FL("couldn't add hash entry at DPH for aid=%d, MacAddr:" MAC_ADDRESS_STR, peer_idx, MAC_ADDR_ARRAY(hdr->sa));
MAC_ADDRESS_STR), peer_idx, MAC_ADDR_ARRAY(hdr->sa));
/* Release AID */ /* Release AID */
lim_release_peer_idx(mac_ctx, peer_idx, session); lim_release_peer_idx(mac_ctx, peer_idx, session);
@@ -2074,8 +2014,7 @@ static void lim_fill_assoc_ind_wapi_info(tpAniSirGlobal mac_ctx,
uint8_t *wpsie) uint8_t *wpsie)
{ {
if (assoc_req->wapiPresent && (NULL == wpsie)) { if (assoc_req->wapiPresent && (NULL == wpsie)) {
lim_log(mac_ctx, LOGD, pe_debug("Received WAPI IE length in Assoc Req is %d",
FL("Received WAPI IE length in Assoc Req is %d"),
assoc_req->wapi.length); assoc_req->wapi.length);
assoc_ind->wapiIE.wapiIEdata[0] = SIR_MAC_WAPI_EID; assoc_ind->wapiIE.wapiIEdata[0] = SIR_MAC_WAPI_EID;
assoc_ind->wapiIE.wapiIEdata[1] = assoc_req->wapi.length; assoc_ind->wapiIE.wapiIEdata[1] = assoc_req->wapi.length;
@@ -2198,9 +2137,8 @@ void lim_send_mlm_assoc_ind(tpAniSirGlobal mac_ctx,
else else
sub_type = LIM_ASSOC; sub_type = LIM_ASSOC;
lim_log(mac_ctx, LOGD, pe_debug("Sessionid: %d ssid: %s sub_type: %d Associd: %d staAddr: "
FL("Sessionid %d ssid %s sub_type %d Associd %d staAddr " MAC_ADDRESS_STR, session_entry->peSessionId,
MAC_ADDRESS_STR), session_entry->peSessionId,
assoc_req->ssId.ssId, sub_type, sta_ds->assocId, assoc_req->ssId.ssId, sub_type, sta_ds->assocId,
MAC_ADDR_ARRAY(sta_ds->staAddr)); MAC_ADDR_ARRAY(sta_ds->staAddr));
@@ -2211,8 +2149,7 @@ void lim_send_mlm_assoc_ind(tpAniSirGlobal mac_ctx,
if (NULL == assoc_ind) { if (NULL == assoc_ind) {
lim_release_peer_idx(mac_ctx, sta_ds->assocId, lim_release_peer_idx(mac_ctx, sta_ds->assocId,
session_entry); session_entry);
lim_log(mac_ctx, LOGE, pe_err("AllocateMemory failed for assoc_ind");
FL("AllocateMemory failed for assoc_ind"));
return; return;
} }
qdf_mem_copy((uint8_t *) assoc_ind->peerMacAddr, qdf_mem_copy((uint8_t *) assoc_ind->peerMacAddr,
@@ -2234,7 +2171,7 @@ void lim_send_mlm_assoc_ind(tpAniSirGlobal mac_ctx,
assoc_req->addIE.length); assoc_req->addIE.length);
} }
if (assoc_req->rsnPresent && (NULL == wpsie)) { if (assoc_req->rsnPresent && (NULL == wpsie)) {
lim_log(mac_ctx, LOGD, FL("Assoc Req RSN IE len = %d"), pe_debug("Assoc Req RSN IE len: %d",
assoc_req->rsn.length); assoc_req->rsn.length);
assoc_ind->rsnIE.length = 2 + assoc_req->rsn.length; assoc_ind->rsnIE.length = 2 + assoc_req->rsn.length;
assoc_ind->rsnIE.rsnIEdata[0] = SIR_MAC_RSN_EID; assoc_ind->rsnIE.rsnIEdata[0] = SIR_MAC_RSN_EID;
@@ -2263,8 +2200,7 @@ void lim_send_mlm_assoc_ind(tpAniSirGlobal mac_ctx,
rsn_len = assoc_ind->rsnIE.length; rsn_len = assoc_ind->rsnIE.length;
if ((rsn_len + assoc_req->wpa.length) if ((rsn_len + assoc_req->wpa.length)
>= SIR_MAC_MAX_IE_LENGTH) { >= SIR_MAC_MAX_IE_LENGTH) {
lim_log(mac_ctx, LOGE, pe_err("rsnIEdata index out of bounds: %d",
FL("rsnIEdata index out of bounds %d"),
rsn_len); rsn_len);
qdf_mem_free(assoc_ind); qdf_mem_free(assoc_ind);
return; return;
@@ -2309,8 +2245,7 @@ void lim_send_mlm_assoc_ind(tpAniSirGlobal mac_ctx,
assoc_ind->addIE.length += assoc_ind->addIE.length +=
2 + DOT11F_IE_HTCAPS_MIN_LEN; 2 + DOT11F_IE_HTCAPS_MIN_LEN;
} else { } else {
lim_log(mac_ctx, LOGE, pe_err("Fail:HT capabilities IE to addIE");
FL("Fail:HT capabilities IE to addIE"));
} }
} }
@@ -2318,8 +2253,7 @@ void lim_send_mlm_assoc_ind(tpAniSirGlobal mac_ctx,
if (wlan_cfg_get_int (mac_ctx, if (wlan_cfg_get_int (mac_ctx,
(uint16_t) WNI_CFG_WME_ENABLED, &tmp) (uint16_t) WNI_CFG_WME_ENABLED, &tmp)
!= eSIR_SUCCESS) != eSIR_SUCCESS)
lim_log(mac_ctx, LOGE, pe_err("wlan_cfg_get_int failed for id: %d",
FL("wlan_cfg_get_int failed for id %d"),
WNI_CFG_WME_ENABLED); WNI_CFG_WME_ENABLED);
/* check whether AP is enabled with WMM */ /* check whether AP is enabled with WMM */