Add Winscope report to the bugreport when using continuous mode
When logging window traces in continuous mode the window manager doesn't
continuously save data to disk.
The window traces (continuous or not) have to be present in the bug
report.
Add instruction to dump the window trace during bugreporting.
To activate continuous trace:
- adb shell cmd window tracing continuous true
- adb shell cmd window tracing start
To manually dump window trace:
- adb shell dumpsys window trace
Test: Flash a device. Set continuous mode. Start the trace. Trigger a
bugreport. Check if the zip file contains the a wm_trace.pb under
FS/data/misc/wmtrace
Change-Id: I1af0b3b37e48ba026fa64515d7e330a2ba7663b6
diff --git a/cmds/dumpstate/dumpstate.cpp b/cmds/dumpstate/dumpstate.cpp
index dc3faa0..d3e0b93 100644
--- a/cmds/dumpstate/dumpstate.cpp
+++ b/cmds/dumpstate/dumpstate.cpp
@@ -1331,6 +1331,7 @@
DumpFile("BINDER STATS", "/sys/kernel/debug/binder/stats");
DumpFile("BINDER STATE", "/sys/kernel/debug/binder/state");
+ RunDumpsys("WINSCOPE TRACE", {"window", "trace"});
/* Add window and surface trace files. */
if (!PropertiesHelper::IsUserBuild()) {
ds.AddDir(WMTRACE_DATA_DIR, false);