Merge "Make ion trace point optional"

am: 22fe9b3c90

Change-Id: Ia7d3fae07dd242eda5337d1f25d0eb1ee95cae9f
This commit is contained in:
Wei Wang 2019-03-29 01:14:34 -07:00 committed by android-build-merger
commit 422c18cc03

View file

@ -30,24 +30,25 @@ using ::android::hardware::atrace::V1_0::TracingCategory;
struct TracingConfig {
std::string description;
// path and if error on failure
std::vector<std::pair<std::string, bool>> paths;
};
// This is a map stores categories and their sysfs paths with required flags
const std::map<std::string, TracingConfig> kTracingMap = {
// gfx
{
"gfx",
{"Graphics",
{{"/sys/kernel/debug/tracing/events/mdss/enable", false},
{"/sys/kernel/debug/tracing/events/sde/enable", false},
{"/sys/kernel/debug/tracing/events/mali_systrace/enable", false}}},
},
{
"ion",
{"ION allocation",
{{"/sys/kernel/debug/tracing/events/kmem/ion_alloc_buffer_start/enable", true}}},
},
// gfx
{
"gfx",
{"Graphics",
{{"/sys/kernel/debug/tracing/events/mdss/enable", false},
{"/sys/kernel/debug/tracing/events/sde/enable", false},
{"/sys/kernel/debug/tracing/events/mali_systrace/enable", false}}},
},
{
"ion",
{"ION allocation",
{{"/sys/kernel/debug/tracing/events/kmem/ion_alloc_buffer_start/enable", false}}},
},
};
// Methods from ::android::hardware::atrace::V1_0::IAtraceDevice follow.