From 86afc8fbc4f8af9fd7a5187a515c63213f2d9e5b Mon Sep 17 00:00:00 2001 From: Abhinav Kumar Date: Mon, 24 Feb 2020 14:39:57 +0530 Subject: [PATCH] qcacld-3.0: Optimize logs after connect complete Optimize logs after connect complete i.e roam offload params and tdls state etc. Change-Id: I5df7eb236ef1c7369f4d996c4f0eda7225652f12 CRs-Fixed: 2627694 --- components/mlme/core/src/wlan_mlme_main.c | 6 +- components/tdls/core/src/wlan_tdls_main.c | 38 ------- core/mac/src/pe/lim/lim_process_fils.c | 13 ++- core/sme/src/common/sme_api.c | 10 +- core/sme/src/csr/csr_api_roam.c | 116 ++-------------------- core/sme/src/csr/csr_api_scan.c | 27 ++++- core/sme/src/csr/csr_neighbor_roam.c | 13 +-- core/wma/src/wma_scan_roam.c | 114 ++++++++++----------- core/wma/src/wma_utils.c | 7 +- 9 files changed, 101 insertions(+), 243 deletions(-) diff --git a/components/mlme/core/src/wlan_mlme_main.c b/components/mlme/core/src/wlan_mlme_main.c index c3e8cfdae21c..e67b29588ee5 100644 --- a/components/mlme/core/src/wlan_mlme_main.c +++ b/components/mlme/core/src/wlan_mlme_main.c @@ -2667,9 +2667,9 @@ static void mlme_print_roaming_state(uint8_t vdev_id, enum roam_offload_state cur_state, enum roam_offload_state new_state) { - mlme_debug("ROAM: vdev[%d] ROAM State Changed from [%s] to [%s]", - vdev_id, mlme_roam_state_to_string(cur_state), - mlme_roam_state_to_string(new_state)); + mlme_debug("ROAM: vdev %d: %s(%d) --> %s(%d)", + vdev_id, mlme_roam_state_to_string(cur_state), cur_state, + mlme_roam_state_to_string(new_state), new_state); /* TODO: Try to print the state change requestor also */ } diff --git a/components/tdls/core/src/wlan_tdls_main.c b/components/tdls/core/src/wlan_tdls_main.c index 5dacf15cc769..8596fabd1a5b 100644 --- a/components/tdls/core/src/wlan_tdls_main.c +++ b/components/tdls/core/src/wlan_tdls_main.c @@ -793,37 +793,6 @@ QDF_STATUS tdls_get_vdev_objects(struct wlan_objmgr_vdev *vdev, return QDF_STATUS_SUCCESS; } -/** - * tdls_state_param_setting_dump() - print tdls state & parameters to send to fw - * @info: tdls setting to be sent to fw - * - * Return: void - */ -static void tdls_state_param_setting_dump(struct tdls_info *info) -{ - if (!info) - return; - - tdls_debug("Setting tdls state and param in fw: vdev_id: %d, tdls_state: %d, notification_interval_ms: %d, tx_discovery_threshold: %d, tx_teardown_threshold: %d, rssi_teardown_threshold: %d, rssi_delta: %d, tdls_options: 0x%x, peer_traffic_ind_window: %d, peer_traffic_response_timeout: %d, puapsd_mask: 0x%x, puapsd_inactivity_time: %d, puapsd_rx_frame_threshold: %d, teardown_notification_ms: %d, tdls_peer_kickout_threshold: %d, tdls_discovery_wake_timeout: %d", - info->vdev_id, - info->tdls_state, - info->notification_interval_ms, - info->tx_discovery_threshold, - info->tx_teardown_threshold, - info->rssi_teardown_threshold, - info->rssi_delta, - info->tdls_options, - info->peer_traffic_ind_window, - info->peer_traffic_response_timeout, - info->puapsd_mask, - info->puapsd_inactivity_time, - info->puapsd_rx_frame_threshold, - info->teardown_notification_ms, - info->tdls_peer_kickout_threshold, - info->tdls_discovery_wake_timeout); - -} - QDF_STATUS tdls_set_offchan_mode(struct wlan_objmgr_psoc *psoc, struct tdls_channel_switch_params *param) { @@ -1120,7 +1089,6 @@ void tdls_send_update_to_fw(struct tdls_vdev_priv_obj *tdls_vdev_obj, QDF_STATUS status; uint8_t set_state_cnt; - tdls_debug("Enter"); tdls_feature_flags = tdls_soc_obj->tdls_configs.tdls_feature_flags; if (!TDLS_IS_ENABLED(tdls_feature_flags)) { tdls_debug("TDLS mode is not enabled"); @@ -1140,8 +1108,6 @@ void tdls_send_update_to_fw(struct tdls_vdev_priv_obj *tdls_vdev_obj, tdls_soc_obj->tdls_current_mode = TDLS_SUPPORT_DISABLED; } else { - tdls_debug("TDLS feature flags from ini %d ", - tdls_feature_flags); if (!TDLS_IS_IMPLICIT_TRIG_ENABLED(tdls_feature_flags)) tdls_soc_obj->tdls_current_mode = TDLS_SUPPORT_EXP_TRIG_ONLY; @@ -1214,8 +1180,6 @@ void tdls_send_update_to_fw(struct tdls_vdev_priv_obj *tdls_vdev_obj, tdls_info_to_fw->tdls_discovery_wake_timeout = tdls_soc_obj->tdls_configs.tdls_discovery_wake_timeout; - tdls_state_param_setting_dump(tdls_info_to_fw); - status = tdls_update_fw_tdls_state(tdls_soc_obj, tdls_info_to_fw); if (QDF_STATUS_SUCCESS != status) goto done; @@ -1246,8 +1210,6 @@ tdls_process_sta_connect(struct tdls_sta_notify_params *notify) return QDF_STATUS_E_INVAL; - tdls_debug("Check and update TDLS state"); - if (policy_mgr_get_connection_count(tdls_soc_obj->soc) > 1) { tdls_debug("Concurrent sessions exist, TDLS can't be enabled"); return QDF_STATUS_SUCCESS; diff --git a/core/mac/src/pe/lim/lim_process_fils.c b/core/mac/src/pe/lim/lim_process_fils.c index e73823de47c3..0c4f26940a7b 100644 --- a/core/mac/src/pe/lim/lim_process_fils.c +++ b/core/mac/src/pe/lim/lim_process_fils.c @@ -2255,9 +2255,10 @@ void lim_update_fils_rik(struct pe_session *pe_session, if ((!lim_is_fils_connection(pe_session) || !pe_fils_info) && (req_buffer->is_fils_connection)) { if (roam_fils_params->rrk_length > FILS_MAX_RRK_LENGTH) { - pe_debug("FILS rrk len(%d) max (%d)", - roam_fils_params->rrk_length, - FILS_MAX_RRK_LENGTH); + if (lim_is_fils_connection(pe_session)) + pe_debug("FILS rrk len(%d) max (%d)", + roam_fils_params->rrk_length, + FILS_MAX_RRK_LENGTH); return; } @@ -2276,8 +2277,10 @@ void lim_update_fils_rik(struct pe_session *pe_session, } if ((pe_fils_info->fils_rik_len > FILS_MAX_RIK_LENGTH) || !pe_fils_info->fils_rik) { - pe_debug("Fils rik len(%d) max %d", pe_fils_info->fils_rik_len, - FILS_MAX_RIK_LENGTH); + if (pe_fils_info->fils_rik) + pe_debug("Fils rik len(%d) max %d", + pe_fils_info->fils_rik_len, + FILS_MAX_RIK_LENGTH); return; } diff --git a/core/sme/src/common/sme_api.c b/core/sme/src/common/sme_api.c index 0935a413787c..9815d106220a 100644 --- a/core/sme/src/common/sme_api.c +++ b/core/sme/src/common/sme_api.c @@ -6137,16 +6137,12 @@ void sme_free_join_rsp_fils_params(struct csr_roam_info *roam_info) { struct fils_join_rsp_params *roam_fils_params; - if (!roam_info) { - sme_debug("FILS Roam Info NULL"); + if (!roam_info) return; - } roam_fils_params = roam_info->fils_join_rsp; - if (!roam_fils_params) { - sme_debug("FILS Roam Param NULL"); + if (!roam_fils_params) return; - } if (roam_fils_params->fils_pmk) qdf_mem_free(roam_fils_params->fils_pmk); @@ -7393,7 +7389,7 @@ void sme_dump_freq_list(tCsrChannelInfo *chan_info) } } - sme_debug("No.of frequencies: %u, frequency list: %s", i, channel_list); + sme_debug("frequency list [%u]: %s", i, channel_list); qdf_mem_free(channel_list); } diff --git a/core/sme/src/csr/csr_api_roam.c b/core/sme/src/csr/csr_api_roam.c index 863272bc0e66..2d51b99f9e2e 100644 --- a/core/sme/src/csr/csr_api_roam.c +++ b/core/sme/src/csr/csr_api_roam.c @@ -2186,11 +2186,8 @@ is_dfs_unsafe_extra_band_chan(struct mac_context *mac_ctx, uint32_t freq, ROAMING_DFS_CHANNEL_DISABLED || mac_ctx->roam.configParam.sta_roam_policy.dfs_mode == CSR_STA_ROAM_POLICY_DFS_DISABLED) && - (wlan_reg_is_dfs_for_freq(mac_ctx->pdev, freq))) { - QDF_TRACE(QDF_MODULE_ID_SME, QDF_TRACE_LEVEL_DEBUG, - ("dfs freq %d"), freq); + (wlan_reg_is_dfs_for_freq(mac_ctx->pdev, freq))) return true; - } pld_get_wlan_unsafe_channel(qdf_ctx->dev, unsafe_chan, &unsafe_chan_cnt, @@ -2209,7 +2206,6 @@ is_dfs_unsafe_extra_band_chan(struct mac_context *mac_ctx, uint32_t freq, } } } - sme_debug("band %d", band); if (!csr_check_band_freq_match(band, freq)) { QDF_TRACE(QDF_MODULE_ID_SME, QDF_TRACE_LEVEL_DEBUG, ("ignoring non-intra band freq %d"), @@ -17633,10 +17629,6 @@ csr_fetch_ch_lst_from_occupied_lst(struct mac_context *mac_ctx, ch_lst = mac_ctx->scan.occupiedChannels[session_id].channel_freq_list; op_freq = session->connectedProfile.op_freq; - QDF_TRACE(QDF_MODULE_ID_SME, QDF_TRACE_LEVEL_DEBUG, - "Num of channels before filtering=%d", - mac_ctx->scan.occupiedChannels[session_id].numChannels); - if (CSR_IS_ROAM_INTRA_BAND_ENABLED(mac_ctx)) { if (WLAN_REG_IS_5GHZ_CH_FREQ(op_freq)) band = BAND_5G; @@ -17652,14 +17644,6 @@ csr_fetch_ch_lst_from_occupied_lst(struct mac_context *mac_ctx, continue; } req_buf->ConnectedNetwork.chan_freq_cache[num_channels++] = *ch_lst; - if (*ch_lst) - QDF_TRACE(QDF_MODULE_ID_SME, QDF_TRACE_LEVEL_DEBUG, - "DFSRoam=%d, ChnlState=%d, Chnl freq=%d, num_ch=%d", - mac_ctx->mlme_cfg->lfr.roaming_dfs_channel, - wlan_reg_get_channel_state_for_freq( - mac_ctx->pdev, *ch_lst), - *ch_lst, - num_channels); ch_lst++; } req_buf->ConnectedNetwork.ChannelCount = num_channels; @@ -17753,7 +17737,6 @@ csr_add_ch_lst_from_roam_scan_list(struct mac_context *mac_ctx, sme_err("Failed to copy channels to roam list"); return status; } - sme_debug("Added to roam chan list:"); sme_dump_freq_list(pref_chan_info); req_buf->ChannelCacheType = CHANNEL_LIST_DYNAMIC; @@ -17820,8 +17803,6 @@ csr_rso_command_fill_11w_params(struct mac_context *mac_ctx, network_cfg->gp_mgmt_cipher_suite = group_mgmt_cipher; else network_cfg->gp_mgmt_cipher_suite = eSIR_ED_NONE; - - pe_debug("gp_mgmt_cipher_suite %d", network_cfg->gp_mgmt_cipher_suite); } #else @@ -17962,13 +17943,6 @@ csr_create_roam_scan_offload_request(struct mac_context *mac_ctx, req_buf->RoamBeaconRssiWeight = roam_info->cfgParams.nRoamBeaconRssiWeight; csr_copy_mawc_config(mac_ctx, &req_buf->mawc_roam_params); - sme_debug("MAWC:global=%d,roam=%d,traffic=%d,ap_rssi=%d,high=%d,low=%d", - req_buf->mawc_roam_params.mawc_enabled, - req_buf->mawc_roam_params.mawc_roam_enabled, - req_buf->mawc_roam_params.mawc_roam_traffic_threshold, - req_buf->mawc_roam_params.mawc_roam_ap_rssi_threshold, - req_buf->mawc_roam_params.mawc_roam_rssi_high_adjust, - req_buf->mawc_roam_params.mawc_roam_rssi_low_adjust); req_buf->min_rssi_params[DEAUTH_MIN_RSSI] = mac_ctx->mlme_cfg->trig_min_rssi[DEAUTH_MIN_RSSI]; @@ -17987,12 +17961,13 @@ csr_create_roam_scan_offload_request(struct mac_context *mac_ctx, (csr_is_auth_type_ese(req_buf-> ConnectedNetwork.authentication))); req_buf->is_11r_assoc = roam_info->is11rAssoc; - sme_debug("IsEseAssoc: %d is_11r_assoc: %d middle of roaming: %d", - req_buf->IsESEAssoc, req_buf->is_11r_assoc, - req_buf->middle_of_roaming); - sme_debug("ese_neighbor_list_recvd: %d cur no of chan: %d", - ese_neighbor_list_recvd, curr_ch_lst_info->numOfChannels); + if (req_buf->IsESEAssoc || req_buf->is_11r_assoc || + req_buf->middle_of_roaming) + sme_debug("IsEseAssoc: %d is_11r_assoc: %d middle of roaming: %d ese_neighbor_list_recvd: %d cur no of chan: %d", + req_buf->IsESEAssoc, req_buf->is_11r_assoc, + req_buf->middle_of_roaming, ese_neighbor_list_recvd, + curr_ch_lst_info->numOfChannels); #endif if (ese_neighbor_list_recvd || @@ -18109,18 +18084,6 @@ csr_create_roam_scan_offload_request(struct mac_context *mac_ctx, req_buf->lca_config_params.num_disallowed_aps = mac_ctx->mlme_cfg->lfr.lfr3_num_disallowed_aps; - sme_debug("HomeAwayTime=%d EarlyStopFeature Enable=%d", - req_buf->HomeAwayTime, req_buf->early_stop_scan_enable); - - sme_debug("MinThresh=%d, MaxThresh=%d", - req_buf->early_stop_scan_min_threshold, - req_buf->early_stop_scan_max_threshold); - - sme_debug("disallow_dur=%d rssi_chan_pen=%d num_disallowed_aps=%d", - req_buf->lca_config_params.disallow_duration, - req_buf->lca_config_params.rssi_channel_penalization, - req_buf->lca_config_params.num_disallowed_aps); - /* For RSO Stop, we need to notify FW to deinit BTM */ if (command == ROAM_SCAN_OFFLOAD_STOP) req_buf->btm_offload_config = 0; @@ -18176,7 +18139,6 @@ csr_update_11k_offload_params(struct mac_context *mac_ctx, csr_config->offload_11k_enable_bitmask; } else { params->offload_11k_bitmask = 0; - sme_debug("11k offload disabled in RSO"); return; } @@ -18245,8 +18207,6 @@ csr_update_11k_offload_params(struct mac_context *mac_ctx, qdf_mem_copy(params->neighbor_report_params.ssid.mac_ssid, session->connectedProfile.SSID.ssId, session->connectedProfile.SSID.length); - - sme_debug("Updated 11k offload params to RSO"); } QDF_STATUS csr_invoke_neighbor_report_request(uint8_t session_id, @@ -18370,7 +18330,6 @@ csr_add_rssi_reject_ap_list(struct mac_context *mac_ctx, MAX_RSSI_AVOID_BSSID_LIST, DRIVER_RSSI_REJECT_TYPE); if (!roam_params->num_rssi_rejection_ap) { - sme_debug("RSSI reject list NULL"); qdf_mem_free(reject_list); return; } @@ -18903,10 +18862,8 @@ uint8_t csr_get_roam_enabled_sta_sessionid(struct mac_context *mac_ctx) session->pCurRoamProfile->csrPersona != QDF_STA_MODE) continue; - if (MLME_IS_ROAM_INITIALIZED(mac_ctx->psoc, i)) { - sme_debug("ROAM: Enabled on vdev_id: %d", i); + if (MLME_IS_ROAM_INITIALIZED(mac_ctx->psoc, i)) return i; - } } return WLAN_UMAC_VDEV_ID_MAX; @@ -19258,12 +19215,12 @@ csr_roam_offload_scan(struct mac_context *mac_ctx, uint8_t session_id, &mac_ctx->roam.neighborRoamInfo[session_id]; struct roam_ext_params *roam_params_dst; struct roam_ext_params *roam_params_src; - uint8_t i, temp_session_id; + uint8_t temp_session_id; bool prev_roaming_state; enum csr_akm_type roam_profile_akm = eCSR_AUTH_TYPE_UNKNOWN; uint32_t fw_akm_bitmap; - sme_debug("RSO Command %d, Session id %d, Reason %d", command, + sme_debug("RSO Command %d, vdev %d, Reason %d", command, session_id, reason); if (!session) { QDF_TRACE(QDF_MODULE_ID_SME, QDF_TRACE_LEVEL_ERROR, @@ -19396,7 +19353,6 @@ csr_roam_offload_scan(struct mac_context *mac_ctx, uint8_t session_id, (-1); req_buf->rssi_thresh_offset_5g = roam_info->cfgParams.rssi_thresh_offset_5g; - sme_debug("5g offset threshold: %d", req_buf->rssi_thresh_offset_5g); qdf_mem_copy(roam_params_dst, roam_params_src, sizeof(*roam_params_dst)); roam_params_dst->traffic_threshold = @@ -19430,57 +19386,12 @@ csr_roam_offload_scan(struct mac_context *mac_ctx, uint8_t session_id, */ if (roam_params_src->rssi_diff) req_buf->RoamRssiDiff = roam_params_src->rssi_diff; - QDF_TRACE(QDF_MODULE_ID_SME, QDF_TRACE_LEVEL_DEBUG, - "num_bssid_avoid_list: %d num_ssid_allowed_list: %d num_bssid_favored: %d raise_rssi_thresh_5g: %d drop_rssi_thresh_5g: %d raise_rssi_type_5g: %d raise_factor_5g: %d drop_rssi_type_5g: %d drop_factor_5g: %d max_raise_rssi_5g: %d max_drop_rssi_5g: %d rssi_diff: %d alert_rssi_threshold: %d", - roam_params_dst->num_bssid_avoid_list, - roam_params_dst->num_ssid_allowed_list, - roam_params_dst->num_bssid_favored, - roam_params_dst->raise_rssi_thresh_5g, - roam_params_dst->drop_rssi_thresh_5g, - roam_params_dst->raise_rssi_type_5g, - roam_params_dst->raise_factor_5g, - roam_params_dst->drop_rssi_type_5g, - roam_params_dst->drop_factor_5g, - roam_params_dst->max_raise_rssi_5g, - roam_params_dst->max_drop_rssi_5g, - req_buf->RoamRssiDiff, roam_params_dst->alert_rssi_threshold); /* Set initial dense roam status */ if (mac_ctx->scan.roam_candidate_count[session_id] > roam_params_dst->dense_min_aps_cnt) roam_params_dst->initial_dense_status = true; - QDF_TRACE(QDF_MODULE_ID_SME, QDF_TRACE_LEVEL_DEBUG, - "dense_rssi_thresh_offset: %d, dense_min_aps_cnt:%d, traffic_threshold:%d, " - "initial_dense_status:%d, candidate count:%d", - roam_params_dst->dense_rssi_thresh_offset, - roam_params_dst->dense_min_aps_cnt, - roam_params_dst->traffic_threshold, - roam_params_dst->initial_dense_status, - mac_ctx->scan.roam_candidate_count[session_id]); - sme_debug("BG Scan Bad RSSI:%d, bitmap:0x%x Offset for 2G to 5G Roam %d", - roam_params_dst->bg_scan_bad_rssi_thresh, - roam_params_dst->bg_scan_client_bitmap, - roam_params_dst->roam_bad_rssi_thresh_offset_2g); - - for (i = 0; i < roam_params_dst->num_bssid_avoid_list; i++) { - QDF_TRACE(QDF_MODULE_ID_SME, QDF_TRACE_LEVEL_DEBUG, - "Blacklist Bssid:"QDF_MAC_ADDR_STR")", - QDF_MAC_ADDR_ARRAY(roam_params_dst->bssid_avoid_list[i]. - bytes)); - } - for (i = 0; i < roam_params_dst->num_ssid_allowed_list; i++) { - QDF_TRACE(QDF_MODULE_ID_SME, QDF_TRACE_LEVEL_DEBUG, - "Whitelist: %.*s", - roam_params_dst->ssid_allowed_list[i].length, - roam_params_dst->ssid_allowed_list[i].ssId); - } - for (i = 0; i < roam_params_dst->num_bssid_favored; i++) { - QDF_TRACE(QDF_MODULE_ID_SME, QDF_TRACE_LEVEL_DEBUG, - "Preferred Bssid:"QDF_MAC_ADDR_STR") score: %d", - QDF_MAC_ADDR_ARRAY(roam_params_dst->bssid_favored[i].bytes), - roam_params_dst->bssid_favored_factor[i]); - } req_buf->hi_rssi_scan_max_count = roam_info->cfgParams.hi_rssi_scan_max_count; req_buf->hi_rssi_scan_delay = @@ -19499,12 +19410,6 @@ csr_roam_offload_scan(struct mac_context *mac_ctx, uint8_t session_id, req_buf->hi_rssi_scan_rssi_delta = roam_info->cfgParams.hi_rssi_scan_rssi_delta; - sme_debug("hi_rssi:delta=%d, max_count=%d, delay=%d, ub=%d", - req_buf->hi_rssi_scan_rssi_delta, - req_buf->hi_rssi_scan_max_count, - req_buf->hi_rssi_scan_delay, - req_buf->hi_rssi_scan_rssi_ub); - if (command != ROAM_SCAN_OFFLOAD_STOP) { req_buf->assoc_ie.length = session->nAddIEAssocLength; qdf_mem_copy(req_buf->assoc_ie.addIEdata, @@ -21796,7 +21701,6 @@ csr_send_roam_offload_init_msg(struct mac_context *mac, uint32_t vdev_id, * stop command, otherwise due to a race if deinit RSO goes first * without RSO stop , firmware will assert. */ - sme_debug("Post roam init to LIM for vdev %d", vdev_id); message.bodyptr = params; message.type = eWNI_SME_ROAM_INIT_PARAM; status = scheduler_post_message(QDF_MODULE_ID_SME, QDF_MODULE_ID_PE, diff --git a/core/sme/src/csr/csr_api_scan.c b/core/sme/src/csr/csr_api_scan.c index 70b1ae558398..ede88897ee41 100644 --- a/core/sme/src/csr/csr_api_scan.c +++ b/core/sme/src/csr/csr_api_scan.c @@ -357,8 +357,6 @@ static void csr_add_to_occupied_channels(struct mac_context *mac, num_occupied_ch, ch_freq); if (QDF_IS_STATUS_SUCCESS(status)) { occupied_ch->numChannels++; - sme_debug("Added channel freq %d to the list (count=%d)", - ch_freq, occupied_ch->numChannels); if (occupied_ch->numChannels > CSR_BG_SCAN_OCCUPIED_CHANNEL_LIST_LEN) occupied_ch->numChannels = @@ -2716,6 +2714,27 @@ void csr_remove_bssid_from_scan_list(struct mac_context *mac_ctx, csr_flush_bssid(mac_ctx, bssid); } +static void csr_dump_occupied_chan_list(struct csr_channel *occupied_ch) +{ + uint8_t idx; + uint32_t buff_len; + char *chan_buff; + uint32_t len = 0; + + buff_len = (occupied_ch->numChannels * 5) + 1; + chan_buff = qdf_mem_malloc(buff_len); + if (!chan_buff) + return; + + for (idx = 0; idx < occupied_ch->numChannels; idx++) + len += qdf_scnprintf(chan_buff + len, buff_len - len, " %d", + occupied_ch->channel_freq_list[idx]); + + sme_nofl_debug("Occupied chan list[%d]:%s", + occupied_ch->numChannels, chan_buff); + + qdf_mem_free(chan_buff); +} void csr_init_occupied_channels_list(struct mac_context *mac_ctx, uint8_t sessionId) { @@ -2788,11 +2807,12 @@ void csr_init_occupied_channels_list(struct mac_context *mac_ctx, if (list) sme_debug("num_entries %d", qdf_list_size(list)); if (!list || (list && !qdf_list_size(list))) { - sme_err("get scan result failed"); wlan_objmgr_pdev_release_ref(pdev, WLAN_LEGACY_MAC_ID); qdf_mem_free(filter); if (list) ucfg_scan_purge_results(list); + csr_dump_occupied_chan_list( + &mac_ctx->scan.occupiedChannels[sessionId]); return; } @@ -2809,6 +2829,7 @@ void csr_init_occupied_channels_list(struct mac_context *mac_ctx, cur_lst = next_lst; next_lst = NULL; } + csr_dump_occupied_chan_list(&mac_ctx->scan.occupiedChannels[sessionId]); qdf_mem_free(filter); ucfg_scan_purge_results(list); diff --git a/core/sme/src/csr/csr_neighbor_roam.c b/core/sme/src/csr/csr_neighbor_roam.c index 79c7b737ee2c..46b96be753be 100644 --- a/core/sme/src/csr/csr_neighbor_roam.c +++ b/core/sme/src/csr/csr_neighbor_roam.c @@ -58,8 +58,7 @@ void csr_neighbor_roam_state_transition(struct mac_context *mac_ctx, mac_ctx->roam.neighborRoamInfo[session].prevNeighborRoamState = mac_ctx->roam.neighborRoamInfo[session].neighborRoamState; mac_ctx->roam.neighborRoamInfo[session].neighborRoamState = newstate; - QDF_TRACE(QDF_MODULE_ID_SME, QDF_TRACE_LEVEL_DEBUG, - FL("Sessionid (%d) NeighborRoam transition from %s to %s"), + sme_nofl_debug("NeighborRoam transition: vdev %d %s --> %s", session, csr_neighbor_roam_state_to_string( mac_ctx->roam.neighborRoamInfo[session].prevNeighborRoamState), csr_neighbor_roam_state_to_string(newstate)); @@ -832,8 +831,6 @@ static void csr_neighbor_roam_info_ctx_init(struct mac_context *mac, ngbr_roam_info->is11rAssoc = true; } else ngbr_roam_info->is11rAssoc = false; - QDF_TRACE(QDF_MODULE_ID_SME, QDF_TRACE_LEVEL_DEBUG, - FL("11rAssoc is = %d"), ngbr_roam_info->is11rAssoc); #ifdef FEATURE_WLAN_ESE /* Based on the auth scheme tell if we are 11r */ @@ -843,9 +840,6 @@ static void csr_neighbor_roam_info_ctx_init(struct mac_context *mac, ngbr_roam_info->isESEAssoc = true; } else ngbr_roam_info->isESEAssoc = false; - QDF_TRACE(QDF_MODULE_ID_SME, QDF_TRACE_LEVEL_DEBUG, - FL("isESEAssoc is = %d ft = %d"), - ngbr_roam_info->isESEAssoc, init_ft_flag); #endif /* If "FastRoamEnabled" ini is enabled */ if (csr_roam_is_fast_roam_enabled(mac, session_id)) @@ -873,9 +867,6 @@ static void csr_neighbor_roam_info_ctx_init(struct mac_context *mac, #ifdef WLAN_FEATURE_ROAM_OFFLOAD if (session->roam_synch_in_progress) { if (mac->roam.pReassocResp) { - QDF_TRACE(QDF_MODULE_ID_SME, - QDF_TRACE_LEVEL_DEBUG, - "Free Reassoc Rsp"); qdf_mem_free(mac->roam.pReassocResp); mac->roam.pReassocResp = NULL; } @@ -920,7 +911,7 @@ QDF_STATUS csr_neighbor_roam_indicate_connect( return QDF_STATUS_E_FAILURE; } - sme_debug("Connect ind. received with session id %d in state %s", + sme_debug("Connect ind, vdev id %d in state %s", session_id, mac_trace_get_neighbour_roam_state( ngbr_roam_info->neighborRoamState)); diff --git a/core/wma/src/wma_scan_roam.c b/core/wma/src/wma_scan_roam.c index 62a12453a0f0..86b25adcd45a 100644 --- a/core/wma/src/wma_scan_roam.c +++ b/core/wma/src/wma_scan_roam.c @@ -273,10 +273,8 @@ static void wma_roam_scan_fill_fils_params(tp_wma_handle wma_handle, { struct roam_fils_params *dst_fils_params, *src_fils_params; - if (!params || !roam_req || !roam_req->is_fils_connection) { - wma_debug("Invalid input"); + if (!params || !roam_req || !roam_req->is_fils_connection) return; - } src_fils_params = &roam_req->roam_fils_params; dst_fils_params = ¶ms->roam_fils_params; @@ -336,7 +334,6 @@ static void wma_roam_scan_offload_set_params( params->auth_mode = e_csr_auth_type_to_rsn_authmode (roam_req->ConnectedNetwork.authentication, roam_req->ConnectedNetwork.encryption); - WMA_LOGD("%s : auth mode = %d", __func__, params->auth_mode); params->roam_offload_enabled = roam_req->roam_offload_enabled; params->roam_offload_params.ho_delay_for_rx = @@ -366,11 +363,10 @@ static void wma_roam_scan_offload_set_params( params->fw_pmksa_cache = roam_req->pmkid_modes.fw_pmksa_cache; params->rct_validity_timer = roam_req->rct_validity_timer; params->is_adaptive_11r = roam_req->is_adaptive_11r_connection; - WMA_LOGD(FL("qos_caps: %d, qos_enabled: %d, ho_delay_for_rx: %d, roam_scan_mode: %d"), + wma_debug("qos_caps %d, qos_enabled %d, ho_delay_for_rx %d, roam_scan_mode %d roam_preauth: retrycount %d, no_ack_timeout %d", params->roam_offload_params.qos_caps, params->roam_offload_params.qos_enabled, - params->roam_offload_params.ho_delay_for_rx, params->mode); - WMA_LOGD(FL("roam_preauth_retry_count: %d, roam_preauth_no_ack_timeout: %d"), + params->roam_offload_params.ho_delay_for_rx, params->mode, params->roam_offload_params.roam_preauth_retry_count, params->roam_offload_params.roam_preauth_no_ack_timeout); } @@ -439,9 +435,9 @@ QDF_STATUS wma_roam_scan_offload_mode(tp_wma_handle wma_handle, wma_roam_scan_fill_fils_params(wma_handle, params, roam_req); } - WMA_LOGD(FL("min_delay_btw_roam_scans:%d, roam_tri_reason_bitmask:%d"), - params->min_delay_btw_roam_scans, - params->roam_trigger_reason_bitmask); + wma_debug("min_delay_btw_roam_scans %d, roam_tri_reason_bitmask %d", + params->min_delay_btw_roam_scans, + params->roam_trigger_reason_bitmask); wma_roam_scan_offload_set_params( wma_handle, @@ -455,7 +451,6 @@ QDF_STATUS wma_roam_scan_offload_mode(tp_wma_handle wma_handle, if (QDF_IS_STATUS_ERROR(status)) return status; - WMA_LOGD("%s: WMA --> WMI_ROAM_SCAN_MODE", __func__); return status; } @@ -577,9 +572,6 @@ wma_roam_scan_offload_rssi_thresh(tp_wma_handle wma_handle, WMA_NOISE_FLOOR_DBM_DEFAULT) & 0x000000ff; - WMA_LOGD("WMA --> good_rssi_threshold=%d", - params.good_rssi_threshold); - if (roam_req->early_stop_scan_enable) { if (db2dbm_enabled) { params.roam_earlystop_thres_min = @@ -608,11 +600,11 @@ wma_roam_scan_offload_rssi_thresh(tp_wma_handle wma_handle, params.rssi_thresh_offset_5g = roam_req->rssi_thresh_offset_5g; - WMA_LOGD("early_stop_thresholds en=%d, min=%d, max=%d", - roam_req->early_stop_scan_enable, - params.roam_earlystop_thres_min, - params.roam_earlystop_thres_max); - WMA_LOGD("rssi_thresh_offset_5g = %d", params.rssi_thresh_offset_5g); + wma_debug("good_rssi_threshold %d, early_stop_thresholds en=%d, min=%d, max=%d roam_scan_rssi_thresh=%d, roam_rssi_thresh_diff=%d", + params.good_rssi_threshold, roam_req->early_stop_scan_enable, + params.roam_earlystop_thres_min, + params.roam_earlystop_thres_max, rssi_thresh, + rssi_thresh_diff); status = wmi_unified_roam_scan_offload_rssi_thresh_cmd( wma_handle->wmi_handle, ¶ms); @@ -621,21 +613,16 @@ wma_roam_scan_offload_rssi_thresh(tp_wma_handle wma_handle, return status; } - WMA_LOGD(FL("roam_scan_rssi_thresh=%d, roam_rssi_thresh_diff=%d"), - rssi_thresh, rssi_thresh_diff); - WMA_LOGD( - FL("hirssi_scan max_count=%d, delta=%d, hirssi_upper_bound=%d"), - hirssi_scan_max_count, hirssi_scan_delta, hirssi_upper_bound); - WMA_LOGD( - FL("dense_rssi_thresh_offset=%d, dense_min_aps_cnt=%d, traffic_threshold=%d initial_dense_status=%d"), - roam_params->dense_rssi_thresh_offset, - roam_params->dense_min_aps_cnt, - roam_params->traffic_threshold, - roam_params->initial_dense_status); - WMA_LOGD(FL("BG Scan Bad RSSI:%d, bitmap:0x%x Offset for 2G to 5G Roam:%d"), - roam_params->bg_scan_bad_rssi_thresh, - roam_params->bg_scan_client_bitmap, - roam_params->roam_bad_rssi_thresh_offset_2g); + wma_debug("hirssi max cnt %d, delta %d, hirssi upper bound %d dense rssi thresh offset %d, dense min aps cnt %d, traffic_threshold %d dense_status=%d", + hirssi_scan_max_count, hirssi_scan_delta, hirssi_upper_bound, + roam_params->dense_rssi_thresh_offset, + roam_params->dense_min_aps_cnt, + roam_params->traffic_threshold, + roam_params->initial_dense_status); + wma_debug("BG Scan Bad RSSI:%d, bitmap:0x%x Offset for 2G to 5G Roam:%d", + roam_params->bg_scan_bad_rssi_thresh, + roam_params->bg_scan_client_bitmap, + roam_params->roam_bad_rssi_thresh_offset_2g); return status; } @@ -1173,18 +1160,6 @@ void wma_roam_scan_fill_scan_params(tp_wma_handle wma_handle, WMI_SCAN_ADD_DS_IE_IN_PROBE_REQ; if (roam_req) { /* Parameters updated after association is complete */ - WMA_LOGD("%s: NeighborScanChannelMinTime: %d NeighborScanChannelMaxTime: %d", - __func__, - roam_req->NeighborScanChannelMinTime, - roam_req->NeighborScanChannelMaxTime); - WMA_LOGD("%s: NeighborScanTimerPeriod: %d " - "neighbor_scan_min_timer_period %d " - "HomeAwayTime: %d nProbes: %d", - __func__, - roam_req->NeighborScanTimerPeriod, - roam_req->neighbor_scan_min_timer_period, - roam_req->HomeAwayTime, roam_req->nProbes); - wlan_scan_cfg_get_passive_dwelltime(wma_handle->psoc, &scan_params->dwell_time_passive); /* @@ -1289,16 +1264,15 @@ void wma_roam_scan_fill_scan_params(tp_wma_handle wma_handle, scan_params->n_probes = 0; } - WMA_LOGD("%s: Rome roam scan parameters: dwell_time_active = %d, dwell_time_passive = %d", - __func__, scan_params->dwell_time_active, - scan_params->dwell_time_passive); - WMA_LOGD("%s: min_rest_time = %d, max_rest_time = %d, repeat_probe_time = %d n_probes = %d", - __func__, scan_params->min_rest_time, - scan_params->max_rest_time, - scan_params->repeat_probe_time, scan_params->n_probes); - WMA_LOGD("%s: max_scan_time = %d, idle_time = %d, burst_duration = %d, scan_ctrl_flags = 0x%x", - __func__, scan_params->max_scan_time, scan_params->idle_time, - scan_params->burst_duration, scan_params->scan_ctrl_flags); + wma_debug("Rome roam scan parameters: dwell time: active %d passive %d, minrest %d max rest %d repeat probe time %d n_probes %d", + scan_params->dwell_time_active, + scan_params->dwell_time_passive, scan_params->min_rest_time, + scan_params->max_rest_time, scan_params->repeat_probe_time, + scan_params->n_probes); + + wma_debug("max_scan_time %d, idle_time %d, burst_duration %d, scan_ctrl_flags 0x%x", + scan_params->max_scan_time, scan_params->idle_time, + scan_params->burst_duration, scan_params->scan_ctrl_flags); } /** @@ -1459,12 +1433,14 @@ static QDF_STATUS wma_roam_scan_filter(tp_wma_handle wma_handle, roam_params->ssid_allowed_list[i].length); params->ssid_allowed_list[i].length = roam_params->ssid_allowed_list[i].length; - WMA_LOGD("%s: SSID length=%d", __func__, - params->ssid_allowed_list[i].length); - qdf_trace_hex_dump(QDF_MODULE_ID_WMA, QDF_TRACE_LEVEL_DEBUG, - (uint8_t *)params->ssid_allowed_list[i].mac_ssid, - params->ssid_allowed_list[i].length); + wma_debug("SSID %d: %.*s", i, + params->ssid_allowed_list[i].length, + params->ssid_allowed_list[i].mac_ssid); } + + for (i = 0; i < params->num_bssid_black_list; i++) + wma_debug("Blacklist bssid[%d]:" QDF_MAC_ADDR_STR, i, + QDF_MAC_ADDR_ARRAY(params->bssid_avoid_list[i].bytes)); qdf_mem_copy(params->bssid_favored, roam_params->bssid_favored, MAX_BSSID_FAVORED * sizeof(struct qdf_mac_addr)); qdf_mem_copy(params->bssid_favored_factor, @@ -1474,6 +1450,11 @@ static QDF_STATUS wma_roam_scan_filter(tp_wma_handle wma_handle, MAX_RSSI_AVOID_BSSID_LIST * sizeof(struct reject_ap_config_params)); + for (i = 0; i < params->num_bssid_preferred_list; i++) + wma_debug("Preferred Bssid[%d]:"QDF_MAC_ADDR_STR" score: %d", i, + QDF_MAC_ADDR_ARRAY(params->bssid_favored[i].bytes), + params->bssid_favored_factor[i]); + if (params->lca_disallow_config_present) { params->disallow_duration = lca_config_params->disallow_duration; @@ -1481,6 +1462,10 @@ static QDF_STATUS wma_roam_scan_filter(tp_wma_handle wma_handle, = lca_config_params->rssi_channel_penalization; params->num_disallowed_aps = lca_config_params->num_disallowed_aps; + wma_debug("disallow_dur %d rssi_chan_pen %d num_disallowed_aps %d", + params->disallow_duration, + params->rssi_channel_penalization, + params->num_disallowed_aps); } status = wmi_unified_roam_scan_filter_cmd(wma_handle->wmi_handle, params); @@ -1819,9 +1804,10 @@ QDF_STATUS wma_process_roaming_config(tp_wma_handle wma_handle, return QDF_STATUS_E_FAILURE; } - WMA_LOGD("%s: RSO Command:%d, reason:%d session ID %d en %d", __func__, - roam_req->Command, roam_req->reason, roam_req->sessionId, - roam_req->RoamScanOffloadEnabled); + wma_debug("RSO Command:%d, reason %d vdev %d enable %d 11k bitmask %d", + roam_req->Command, roam_req->reason, roam_req->sessionId, + roam_req->RoamScanOffloadEnabled, + roam_req->offload_11k_params.offload_11k_bitmask); wma_handle->interfaces[roam_req->sessionId].roaming_in_progress = false; switch (roam_req->Command) { case ROAM_SCAN_OFFLOAD_START: diff --git a/core/wma/src/wma_utils.c b/core/wma/src/wma_utils.c index 7f3b6d83dd86..bde98d58cece 100644 --- a/core/wma/src/wma_utils.c +++ b/core/wma/src/wma_utils.c @@ -4036,9 +4036,7 @@ static void wma_set_roam_offload_flag(tp_wma_handle wma, uint8_t vdev_id, flag |= WMI_ROAM_BMISS_FINAL_SCAN_TYPE_FLAG; } - WMA_LOGD("%s: vdev_id:%d, is_set:%d, flag:%d", - __func__, vdev_id, is_set, flag); - + wma_debug("vdev_id:%d, is_set:%d, flag:%d", vdev_id, is_set, flag); status = wma_vdev_set_param(wma->wmi_handle, vdev_id, WMI_VDEV_PARAM_ROAM_FW_OFFLOAD, flag); if (QDF_IS_STATUS_ERROR(status)) @@ -4051,9 +4049,6 @@ void wma_update_roam_offload_flag(void *handle, tp_wma_handle wma = handle; struct wma_txrx_node *iface; - WMA_LOGD("%s: vdev_id:%d, is_connected:%d", __func__, - params->vdev_id, params->enable); - if (!wma_is_vdev_valid(params->vdev_id)) { WMA_LOGE("%s: vdev_id: %d is not active", __func__, params->vdev_id);