summaryrefslogtreecommitdiff
path: root/drivers/rmnet/shs/rmnet_shs_wq.c
diff options
context:
space:
mode:
authorChinmay Agarwal <chinagar@codeaurora.org>2019-11-27 01:16:36 +0530
committerGerrit - the friendly Code Review server <code-review@localhost>2019-11-27 10:05:17 -0800
commit7d0c0a3a5cec1dbda36c10cca14b5c33e3acbc11 (patch)
tree01d00e991fb6a69031054f8658737320157a297d /drivers/rmnet/shs/rmnet_shs_wq.c
parent7f36751352721ee10a919b61c7480b0299645856 (diff)
downloaddata-kernel-7d0c0a3a5cec1dbda36c10cca14b5c33e3acbc11.tar.gz
data-kernel: rmnet: shs: Fix Errors Reported during Static Analysis.
Set the weights to be used in calculating "avg_pps", when the flow is executing on the Perf CPU's in function "rmnet_shs_wq_get_flow_avg_pps". Change-Id: Ia50db34a348c068a9b1bf3171fced858ce0a62de Signed-off-by: Chinmay Agarwal <chinagar@codeaurora.org>
Diffstat (limited to 'drivers/rmnet/shs/rmnet_shs_wq.c')
-rw-r--r--drivers/rmnet/shs/rmnet_shs_wq.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/drivers/rmnet/shs/rmnet_shs_wq.c b/drivers/rmnet/shs/rmnet_shs_wq.c
index 298058c..60653bf 100644
--- a/drivers/rmnet/shs/rmnet_shs_wq.c
+++ b/drivers/rmnet/shs/rmnet_shs_wq.c
@@ -455,6 +455,9 @@ static u64 rmnet_shs_wq_get_flow_avg_pps(struct rmnet_shs_wq_hstat_s *hnode)
/* More weight to current value */
new_weight = rmnet_shs_wq_tuning;
old_weight = 100 - rmnet_shs_wq_tuning;
+ } else {
+ old_weight = rmnet_shs_wq_tuning;
+ new_weight = 100 - rmnet_shs_wq_tuning;
}
/* computing weighted average per flow, if the flow has just started,