Move modem dump log to gs-common
Bug: 240530709 Test: adb bugreport and the following file got to dumpstate_board.bin: extended_log_uim.txt extended_log_os.txt nv_normal.bin nv_protected.bin Change-Id: I4994cdef97805aa54dbf54b218beea796a6b7969
This commit is contained in:
parent
a759a55943
commit
e305d69c78
2 changed files with 0 additions and 24 deletions
|
@ -29,7 +29,6 @@
|
||||||
|
|
||||||
#include "DumpstateUtil.h"
|
#include "DumpstateUtil.h"
|
||||||
|
|
||||||
#define MODEM_EXTENDED_LOG_DIRECTORY "/data/vendor/radio/extended_logs"
|
|
||||||
#define RIL_LOG_DIRECTORY "/data/vendor/radio"
|
#define RIL_LOG_DIRECTORY "/data/vendor/radio"
|
||||||
#define RIL_LOG_DIRECTORY_PROPERTY "persist.vendor.ril.log.base_dir"
|
#define RIL_LOG_DIRECTORY_PROPERTY "persist.vendor.ril.log.base_dir"
|
||||||
#define RIL_LOG_NUMBER_PROPERTY "persist.vendor.ril.log.num_file"
|
#define RIL_LOG_NUMBER_PROPERTY "persist.vendor.ril.log.num_file"
|
||||||
|
@ -56,7 +55,6 @@ namespace hardware {
|
||||||
namespace dumpstate {
|
namespace dumpstate {
|
||||||
|
|
||||||
#define MODEM_LOG_PREFIX "sbuff_"
|
#define MODEM_LOG_PREFIX "sbuff_"
|
||||||
#define EXTENDED_LOG_PREFIX "extended_log_"
|
|
||||||
#define RIL_LOG_PREFIX "rild.log."
|
#define RIL_LOG_PREFIX "rild.log."
|
||||||
#define BUFSIZE 65536
|
#define BUFSIZE 65536
|
||||||
#define TCPDUMP_LOG_PREFIX "tcpdump"
|
#define TCPDUMP_LOG_PREFIX "tcpdump"
|
||||||
|
@ -169,19 +167,6 @@ void dumpNetmgrLogs(std::string destDir) {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
/** Dumps last synced NV data into bugreports */
|
|
||||||
void dumpModemEFS(std::string destDir) {
|
|
||||||
const std::string EFS_DIRECTORY = "/mnt/vendor/efs/";
|
|
||||||
const std::vector <std::string> nv_files
|
|
||||||
{
|
|
||||||
EFS_DIRECTORY+"nv_normal.bin",
|
|
||||||
EFS_DIRECTORY+"nv_protected.bin",
|
|
||||||
};
|
|
||||||
for (const auto& logFile : nv_files) {
|
|
||||||
copyFile(logFile, destDir + "/" + basename(logFile.c_str()));
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
timepoint_t startSection(int fd, const std::string §ionName) {
|
timepoint_t startSection(int fd, const std::string §ionName) {
|
||||||
::android::base::WriteStringToFd(
|
::android::base::WriteStringToFd(
|
||||||
"\n"
|
"\n"
|
||||||
|
@ -207,7 +192,6 @@ Dumpstate::Dumpstate()
|
||||||
{ "display", [this](int fd) { dumpDisplaySection(fd); } },
|
{ "display", [this](int fd) { dumpDisplaySection(fd); } },
|
||||||
},
|
},
|
||||||
mLogSections{
|
mLogSections{
|
||||||
{ "modem", [this](int fd, const std::string &destDir) { dumpModemLogs(fd, destDir); } },
|
|
||||||
{ "radio", [this](int fd, const std::string &destDir) { dumpRadioLogs(fd, destDir); } },
|
{ "radio", [this](int fd, const std::string &destDir) { dumpRadioLogs(fd, destDir); } },
|
||||||
{ "camera", [this](int fd, const std::string &destDir) { dumpCameraLogs(fd, destDir); } },
|
{ "camera", [this](int fd, const std::string &destDir) { dumpCameraLogs(fd, destDir); } },
|
||||||
} {
|
} {
|
||||||
|
@ -301,13 +285,6 @@ void Dumpstate::dumpDisplaySection(int fd) {
|
||||||
DumpFileToFd(fd, "Secondary panel extra info", "/sys/devices/platform/exynos-drm/secondary-panel/panel_extinfo");
|
DumpFileToFd(fd, "Secondary panel extra info", "/sys/devices/platform/exynos-drm/secondary-panel/panel_extinfo");
|
||||||
}
|
}
|
||||||
|
|
||||||
void Dumpstate::dumpModemLogs(int fd, const std::string &destDir) {
|
|
||||||
std::string extendedLogDir = MODEM_EXTENDED_LOG_DIRECTORY;
|
|
||||||
|
|
||||||
dumpLogs(fd, extendedLogDir, destDir, 20, EXTENDED_LOG_PREFIX);
|
|
||||||
dumpModemEFS(destDir);
|
|
||||||
}
|
|
||||||
|
|
||||||
void Dumpstate::dumpRadioLogs(int fd, const std::string &destDir) {
|
void Dumpstate::dumpRadioLogs(int fd, const std::string &destDir) {
|
||||||
std::string tcpdumpLogDir = TCPDUMP_LOG_DIRECTORY;
|
std::string tcpdumpLogDir = TCPDUMP_LOG_DIRECTORY;
|
||||||
bool tcpdumpEnabled = ::android::base::GetBoolProperty(TCPDUMP_PERSIST_PROPERTY, false);
|
bool tcpdumpEnabled = ::android::base::GetBoolProperty(TCPDUMP_PERSIST_PROPERTY, false);
|
||||||
|
|
|
@ -57,7 +57,6 @@ class Dumpstate : public BnDumpstateDevice {
|
||||||
void dumpLogSection(int fd, int fdModem);
|
void dumpLogSection(int fd, int fdModem);
|
||||||
|
|
||||||
// Log sections to be dumped individually into dumpstate_board.bin
|
// Log sections to be dumped individually into dumpstate_board.bin
|
||||||
void dumpModemLogs(int fd, const std::string &destDir);
|
|
||||||
void dumpRadioLogs(int fd, const std::string &destDir);
|
void dumpRadioLogs(int fd, const std::string &destDir);
|
||||||
void dumpCameraLogs(int fd, const std::string &destDir);
|
void dumpCameraLogs(int fd, const std::string &destDir);
|
||||||
|
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue