From: zhangqing Date: Tue, 9 Jun 2015 14:31:06 +0000 (-0700) Subject: rk3x: rmic: rk818: fix the code build warning in rk3288. X-Git-Tag: firefly_0821_release~4057 X-Git-Url: http://demsky.eecs.uci.edu/git/?a=commitdiff_plain;h=a3ba3d67ea73867b2904a9285e1d472451e67aa5;p=firefly-linux-kernel-4.4.55.git rk3x: rmic: rk818: fix the code build warning in rk3288. Signed-off-by: chenjianhong --- diff --git a/drivers/power/rk818_battery.c b/drivers/power/rk818_battery.c index 9982dcae1e9c..07f3300df0e1 100755 --- a/drivers/power/rk818_battery.c +++ b/drivers/power/rk818_battery.c @@ -3085,9 +3085,9 @@ static int rk81x_bat_get_rsoc_trend(struct rk81x_battery *di, int *trend_mult) if (di->s2r && !di->slp_psy_status) di->trend_start_cap = di->remain_capacity; + diff_cap = remain_cap - trend_start_cap; DBG("<%s>. trend_start_cap = %d, diff_cap = %d\n", __func__, trend_start_cap, diff_cap); - diff_cap = remain_cap - trend_start_cap; *trend_mult = abs(diff_cap) / TREND_CAP_DIFF; if (abs(diff_cap) >= TREND_CAP_DIFF) {