Ported cpufreq.c from https://android.googlesource.com/kernel/common.git/+/android-3.0 (Google Common android-3.0 kernel)