drivers: msm_thermal: make thermal throttle temperature threshold user configurable.

Signed-off-by: franciscofranco <franciscofranco.1990@gmail.com>
drivers: thermal: properly limit CPU frequency when the temperature is too hot: if we throttle too much games will lag so we'll only scale down to 1026MHz until the device cools down, then back to 1512MHz again. Added other smaller routine changes to make it work properly.

Signed-off-by: franciscofranco <franciscofranco.1990@gmail.com>
msm8960_tsens: enable all thermal devices

Signed-off-by: Dennis Rassmann <showp1984@gmail.com>
drivers: thermal: fix its behaviour and increase polling time.

Signed-off-by: franciscofranco <franciscofranco.1990@gmail.com>
msm_thermal: scale polling according to temperature, less polling when the device is cool, more polling with its hot. Borrowed idea @motley.

Signed-off-by: franciscofranco <franciscofranco.1990@gmail.com>
msm_thermal: according to @showp1984 the S4-Pro inside of Mako can heat up 20-25ºC in a matter of 250ms if really stressed + ambient heat, so by @showp1984 suggestion lets poll every 250ms if the device is hot so that it maintains the reduced frequency until its cool enough.

Signed-off-by: franciscofranco <franciscofranco.1990@gmail.com>
msm8960_tsens.c: poll faster.

Signed-off-by: franciscofranco <franciscofranco.1990@gmail.com>
msm_thermal: fix the clusterfuck of code with simple routines to check for temperature differences and act accordingly.

Signed-off-by: franciscofranco <franciscofranco.1990@gmail.com>
drivers: thermal: export CPU temp to the userspace every polling rate. Also add another step for throttling if the CPU gets really hot.

Signed-off-by: franciscofranco <franciscofranco.1990@gmail.com>
drivers: thermal: temp already exported here: /sys/devices/virtual/thermal/thermal_zone7/temp

Signed-off-by: franciscofranco <franciscofranco.1990@gmail.com>
thermal: fix extreme throttle step.

Signed-off-by: Francisco Franco <franciscofranco.1990@gmail.com>
cpufreq: interactive: upgrade to Google's latest 3.4

Reference:
https://android.googlesource.com/kernel/common.git/+/android-3.4