Skip to contentSkip to conversation

tools/thermal: tmon: cleanup function init_thermal_controller

PATCH Anup Limbu 1 participant 1 message Nov 30, 2015 2 messages not in the archive

lore
Share & tools
lore

Anup Limbu

author
#2 lore raw
In reply to a message not in the archive

[email protected] [email protected]

Quoted 63 lines · Anand Moon

Hi Anup,

Quoted 47 lines · Anup Limbu

Replacing return type of function as void from int and removing unused variable ret.

---
 tools/thermal/tmon/pid.c  | 5 +----
 tools/thermal/tmon/tmon.h | 2 +-
 2 files changed, 2 insertions(+), 5 deletions(-)
tools/thermal/tmon/pid.c +1 -4
index fd7e9e9..c034bf3 100644
@@ -63,10 +63,8 @@ static double xk_1, xk_2; /* input temperature x[k-#] */
  *
  * add a flag for tuning PID
  */
-int init_thermal_controller(void)
+void init_thermal_controller(void)
 {
-       int ret = 0;
-
        /* init pid params */
        p_param.ts = ticktime;
        /* TODO: get it from TUI tuning tab */
@@ -76,7 +74,6 @@ int init_thermal_controller(void)
 
        p_param.t_target = target_temp_user;
 
-       return ret;
 }
 
 void controller_reset(void)
tools/thermal/tmon/tmon.h +1 -2
index 9e3c49c..016569d 100644
@@ -139,7 +139,7 @@ struct pid_params {
        double y_k;
 };
 
-extern int init_thermal_controller(void);
+extern void init_thermal_controller(void);
 extern void controller_handler(const double xk, double *yk);
 
 extern struct tmon_platform_data ptdata;
--
Quoted 2 lines

1.9.1

BTW, next time when sending a thermal related change, please cc [email protected], or else the change may got because we usually rely on https://patchwork.kernel.org/project/linux-pm/list/ to review and scrub the patches. :)

---Zhang Rui <[email protected]>

-Anand Moon