qcacld-3.0: Rate limit logs related to SAP chan select
When selecting channel for SAP to operate on, it searches, calculates, and sorts the channels. Each of these steps produces a lot of prints, so rate limit them to prevent a time out. Change-Id: If78c7a4f840bf9353f42dd544134ee690637d22e CRs-fixed: 2865639
This commit is contained in:
@@ -1,5 +1,5 @@
|
|||||||
/*
|
/*
|
||||||
* Copyright (c) 2012-2020 The Linux Foundation. All rights reserved.
|
* Copyright (c) 2012-2021 The Linux Foundation. All rights reserved.
|
||||||
*
|
*
|
||||||
* Permission to use, copy, modify, and/or distribute this software for
|
* Permission to use, copy, modify, and/or distribute this software for
|
||||||
* any purpose with or without fee is hereby granted, provided that the
|
* any purpose with or without fee is hereby granted, provided that the
|
||||||
@@ -457,7 +457,7 @@ static bool sap_chan_sel_init(mac_handle_t mac_handle,
|
|||||||
if (sap_dfs_is_channel_in_nol_list(
|
if (sap_dfs_is_channel_in_nol_list(
|
||||||
sap_ctx, channel,
|
sap_ctx, channel,
|
||||||
PHY_SINGLE_CHANNEL_CENTERED)) {
|
PHY_SINGLE_CHANNEL_CENTERED)) {
|
||||||
sap_debug("Ch %d is in NOL list", channel);
|
sap_debug_rl("Ch %d is in NOL list", channel);
|
||||||
continue;
|
continue;
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -1439,9 +1439,9 @@ static void sap_compute_spect_weight(tSapChSelSpectInfo *pSpectInfoParams,
|
|||||||
normalized_weight =
|
normalized_weight =
|
||||||
((SAP_ACS_WEIGHT_MAX - pSpectCh->weight) *
|
((SAP_ACS_WEIGHT_MAX - pSpectCh->weight) *
|
||||||
(100 - normalize_factor)) / 100;
|
(100 - normalize_factor)) / 100;
|
||||||
sap_debug("freq %d old weight %d new weight %d",
|
sap_debug_rl("freq %d old weight %d new weight %d",
|
||||||
chan_freq, pSpectCh->weight,
|
chan_freq, pSpectCh->weight,
|
||||||
pSpectCh->weight + normalized_weight);
|
pSpectCh->weight + normalized_weight);
|
||||||
pSpectCh->weight += normalized_weight;
|
pSpectCh->weight += normalized_weight;
|
||||||
freq_present_in_list = false;
|
freq_present_in_list = false;
|
||||||
}
|
}
|
||||||
@@ -1451,9 +1451,9 @@ static void sap_compute_spect_weight(tSapChSelSpectInfo *pSpectInfoParams,
|
|||||||
pSpectCh->weight_copy = pSpectCh->weight;
|
pSpectCh->weight_copy = pSpectCh->weight;
|
||||||
|
|
||||||
debug_info:
|
debug_info:
|
||||||
sap_debug("freq = %d, weight = %d rssi = %d bss count = %d",
|
sap_debug_rl("freq = %d, weight = %d rssi = %d bss count = %d",
|
||||||
pSpectCh->chan_freq, pSpectCh->weight,
|
pSpectCh->chan_freq, pSpectCh->weight,
|
||||||
pSpectCh->rssiAgr, pSpectCh->bssCount);
|
pSpectCh->rssiAgr, pSpectCh->bssCount);
|
||||||
|
|
||||||
pSpectCh++;
|
pSpectCh++;
|
||||||
}
|
}
|
||||||
@@ -1656,9 +1656,9 @@ static void sap_sort_chl_weight_80_mhz(struct mac_context *mac_ctx,
|
|||||||
pSpectInfo = pSpectInfoParams->pSpectCh;
|
pSpectInfo = pSpectInfoParams->pSpectCh;
|
||||||
|
|
||||||
for (j = 0; j < (pSpectInfoParams->numSpectChans); j++) {
|
for (j = 0; j < (pSpectInfoParams->numSpectChans); j++) {
|
||||||
sap_debug("freq = %d weight = %d rssi = %d bss count = %d",
|
sap_debug_rl("freq = %d weight = %d rssi = %d bss count = %d",
|
||||||
pSpectInfo->chan_freq, pSpectInfo->weight,
|
pSpectInfo->chan_freq, pSpectInfo->weight,
|
||||||
pSpectInfo->rssiAgr, pSpectInfo->bssCount);
|
pSpectInfo->rssiAgr, pSpectInfo->bssCount);
|
||||||
|
|
||||||
pSpectInfo++;
|
pSpectInfo++;
|
||||||
}
|
}
|
||||||
@@ -1821,9 +1821,9 @@ static void sap_sort_chl_weight_160_mhz(struct mac_context *mac_ctx,
|
|||||||
|
|
||||||
pSpectInfo = pSpectInfoParams->pSpectCh;
|
pSpectInfo = pSpectInfoParams->pSpectCh;
|
||||||
for (j = 0; j < (pSpectInfoParams->numSpectChans); j++) {
|
for (j = 0; j < (pSpectInfoParams->numSpectChans); j++) {
|
||||||
sap_debug("freq = %d weight = %d rssi = %d bss count = %d",
|
sap_debug_rl("freq = %d weight = %d rssi = %d bss count = %d",
|
||||||
pSpectInfo->chan_freq, pSpectInfo->weight,
|
pSpectInfo->chan_freq, pSpectInfo->weight,
|
||||||
pSpectInfo->rssiAgr, pSpectInfo->bssCount);
|
pSpectInfo->rssiAgr, pSpectInfo->bssCount);
|
||||||
|
|
||||||
pSpectInfo++;
|
pSpectInfo++;
|
||||||
}
|
}
|
||||||
@@ -2013,9 +2013,9 @@ static void sap_sort_chl_weight_ht40_24_g(struct mac_context *mac_ctx,
|
|||||||
|
|
||||||
pSpectInfo = pSpectInfoParams->pSpectCh;
|
pSpectInfo = pSpectInfoParams->pSpectCh;
|
||||||
for (j = 0; j < (pSpectInfoParams->numSpectChans); j++) {
|
for (j = 0; j < (pSpectInfoParams->numSpectChans); j++) {
|
||||||
sap_debug("freq = %d weight = %d rssi = %d bss count = %d",
|
sap_debug_rl("freq = %d weight = %d rssi = %d bss count = %d",
|
||||||
pSpectInfo->chan_freq, pSpectInfo->weight,
|
pSpectInfo->chan_freq, pSpectInfo->weight,
|
||||||
pSpectInfo->rssiAgr, pSpectInfo->bssCount);
|
pSpectInfo->rssiAgr, pSpectInfo->bssCount);
|
||||||
|
|
||||||
pSpectInfo++;
|
pSpectInfo++;
|
||||||
}
|
}
|
||||||
@@ -2121,9 +2121,9 @@ static void sap_sort_chl_weight_40_mhz(struct mac_context *mac_ctx,
|
|||||||
|
|
||||||
pSpectInfo = pSpectInfoParams->pSpectCh;
|
pSpectInfo = pSpectInfoParams->pSpectCh;
|
||||||
for (j = 0; j < (pSpectInfoParams->numSpectChans); j++) {
|
for (j = 0; j < (pSpectInfoParams->numSpectChans); j++) {
|
||||||
sap_debug("freq = %d weight = %d rssi = %d bss count = %d",
|
sap_debug_rl("freq = %d weight = %d rssi = %d bss count = %d",
|
||||||
pSpectInfo->chan_freq, pSpectInfo->weight,
|
pSpectInfo->chan_freq, pSpectInfo->weight,
|
||||||
pSpectInfo->rssiAgr, pSpectInfo->bssCount);
|
pSpectInfo->rssiAgr, pSpectInfo->bssCount);
|
||||||
|
|
||||||
pSpectInfo++;
|
pSpectInfo++;
|
||||||
}
|
}
|
||||||
@@ -2192,9 +2192,9 @@ static void sap_sort_chl_weight_all(struct mac_context *mac_ctx,
|
|||||||
|
|
||||||
pSpectCh = pSpectInfoParams->pSpectCh;
|
pSpectCh = pSpectInfoParams->pSpectCh;
|
||||||
for (j = 0; j < (pSpectInfoParams->numSpectChans); j++) {
|
for (j = 0; j < (pSpectInfoParams->numSpectChans); j++) {
|
||||||
sap_debug("Freq = %d weight = %d rssi aggr = %d bss count = %d",
|
sap_debug_rl("Freq = %d weight = %d rssi aggr = %d bss count = %d",
|
||||||
pSpectCh->chan_freq, pSpectCh->weight,
|
pSpectCh->chan_freq, pSpectCh->weight,
|
||||||
pSpectCh->rssiAgr, pSpectCh->bssCount);
|
pSpectCh->rssiAgr, pSpectCh->bssCount);
|
||||||
pSpectCh++;
|
pSpectCh++;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@@ -607,8 +607,8 @@ sap_dfs_is_channel_in_nol_list(struct sap_context *sap_context,
|
|||||||
ch_state = wlan_reg_get_channel_state(pdev, channels[i]);
|
ch_state = wlan_reg_get_channel_state(pdev, channels[i]);
|
||||||
if (CHANNEL_STATE_ENABLE != ch_state &&
|
if (CHANNEL_STATE_ENABLE != ch_state &&
|
||||||
CHANNEL_STATE_DFS != ch_state) {
|
CHANNEL_STATE_DFS != ch_state) {
|
||||||
sap_err("Invalid ch num=%d, ch state=%d",
|
sap_err_rl("Invalid ch num=%d, ch state=%d",
|
||||||
channels[i], ch_state);
|
channels[i], ch_state);
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
} /* loop for bonded channels */
|
} /* loop for bonded channels */
|
||||||
|
Reference in New Issue
Block a user