From: Todd Poynor Date: Tue, 7 Aug 2012 01:18:31 +0000 (-0700) Subject: power: android_battery: nn.n temperature format for /d/android-power X-Git-Tag: firefly_0821_release~4090^2~692 X-Git-Url: http://demsky.eecs.uci.edu/git/?a=commitdiff_plain;h=4e792812de2ee29bbd9cf21f88f0b617aa79cff6;p=firefly-linux-kernel-4.4.55.git power: android_battery: nn.n temperature format for /d/android-power Change-Id: I0c20effcadd3c0673d04be190133883b3c2bf599 Signed-off-by: Todd Poynor --- diff --git a/drivers/power/android_battery.c b/drivers/power/android_battery.c index 80c0bd228aa2..a9708561eaf8 100644 --- a/drivers/power/android_battery.c +++ b/drivers/power/android_battery.c @@ -359,9 +359,10 @@ static int android_power_debug_dump(struct seq_file *s, void *unused) struct android_bat_data *battery = s->private; android_bat_update_data(battery); - seq_printf(s, "l=%d v=%d c=%d temp=%d h=%d st=%d type=%s\n", + seq_printf(s, "l=%d v=%d c=%d temp=%s%ld.%ld h=%d st=%d type=%s\n", battery->batt_soc, battery->batt_vcell/1000, - battery->batt_current, battery->batt_temp, + battery->batt_current, battery->batt_temp < 0 ? "-" : "", + abs(battery->batt_temp / 10), abs(battery->batt_temp % 10), battery->batt_health, battery->charging_status, charge_source_str(battery->charge_source));