wahoo: power: set cpufreq max first

There is a small chance that canceling Encode hint and enabling launch
at the same time. In this case, CPU max is capped so it need to be
updated first.

This CL will make PowerHAL updates max node first, in favor of boosting
hints, such as launch, camera shot and etc. When these boost hints end,
the performance limiting (power conserving) hint such as encode hint
could fail to set at the beginning but will succeed in the second try in
500ms.

Also change the rc file to let init do not restart PowerHAL when
framework died and there is no active long-lasting hint.

Bug: 67648152
Bug: 62041945
Test: launch camera
Test: kill cameraHAL, powerHAL, system-server
Change-Id: I4a9d8d395dea9f42cf6659c86635852f332f7617
2 files changed