Unfortunately, the plugin module of the resource API does not support
timeout feature properly. According to the guide, if the timeout setting
exists, we must not call the resource_clear_cpu_boosting() function.
This patch changes the timeout argument to -1 from the 5000 (milliseconds).
The RESET_ON_FORK flag is also removed.
Change-Id: I390c5ec3dd6f8ae0d5ac87303e1378ba17411f68
Signed-off-by: Hwankyu Jhun <h.jhun@samsung.com>
extern "C" EXPORT int amd_main(int argc, char** argv) {
amd::CPUBoostController::DoBoost(getpid(),
- amd::CPUBoostController::Level::Strong, 10000);
+ amd::CPUBoostController::Level::Strong, -1);
if (Initialize() != 0) {
_E("AMD initialization is failed");
return -1;
};
int ret = resource_set_cpu_boosting(res_pid,
- static_cast<cpu_boosting_level_e>(level), CPU_BOOSTING_RESET_ON_FORK,
- timeout_msec);
+ static_cast<cpu_boosting_level_e>(level),
+ static_cast<cpu_boosting_flag_e>(0), timeout_msec);
if (ret != 0)
_E("resource_set_cpu_boosting() is failed. error: %d", ret);
else