From 0c5e45b63d22c6efa6f829c617d8f36688e53c5d Mon Sep 17 00:00:00 2001 From: Marek Lindner Date: Sat, 23 Jun 2012 11:46:05 +0200 Subject: [PATCH] batman-adv: fix counter summary length MIME-Version: 1.0 Content-Type: text/plain; charset=utf8 Content-Transfer-Encoding: 8bit Signed-off-by: Marek Lindner Acked-by: Martin Hundebøll Signed-off-by: Antonio Quartulli --- net/batman-adv/main.h | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/net/batman-adv/main.h b/net/batman-adv/main.h index 8193650e549..b8d4ac17f00 100644 --- a/net/batman-adv/main.h +++ b/net/batman-adv/main.h @@ -265,9 +265,8 @@ static inline void batadv_add_counter(struct batadv_priv *bat_priv, size_t idx, static inline uint64_t batadv_sum_counter(struct batadv_priv *bat_priv, size_t idx) { - uint64_t *counters; + uint64_t *counters, sum = 0; int cpu; - int sum = 0; for_each_possible_cpu(cpu) { counters = per_cpu_ptr(bat_priv->bat_counters, cpu); -- 2.20.1