From c0f5a7b8820c2ced7ff791b58e880d17b6a3f2a1 Mon Sep 17 00:00:00 2001 From: Rick Yiu Date: Fri, 21 May 2021 16:57:57 +0800 Subject: [PATCH] gs101: dumpstate: Dump vendor group value Dump attributes and tasks for each vendor group. Bug: 172112042 Test: dump successfully Change-Id: I538a88391e4917749689b9ee1cfa00a8fe1049e5 --- dumpstate/DumpstateDevice.cpp | 12 ++++++++++++ 1 file changed, 12 insertions(+) diff --git a/dumpstate/DumpstateDevice.cpp b/dumpstate/DumpstateDevice.cpp index d518e800..9c259afe 100644 --- a/dumpstate/DumpstateDevice.cpp +++ b/dumpstate/DumpstateDevice.cpp @@ -870,6 +870,18 @@ void DumpstateDevice::dumpRamdumpSection(int fd) { // Dump items that don't fit well into any other section void DumpstateDevice::dumpMiscSection(int fd) { RunCommandToFd(fd, "VENDOR PROPERTIES", {"/vendor/bin/getprop"}); + RunCommandToFd(fd, "Vendor task struct value", {"/vendor/bin/sh", "-c", + "for i in ta fg sys sysbg bg cam nnapi; do " + "echo $i:; " + "for j in prefer_high_cap prefer_idle task_spreading uclamp_max uclamp_min; do " + "echo $j: | tr '[\n]' ' '; " + "cat /sys/kernel/vendor_sched/$i'_'$j; " + "done; " + "echo tasks:; " + "cat /proc/vendor_sched/dump_task_group_$i | tr '[\n]' ' '; " + "echo ''; " + "echo ''; " + "done"}); } // Dump items related to GSC