Support record-tgid
Bug: 110757800
Test: builds
Change-Id: Id3235995a6bcf3678413fdf97ca4b89a5f0c340c
diff --git a/cmds/atrace/atrace.cpp b/cmds/atrace/atrace.cpp
index bce8b45..507a893 100644
--- a/cmds/atrace/atrace.cpp
+++ b/cmds/atrace/atrace.cpp
@@ -258,6 +258,9 @@
static const char* k_printTgidPath =
"options/print-tgid";
+static const char* k_recordTgidPath =
+ "options/record-tgid";
+
static const char* k_funcgraphAbsTimePath =
"options/funcgraph-abstime";
@@ -523,6 +526,9 @@
if (fileExists(k_printTgidPath)) {
return setKernelOptionEnable(k_printTgidPath, enable);
}
+ if (fileExists(k_recordTgidPath)) {
+ return setKernelOptionEnable(k_recordTgidPath, enable);
+ }
return true;
}