summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorKelly Rossmoyer <krossmo@google.com>2018-08-21 18:06:38 -0700
committerKelly Rossmoyer <krossmo@google.com>2018-08-27 18:17:05 -0700
commitfbaa01eb4943f209da63df048a6de21fb84a00a8 (patch)
tree02337c36a27238ce5c07ee471a36fe3cb516eeea
parentcf39b7bcad8c4d099b29ad42c6d524837fe3b2ea (diff)
downloadnative-fbaa01eb4943f209da63df048a6de21fb84a00a8.tar.gz
Add batterystats -c data to telephony bugreports
Telephony bugreports currently capture 'dumpsys batterystats' output, but only in its human-friendly format. While humans may enjoy that format, Historian does not, and fails to properly load telephony bugreports (including those triggered by LowPowerMonitor) as a result. This makes it essentially impossible to use Historian when triaging/ analyzing telephony-style bugreports. To enable Historian processing of telephony bugreports, this change adds the 'checkin' format ("dumpsys batterystats -c") data along with the existing entries. ABT (Android Bug Tool) still doesn't properly list dumpsys sections in its UI even with this change, but I think nothing short of a full, comprehensive dumpsys run will make ABT happy. And that's okay, because all of the text content can still be navigated manually. Bug: 111763716 Test: Triggered telephony bugreports with and without the change on an appropriate device, manually verified that the checkin format data was present with the code change in place, and loaded the bugreport into Historian successfully. Change-Id: Iba434bfd219c627cd3c058e549a627947d9ce501
-rw-r--r--cmds/dumpstate/dumpstate.cpp6
1 files changed, 6 insertions, 0 deletions
diff --git a/cmds/dumpstate/dumpstate.cpp b/cmds/dumpstate/dumpstate.cpp
index 9d897f523d..1d951bed23 100644
--- a/cmds/dumpstate/dumpstate.cpp
+++ b/cmds/dumpstate/dumpstate.cpp
@@ -1537,6 +1537,12 @@ static void DumpstateTelephonyOnly() {
DUMPSYS_COMPONENTS_OPTIONS);
printf("========================================================\n");
+ printf("== Checkins\n");
+ printf("========================================================\n");
+
+ RunDumpsys("CHECKIN BATTERYSTATS", {"batterystats", "-c"});
+
+ printf("========================================================\n");
printf("== dumpstate: done (id %d)\n", ds.id_);
printf("========================================================\n");
}