Add UFS health information into board specific dumpstate

Test: Take bugreport
Bug: 66967195
Change-Id: Id635b64f77d4a6fdc1ace2290f89adfdf86514a7
This commit is contained in:
Wei Wang
2017-10-02 14:48:46 -07:00
parent 28ad3b196c
commit 0db0037ca1
5 changed files with 18 additions and 0 deletions

View File

@@ -234,6 +234,7 @@ Return<void> DumpstateDevice::dumpstateBoard(const hidl_handle& handle) {
DumpFileToFd(fd, "UFS model", "/sys/block/sda/device/model");
DumpFileToFd(fd, "UFS rev", "/sys/block/sda/device/rev");
DumpFileToFd(fd, "UFS size", "/sys/block/sda/size");
RunCommandToFd(fd, "UFS health", {"/vendor/bin/sh", "-c", "for f in $(find /sys/kernel/debug/ufshcd0 -type f); do if [[ -r $f && -f $f ]]; then echo --- $f; cat $f; fi; done"});
DumpFileToFd(fd, "INTERRUPTS", "/proc/interrupts");
DumpFileToFd(fd, "RPM Stats", "/d/rpm_stats");
DumpFileToFd(fd, "Power Management Stats", "/d/rpm_master_stats");