powerstats: add AoC restart count stats am: cce5e9f8b0
Original change: https://googleplex-android-review.googlesource.com/c/device/google/gs101/+/17365283 Change-Id: I3e5830b6a14e797eceb61a8f179358ccee64ee02 Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
This commit is contained in:
commit
67f3dda062
1 changed files with 17 additions and 0 deletions
|
@ -79,6 +79,23 @@ void addAoC(std::shared_ptr<PowerStats> p) {
|
||||||
};
|
};
|
||||||
p->addStateResidencyDataProvider(
|
p->addStateResidencyDataProvider(
|
||||||
std::make_unique<AocStateResidencyDataProvider>(monitorIds, monitorStates));
|
std::make_unique<AocStateResidencyDataProvider>(monitorIds, monitorStates));
|
||||||
|
|
||||||
|
// Add AoC restart count
|
||||||
|
const GenericStateResidencyDataProvider::StateResidencyConfig restartCountConfig = {
|
||||||
|
.entryCountSupported = true,
|
||||||
|
.entryCountPrefix = "",
|
||||||
|
.totalTimeSupported = false,
|
||||||
|
.lastEntrySupported = false,
|
||||||
|
};
|
||||||
|
const std::vector<std::pair<std::string, std::string>> restartCountHeaders = {
|
||||||
|
std::make_pair("RESTART", ""),
|
||||||
|
};
|
||||||
|
std::vector<GenericStateResidencyDataProvider::PowerEntityConfig> cfgs;
|
||||||
|
cfgs.emplace_back(
|
||||||
|
generateGenericStateResidencyConfigs(restartCountConfig, restartCountHeaders),
|
||||||
|
"AoC-Count", "");
|
||||||
|
p->addStateResidencyDataProvider(std::make_unique<GenericStateResidencyDataProvider>(
|
||||||
|
"/sys/devices/platform/19000000.aoc/restart_count", cfgs));
|
||||||
}
|
}
|
||||||
|
|
||||||
void addDvfsStats(std::shared_ptr<PowerStats> p) {
|
void addDvfsStats(std::shared_ptr<PowerStats> p) {
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue