PD#166793: code defects in thermal part
Change-Id: Icd970eced2ed3bcd76a8baf15bf7b885d63d8d6a
Signed-off-by: zhiqiang.liang <zhiqiang.liang@amlogic.com>
struct thermal_zone_device *tz,
enum thermal_trip_type type)
{
- unsigned long cur_state, ins_upper;
+ unsigned long ins_upper;
+ long cur_state;
long upper = -1;
int i;
pr_debug("state=%ld,gpufreq_device->gpufreq_state=%d\n",
state, gpufreq_device->gpufreq_state);
- if (state >= 0 && state <= max_state) {
+ if (state <= max_state) {
if (gpufreq_device->set_gpu_freq_idx)
gpufreq_device->set_gpu_freq_idx((unsigned int)state);
}
struct thermal_zone_device *tz,
enum thermal_trip_type type)
{
- unsigned long cur_state, ins_upper;
+ unsigned long ins_upper;
+ long cur_state;
long upper = -1;
int i;