Snap for 8535289 from 668ac0483d
to tm-qpr1-release
Change-Id: I00075af57eb3e4cc86736e663b93f719468dcf21
This commit is contained in:
commit
b9cccdea35
3 changed files with 20 additions and 10 deletions
|
@ -374,7 +374,13 @@ on post-fs-data
|
||||||
# Modem replay folder
|
# Modem replay folder
|
||||||
mkdir /mnt/vendor/modem_userdata/replay 0775 radio system
|
mkdir /mnt/vendor/modem_userdata/replay 0775 radio system
|
||||||
|
|
||||||
# Write display MIPI frequency from Modem
|
# Write display frequency config from RadioExt HAL
|
||||||
|
|
||||||
|
# OSC frequency files
|
||||||
|
chown system system /sys/devices/platform/1c2c0000.drmdsim/1c2c0000.drmdsim.0/osc2_clk_khz
|
||||||
|
chmod 0664 /sys/devices/platform/1c2c0000.drmdsim/1c2c0000.drmdsim.0/osc2_clk_khz
|
||||||
|
|
||||||
|
# MIPI frequency files
|
||||||
chown system system /sys/devices/platform/1c2c0000.drmdsim/hs_clock
|
chown system system /sys/devices/platform/1c2c0000.drmdsim/hs_clock
|
||||||
chown system system /sys/devices/platform/1c2d0000.drmdsim/hs_clock
|
chown system system /sys/devices/platform/1c2d0000.drmdsim/hs_clock
|
||||||
chmod 0664 /sys/devices/platform/1c2c0000.drmdsim/hs_clock
|
chmod 0664 /sys/devices/platform/1c2c0000.drmdsim/hs_clock
|
||||||
|
|
|
@ -401,6 +401,8 @@ void Dumpstate::dumpPowerSection(int fd) {
|
||||||
|
|
||||||
if (!PropertiesHelper::IsUserBuild()) {
|
if (!PropertiesHelper::IsUserBuild()) {
|
||||||
DumpFileToFd(fd, "DC_registers dump", "/sys/class/power_supply/pca94xx-mains/device/registers_dump");
|
DumpFileToFd(fd, "DC_registers dump", "/sys/class/power_supply/pca94xx-mains/device/registers_dump");
|
||||||
|
DumpFileToFd(fd, "max77759_chg registers dump", "/d/max77759_chg/registers");
|
||||||
|
DumpFileToFd(fd, "max77729_pmic registers dump", "/d/max77729_pmic/registers");
|
||||||
|
|
||||||
RunCommandToFd(fd, "fg_model", {"/vendor/bin/sh", "-c",
|
RunCommandToFd(fd, "fg_model", {"/vendor/bin/sh", "-c",
|
||||||
"for f in /d/maxfg* ; do "
|
"for f in /d/maxfg* ; do "
|
||||||
|
|
|
@ -16,7 +16,7 @@
|
||||||
|
|
||||||
#include <PowerStatsAidl.h>
|
#include <PowerStatsAidl.h>
|
||||||
#include <Gs201CommonDataProviders.h>
|
#include <Gs201CommonDataProviders.h>
|
||||||
#include <AocStateResidencyDataProvider.h>
|
#include <AocTimedStateResidencyDataProvider.h>
|
||||||
#include <DevfreqStateResidencyDataProvider.h>
|
#include <DevfreqStateResidencyDataProvider.h>
|
||||||
#include <DvfsStateResidencyDataProvider.h>
|
#include <DvfsStateResidencyDataProvider.h>
|
||||||
#include <UfsStateResidencyDataProvider.h>
|
#include <UfsStateResidencyDataProvider.h>
|
||||||
|
@ -32,7 +32,7 @@
|
||||||
#include <android/binder_process.h>
|
#include <android/binder_process.h>
|
||||||
#include <log/log.h>
|
#include <log/log.h>
|
||||||
|
|
||||||
using aidl::android::hardware::power::stats::AocStateResidencyDataProvider;
|
using aidl::android::hardware::power::stats::AocTimedStateResidencyDataProvider;
|
||||||
using aidl::android::hardware::power::stats::DevfreqStateResidencyDataProvider;
|
using aidl::android::hardware::power::stats::DevfreqStateResidencyDataProvider;
|
||||||
using aidl::android::hardware::power::stats::DvfsStateResidencyDataProvider;
|
using aidl::android::hardware::power::stats::DvfsStateResidencyDataProvider;
|
||||||
using aidl::android::hardware::power::stats::UfsStateResidencyDataProvider;
|
using aidl::android::hardware::power::stats::UfsStateResidencyDataProvider;
|
||||||
|
@ -102,6 +102,8 @@ void addPlaceholderEnergyConsumers(std::shared_ptr<PowerStats> p) {
|
||||||
}
|
}
|
||||||
|
|
||||||
void addAoC(std::shared_ptr<PowerStats> p) {
|
void addAoC(std::shared_ptr<PowerStats> p) {
|
||||||
|
// When the given timeout is 0, the timeout will be replaced with "120ms * statesCount".
|
||||||
|
static const uint64_t TIMEOUT_MILLIS = 0;
|
||||||
std::string prefix = "/sys/devices/platform/19000000.aoc/control/";
|
std::string prefix = "/sys/devices/platform/19000000.aoc/control/";
|
||||||
|
|
||||||
// Add AoC cores (a32, ff1, hf0, and hf1)
|
// Add AoC cores (a32, ff1, hf0, and hf1)
|
||||||
|
@ -113,8 +115,8 @@ void addAoC(std::shared_ptr<PowerStats> p) {
|
||||||
};
|
};
|
||||||
std::vector<std::pair<std::string, std::string>> coreStates = {
|
std::vector<std::pair<std::string, std::string>> coreStates = {
|
||||||
{"DWN", "off"}, {"RET", "retention"}, {"WFI", "wfi"}};
|
{"DWN", "off"}, {"RET", "retention"}, {"WFI", "wfi"}};
|
||||||
p->addStateResidencyDataProvider(std::make_unique<AocStateResidencyDataProvider>(coreIds,
|
p->addStateResidencyDataProvider(std::make_unique<AocTimedStateResidencyDataProvider>(coreIds,
|
||||||
coreStates));
|
coreStates, TIMEOUT_MILLIS));
|
||||||
|
|
||||||
// Add AoC voltage stats
|
// Add AoC voltage stats
|
||||||
std::vector<std::pair<std::string, std::string>> voltageIds = {
|
std::vector<std::pair<std::string, std::string>> voltageIds = {
|
||||||
|
@ -125,7 +127,8 @@ void addAoC(std::shared_ptr<PowerStats> p) {
|
||||||
{"UUD", "ultra_underdrive"},
|
{"UUD", "ultra_underdrive"},
|
||||||
{"UD", "underdrive"}};
|
{"UD", "underdrive"}};
|
||||||
p->addStateResidencyDataProvider(
|
p->addStateResidencyDataProvider(
|
||||||
std::make_unique<AocStateResidencyDataProvider>(voltageIds, voltageStates));
|
std::make_unique<AocTimedStateResidencyDataProvider>(voltageIds, voltageStates,
|
||||||
|
TIMEOUT_MILLIS));
|
||||||
|
|
||||||
// Add AoC monitor mode
|
// Add AoC monitor mode
|
||||||
std::vector<std::pair<std::string, std::string>> monitorIds = {
|
std::vector<std::pair<std::string, std::string>> monitorIds = {
|
||||||
|
@ -135,7 +138,8 @@ void addAoC(std::shared_ptr<PowerStats> p) {
|
||||||
{"MON", "mode"},
|
{"MON", "mode"},
|
||||||
};
|
};
|
||||||
p->addStateResidencyDataProvider(
|
p->addStateResidencyDataProvider(
|
||||||
std::make_unique<AocStateResidencyDataProvider>(monitorIds, monitorStates));
|
std::make_unique<AocTimedStateResidencyDataProvider>(monitorIds, monitorStates,
|
||||||
|
TIMEOUT_MILLIS));
|
||||||
|
|
||||||
// Add AoC restart count
|
// Add AoC restart count
|
||||||
const GenericStateResidencyDataProvider::StateResidencyConfig restartCountConfig = {
|
const GenericStateResidencyDataProvider::StateResidencyConfig restartCountConfig = {
|
||||||
|
@ -642,9 +646,7 @@ void addGs201CommonDataProviders(std::shared_ptr<PowerStats> p) {
|
||||||
setEnergyMeter(p);
|
setEnergyMeter(p);
|
||||||
|
|
||||||
addPixelStateResidencyDataProvider(p);
|
addPixelStateResidencyDataProvider(p);
|
||||||
// TODO(b/220032540): Re-enable AoC reporting when AoC long latency issue is fixed or
|
addAoC(p);
|
||||||
// the timeout mechanism is merged.
|
|
||||||
//addAoC(p);
|
|
||||||
addDvfsStats(p);
|
addDvfsStats(p);
|
||||||
addSoC(p);
|
addSoC(p);
|
||||||
addCPUclusters(p);
|
addCPUclusters(p);
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue