diff --git a/device.mk b/device.mk index bb93cedc..9cb81a9a 100644 --- a/device.mk +++ b/device.mk @@ -18,6 +18,7 @@ include device/google/gs-common/device.mk include device/google/gs-common/gs_watchdogd/watchdog.mk include device/google/gs-common/ramdump/ramdump.mk include device/google/gs-common/soc/soc.mk +include device/google/gs-common/soc/freq.mk include device/google/gs-common/modem/modem.mk include device/google/gs-common/aoc/aoc.mk include device/google/gs-common/thermal/thermal.mk diff --git a/dumpstate/Dumpstate.cpp b/dumpstate/Dumpstate.cpp index f1fb809b..6869d2e8 100644 --- a/dumpstate/Dumpstate.cpp +++ b/dumpstate/Dumpstate.cpp @@ -193,8 +193,6 @@ void endSection(int fd, const std::string §ionName, timepoint_t startTime) { Dumpstate::Dumpstate() : mTextSections{ { "wlan", [this](int fd) { dumpWlanSection(fd); } }, - { "memory", [this](int fd) { dumpMemorySection(fd); } }, - { "Devfreq", [this](int fd) { dumpDevfreqSection(fd); } }, { "power", [this](int fd) { dumpPowerSection(fd); } }, { "pixel-trace", [this](int fd) { dumpPixelTraceSection(fd); } }, }, @@ -474,38 +472,6 @@ void Dumpstate::dumpPowerSection(int fd) { } -// Dump items related to Devfreq & BTS -void Dumpstate::dumpDevfreqSection(int fd) { - DumpFileToFd(fd, "MIF DVFS", - "/sys/devices/platform/17000010.devfreq_mif/devfreq/17000010.devfreq_mif/time_in_state"); - DumpFileToFd(fd, "INT DVFS", - "/sys/devices/platform/17000020.devfreq_int/devfreq/17000020.devfreq_int/time_in_state"); - DumpFileToFd(fd, "INTCAM DVFS", - "/sys/devices/platform/17000030.devfreq_intcam/devfreq/17000030.devfreq_intcam/time_in_state"); - DumpFileToFd(fd, "DISP DVFS", - "/sys/devices/platform/17000040.devfreq_disp/devfreq/17000040.devfreq_disp/time_in_state"); - DumpFileToFd(fd, "CAM DVFS", - "/sys/devices/platform/17000050.devfreq_cam/devfreq/17000050.devfreq_cam/time_in_state"); - DumpFileToFd(fd, "TNR DVFS", - "/sys/devices/platform/17000060.devfreq_tnr/devfreq/17000060.devfreq_tnr/time_in_state"); - DumpFileToFd(fd, "MFC DVFS", - "/sys/devices/platform/17000070.devfreq_mfc/devfreq/17000070.devfreq_mfc/time_in_state"); - DumpFileToFd(fd, "BO DVFS", - "/sys/devices/platform/17000080.devfreq_bo/devfreq/17000080.devfreq_bo/time_in_state"); - DumpFileToFd(fd, "BTS stats", "/sys/devices/platform/exynos-bts/bts_stats"); -} - -// Dump items related to memory -void Dumpstate::dumpMemorySection(int fd) { - RunCommandToFd(fd, "CMA info", {"/vendor/bin/sh", "-c", - "for d in $(ls -d /d/cma/*); do " - "echo --- $d;" - "echo --- count; cat $d/count; " - "echo --- used; cat $d/used; " - "echo --- bitmap; cat $d/bitmap; " - "done"}); -} - void Dumpstate::dumpRadioLogs(int fd, const std::string &destDir) { std::string tcpdumpLogDir = TCPDUMP_LOG_DIRECTORY; bool tcpdumpEnabled = ::android::base::GetBoolProperty(TCPDUMP_PERSIST_PROPERTY, false); @@ -632,6 +598,7 @@ ndk::ScopedAStatus Dumpstate::dumpstateBoard(const std::vector<::ndk::ScopedFile ATRACE_BEGIN("dumpstateBoard"); // Unused arguments. (void) in_timeoutMillis; + (void) in_mode; if (in_fds.size() < 1) { ALOGE("no FDs\n"); @@ -646,17 +613,6 @@ ndk::ScopedAStatus Dumpstate::dumpstateBoard(const std::vector<::ndk::ScopedFile "Invalid file descriptor"); } - if (in_mode == IDumpstateDevice::DumpstateMode::WEAR) { - // We aren't a Wear device. - ALOGE("Unsupported mode: %d\n", in_mode); - return ndk::ScopedAStatus::fromServiceSpecificErrorWithMessage(ERROR_UNSUPPORTED_MODE, - "Unsupported mode"); - } else if (in_mode < IDumpstateDevice::DumpstateMode::FULL || in_mode > IDumpstateDevice::DumpstateMode::PROTO) { - ALOGE("Invalid mode: %d\n", in_mode); - return ndk::ScopedAStatus::fromExceptionCodeWithMessage(EX_ILLEGAL_ARGUMENT, - "Invalid mode"); - } - if (in_fds.size() < 2) { ALOGE("no FD for dumpstate_board binary\n"); } else { diff --git a/dumpstate/Dumpstate.h b/dumpstate/Dumpstate.h index a23b346d..6c349703 100644 --- a/dumpstate/Dumpstate.h +++ b/dumpstate/Dumpstate.h @@ -54,8 +54,6 @@ class Dumpstate : public BnDumpstateDevice { // addition to being included in full dumps void dumpWlanSection(int fd); void dumpPowerSection(int fd); - void dumpDevfreqSection(int fd); - void dumpMemorySection(int fd); void dumpPixelTraceSection(int fd); void dumpLogSection(int fd, int fdModem);