add stress, os_perf_state_minimum, min-os-perf, max-os-perf

This commit is contained in:
Carl Pearson
2019-09-25 12:27:06 -05:00
parent c358f18c22
commit 57bf39bb97
5 changed files with 93 additions and 1 deletions

View File

@@ -40,6 +40,14 @@ Result os_perf_state_maximum(const int cpu) {
#endif
}
Result os_perf_state_minimum(const int cpu) {
#ifdef __linux__
return set_governor(cpu, "powersave");
#else
#error "unsupported platform"
#endif
}
Result set_os_perf_state(const int cpu, OsPerfState state) {
#ifdef __linux__
return set_governor(cpu, state.governor);