summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorGanesh Kondabattini <ganeshk@qti.qualcomm.com>2016-05-19 17:09:20 +0530
committerAnjaneedevi Kapparapu <akappa@codeaurora.org>2016-05-23 16:09:45 +0530
commit92177239cfdd1fe8c42a23a087ccc8e91c482422 (patch)
treee2ae53c3c37d782d203d6d33581cffdded5172b7
parent11ef0f5811ebcafe42243bb0502c841b3e10c056 (diff)
qcacld-2.0: Fix the bug in populating the ll stats
If ll stats provided by FW has more than one peer then Driver is allocating memory for all the peers but copying stats for only first peer before sending it to upper layer. Fix the issue to copy stats for all the peers. Change-Id: I91b14377acfed6ccdde4315c4796ef1adbfd18c3 CRs-Fixed: 1018539
-rw-r--r--CORE/SERVICES/WMA/wma.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/CORE/SERVICES/WMA/wma.c b/CORE/SERVICES/WMA/wma.c
index 8482ff694fcb..37bd65fba676 100644
--- a/CORE/SERVICES/WMA/wma.c
+++ b/CORE/SERVICES/WMA/wma.c
@@ -4559,7 +4559,7 @@ static int wma_unified_link_peer_stats_event_handler(void *handle,
wmi_rate_stats *rate_stats;
tSirLLStatsResults *link_stats_results;
u_int8_t *results, *t_peer_stats, *t_rate_stats;
- u_int32_t count, num_rates=0;
+ u_int32_t count, num_rates=0, rate_cnt;
u_int32_t next_res_offset, next_peer_offset, next_rate_offset;
size_t peer_info_size, peer_stats_size, rate_stats_size;
size_t link_stats_results_size;
@@ -4647,7 +4647,7 @@ static int wma_unified_link_peer_stats_event_handler(void *handle,
next_res_offset = peer_stats_size;
next_peer_offset = WMI_TLV_HDR_SIZE;
next_rate_offset = WMI_TLV_HDR_SIZE;
- for (count = 0; count < fixed_param->num_peers; count++) {
+ for (rate_cnt = 0; rate_cnt < fixed_param->num_peers; rate_cnt++) {
WMA_LOGD("Peer Info:");
WMA_LOGD("peer_type %u capabilities %u num_rates %u",
peer_stats->peer_type, peer_stats->capabilities,