aboutsummaryrefslogtreecommitdiffstats
path: root/cputemp2maxfreq.c
diff options
context:
space:
mode:
authorPA4WDH2024-10-09 12:18:23 +0200
committerPA4WDH2024-10-09 12:18:23 +0200
commit9586b59606edcf3538428c16680a2a6eb2d7969d (patch)
treed425b3eb3b3fbd6996c1a0a645ba91498d0e4d50 /cputemp2maxfreq.c
parentRead scaling_max_freq every poll interval (diff)
downloadcputemp2maxfreq-0.7.tar.gz
cputemp2maxfreq-0.7.tar.bz2
cputemp2maxfreq-0.7.zip
Rename config.max_freq to config.target_freq and make texts consistent with that0.7
Diffstat (limited to 'cputemp2maxfreq.c')
-rw-r--r--cputemp2maxfreq.c10
1 files changed, 5 insertions, 5 deletions
diff --git a/cputemp2maxfreq.c b/cputemp2maxfreq.c
index 81fcdef..f4a9c51 100644
--- a/cputemp2maxfreq.c
+++ b/cputemp2maxfreq.c
@@ -37,7 +37,7 @@
struct s_config config={
.name="", // Name of this program, set by argparse
.governor="conservative", // Governor
- .max_temp=70000, // Temperature
+ .target_temp=70000, // Target temperature
.temp_input="auto", // Temperature input
.freq_step=100000, // Frequency step
.fallback_freq=2000000, // Fallback frequency
@@ -100,7 +100,7 @@ int main(int argc,char **argv)
// Log configuration
config.logger("Configuration:");
config.logger("Governor: %s",config.governor);
- config.logger("Temperature: %ld",config.max_temp);
+ config.logger("Target temperature: %ld",config.target_temp);
config.logger("Temp input: %s",config.temp_input);
config.logger("Frequency step: %ld",config.freq_step);
config.logger("Fallback frquency: %ld",config.fallback_freq);
@@ -134,7 +134,7 @@ int main(int argc,char **argv)
config.logger("Physical CPU to change: %d",config.cpu);
}
- if ((config.max_temp<VALID_TEMP_MIN) || (config.max_temp>VALID_TEMP_MAX))
+ if ((config.target_temp<VALID_TEMP_MIN) || (config.target_temp>VALID_TEMP_MAX))
{
config.logger("Invalid temperature, range is %d-%d",VALID_TEMP_MIN,VALID_TEMP_MAX);
exit(1);
@@ -297,14 +297,14 @@ int main(int argc,char **argv)
failsafe(1);
}
- DEBUG1_MAIN("Data: %ld %ld %ld %ld %ld\n",cpudata.cur_temp,config.max_temp,cpudata.max_freq,cpudata.scale_max,cpudata.cur_freq);
+ DEBUG1_MAIN("Data: %ld %ld %ld %ld %ld\n",cpudata.cur_temp,config.target_temp,cpudata.max_freq,cpudata.scale_max,cpudata.cur_freq);
if (config.log_data>0)
{
config.logger("CPU Temperature: %ld, CPU Frequency: %ld",cpudata.cur_temp/1000,cpudata.cur_freq);
}
if (config.csvfile!=NULL) csvlog_write();
- diff=config.max_temp-cpudata.cur_temp;
+ diff=config.target_temp-cpudata.cur_temp;
// Check if we should increase
if ((diff>=1000) && (cpudata.scale_max<cpudata.max_freq))