diff options
| author | Wei Wang <wvw@google.com> | 2018-03-19 22:31:14 -0700 |
|---|---|---|
| committer | Wei Wang <wvw@google.com> | 2018-03-20 06:10:01 +0000 |
| commit | c31ff8c3c07cbcd26aa4b84f73cc587731448a97 (patch) | |
| tree | 13ed66be8e33466873b8ccc711fa47e702e48661 /dumpstate | |
| parent | d6956c7708a1ebd25afbbadec4750efd8192208a (diff) | |
b1c1: dumpstate: dump cpuidle for all cores
Bug: 75974794
Test: take BR
Change-Id: Iefb52e369db72621554926e59725b5fa4dc74cd7
Diffstat (limited to 'dumpstate')
| -rwxr-xr-x | dumpstate/DumpstateDevice.cpp | 6 |
1 files changed, 2 insertions, 4 deletions
diff --git a/dumpstate/DumpstateDevice.cpp b/dumpstate/DumpstateDevice.cpp index 9f13a52..0b3fdb1 100755 --- a/dumpstate/DumpstateDevice.cpp +++ b/dumpstate/DumpstateDevice.cpp @@ -275,10 +275,8 @@ Return<void> DumpstateDevice::dumpstateBoard(const hidl_handle& handle) { DumpFileToFd(fd, "dmabuf info", "/d/dma_buf/bufinfo"); RunCommandToFd(fd, "Temperatures", {"/vendor/bin/sh", "-c", "for f in /sys/class/thermal/thermal* ; do type=`cat $f/type` ; temp=`cat $f/temp` ; echo \"$type: $temp\" ; done"}); RunCommandToFd(fd, "Cooling Device Current State", {"/vendor/bin/sh", "-c", "for f in /sys/class/thermal/cooling* ; do type=`cat $f/type` ; temp=`cat $f/cur_state` ; echo \"$type: $temp\" ; done"}); - DumpFileToFd(fd, "cpu0-3 time-in-state", "/sys/devices/system/cpu/cpu0/cpufreq/stats/time_in_state"); - RunCommandToFd(fd, "cpu0-3 cpuidle", {"/vendor/bin/sh", "-c", "for d in $(ls -d /sys/devices/system/cpu/cpu0/cpuidle/state*); do echo \"$d: `cat $d/name` `cat $d/desc` `cat $d/time` `cat $d/usage`\"; done"}); - DumpFileToFd(fd, "cpu4-7 time-in-state", "/sys/devices/system/cpu/cpu4/cpufreq/stats/time_in_state"); - RunCommandToFd(fd, "cpu4-7 cpuidle", {"/vendor/bin/sh", "-c", "for d in $(ls -d /sys/devices/system/cpu/cpu4/cpuidle/state*); do echo \"$d: `cat $d/name` `cat $d/desc` `cat $d/time` `cat $d/usage`\"; done"}); + RunCommandToFd(fd, "CPU time-in-state", {"/vendor/bin/sh", "-c", "for cpu in /sys/devices/system/cpu/cpu*; do f=$cpu/cpufreq/stats/time_in_state; if [ ! -f $f ]; then continue; fi; echo $f:; cat $f; done"}); + RunCommandToFd(fd, "CPU cpuidle", {"/vendor/bin/sh", "-c", "for cpu in /sys/devices/system/cpu/cpu*; do for d in $cpu/cpuidle/state*; do if [ ! -d $d ]; then continue; fi; echo \"$d: `cat $d/name` `cat $d/desc` `cat $d/time` `cat $d/usage`\"; done; done"}); DumpFileToFd(fd, "MDP xlogs", "/data/vendor/display/mdp_xlog"); DumpFileToFd(fd, "TCPM logs", "/d/tcpm/usbpd0"); DumpFileToFd(fd, "PD Engine", "/d/pd_engine/usbpd0"); |
