move sensors dump to gs-common
Bug: 250475720 Test: adb bugreport Change-Id: I500bfba706b74a872d4ba07b9b58efaed015772e
This commit is contained in:
parent
55f224c9e9
commit
95e0d9bdb9
3 changed files with 1 additions and 25 deletions
|
@ -259,7 +259,6 @@ Dumpstate::Dumpstate()
|
|||
{ "thermal", [this](int fd) { dumpThermalSection(fd); } },
|
||||
{ "touch", [this](int fd) { dumpTouchSection(fd); } },
|
||||
{ "display", [this](int fd) { dumpDisplaySection(fd); } },
|
||||
{ "sensors-usf", [this](int fd) { dumpSensorsUSFSection(fd); } },
|
||||
{ "misc", [this](int fd) { dumpMiscSection(fd); } },
|
||||
{ "camera", [this](int fd) { dumpCameraSection(fd); } },
|
||||
} {
|
||||
|
@ -913,28 +912,6 @@ void Dumpstate::dumpDisplaySection(int fd) {
|
|||
}
|
||||
}
|
||||
|
||||
// Dump items related to sensors usf.
|
||||
void Dumpstate::dumpSensorsUSFSection(int fd) {
|
||||
CommandOptions options = CommandOptions::WithTimeout(2).Build();
|
||||
RunCommandToFd(fd, "USF statistics",
|
||||
{"/vendor/bin/sh", "-c", "usf_stats get --all"},
|
||||
options);
|
||||
if (!PropertiesHelper::IsUserBuild()) {
|
||||
// Not a user build, if this is also not a production device dump the USF registry.
|
||||
std::string hwRev = ::android::base::GetProperty(HW_REVISION, "");
|
||||
if (hwRev.find("PROTO") != std::string::npos ||
|
||||
hwRev.find("EVT") != std::string::npos ||
|
||||
hwRev.find("DVT") != std::string::npos) {
|
||||
RunCommandToFd(fd, "USF Registry",
|
||||
{"/vendor/bin/sh", "-c", "usf_reg_edit save -"},
|
||||
options);
|
||||
RunCommandToFd(fd, "USF Last Stat Buffer",
|
||||
{"/vendor/bin/sh", "-c", "cat /data/vendor/sensors/debug/stats.history"},
|
||||
options);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
// Dump items that don't fit well into any other section
|
||||
void Dumpstate::dumpMiscSection(int fd) {
|
||||
RunCommandToFd(fd, "VENDOR PROPERTIES", {"/vendor/bin/getprop"});
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue