From c9a60c3497f4bab4bc86c53376a11799d0184f70 Mon Sep 17 00:00:00 2001 From: Adam Shih Date: Mon, 13 Feb 2023 11:56:39 +0800 Subject: [PATCH] Move led dump to tablet only Bug: 240530709 Test: adb bugreport Change-Id: I41ab1c21462a2efcdfe2eae0f9aab4ccaa52bbb6 --- dumpstate/Dumpstate.cpp | 16 ---------------- dumpstate/Dumpstate.h | 1 - 2 files changed, 17 deletions(-) diff --git a/dumpstate/Dumpstate.cpp b/dumpstate/Dumpstate.cpp index efa9e254..5131d434 100644 --- a/dumpstate/Dumpstate.cpp +++ b/dumpstate/Dumpstate.cpp @@ -218,7 +218,6 @@ Dumpstate::Dumpstate() { "Devfreq", [this](int fd) { dumpDevfreqSection(fd); } }, { "power", [this](int fd) { dumpPowerSection(fd); } }, { "display", [this](int fd) { dumpDisplaySection(fd); } }, - { "led", [this](int fd) { dumpLEDSection(fd); } }, { "pixel-trace", [this](int fd) { dumpPixelTraceSection(fd); } }, }, mLogSections{ @@ -585,21 +584,6 @@ void Dumpstate::dumpDisplaySection(int fd) { } } -// Dump items related to LED -void Dumpstate::dumpLEDSection(int fd) { - struct stat buffer; - - if (!PropertiesHelper::IsUserBuild()) { - if (!stat("/sys/class/leds/green", &buffer)) { - DumpFileToFd(fd, "Green LED Brightness", "/sys/class/leds/green/brightness"); - DumpFileToFd(fd, "Green LED Max Brightness", "/sys/class/leds/green/max_brightness"); - } - if (!stat("/mnt/vendor/persist/led/led_calibration_LUT.txt", &buffer)) { - DumpFileToFd(fd, "LED Calibration Data", "/mnt/vendor/persist/led/led_calibration_LUT.txt"); - } - } -} - void Dumpstate::dumpModemLogs(int fd, const std::string &destDir) { std::string extendedLogDir = MODEM_EXTENDED_LOG_DIRECTORY; std::string modemLogHistoryDir = MODEM_LOG_HISTORY_DIRECTORY; diff --git a/dumpstate/Dumpstate.h b/dumpstate/Dumpstate.h index 75079e31..a91ef13c 100644 --- a/dumpstate/Dumpstate.h +++ b/dumpstate/Dumpstate.h @@ -57,7 +57,6 @@ class Dumpstate : public BnDumpstateDevice { void dumpDevfreqSection(int fd); void dumpMemorySection(int fd); void dumpDisplaySection(int fd); - void dumpLEDSection(int fd); void dumpPixelTraceSection(int fd); void dumpLogSection(int fd, int fdModem);