drivers: misc: fixed therm estimator bug
Joshua Primero [Wed, 4 Jul 2012 02:39:13 +0000 (19:39 -0700)]
Fixed hi and lo limit bug in thermal estimator driver.

bug 1007726

Change-Id: I2be90ca7d875dbed34004b83f070fb5cbd8bc467
Signed-off-by: Joshua Primero <jprimero@nvidia.com>
Reviewed-on: http://git-master/r/113564
Reviewed-by: Automatic_Commit_Validation_User
GVS: Gerrit_Virtual_Submit
Reviewed-by: Sachin Nikam <snikam@nvidia.com>

drivers/misc/therm_est.c

index fde61bc..e67fc66 100644 (file)
@@ -86,7 +86,7 @@ static void therm_est_work_func(struct work_struct *work)
        est->ntemp++;
 
        if (est->callback && ((est->cur_temp >= est->therm_est_hi_limit) ||
-                        (est->cur_temp <= est->therm_est_hi_limit)))
+                        (est->cur_temp <= est->therm_est_lo_limit)))
                est->callback(est->callback_data);
 
        queue_delayed_work(est->workqueue, &est->therm_est_work,