diff options
author | Todd Poynor <toddpoynor@google.com> | 2012-05-10 23:28:06 -0700 |
---|---|---|
committer | Todd Poynor <toddpoynor@google.com> | 2012-05-10 23:35:45 -0700 |
commit | c12914672a97c8a6c3800d52a5c40ac06878d6db (patch) | |
tree | 292d8d0699328a05107c1c568945e3ce2c62866a /drivers/cpufreq | |
parent | ba43e9be0c7ebac9fee9376ec6e532ea79e8081b (diff) | |
download | kernel_samsung_aries-c12914672a97c8a6c3800d52a5c40ac06878d6db.zip kernel_samsung_aries-c12914672a97c8a6c3800d52a5c40ac06878d6db.tar.gz kernel_samsung_aries-c12914672a97c8a6c3800d52a5c40ac06878d6db.tar.bz2 |
cpufreq: interactive: restart above_hispeed_delay at each hispeed load
Change-Id: I2e5b91d45e8806b0ab94ca2301ed671c9af9ab13
Signed-off-by: Todd Poynor <toddpoynor@google.com>
Diffstat (limited to 'drivers/cpufreq')
-rw-r--r-- | drivers/cpufreq/cpufreq_interactive.c | 9 |
1 files changed, 8 insertions, 1 deletions
diff --git a/drivers/cpufreq/cpufreq_interactive.c b/drivers/cpufreq/cpufreq_interactive.c index 7e17725..7dbacf0 100644 --- a/drivers/cpufreq/cpufreq_interactive.c +++ b/drivers/cpufreq/cpufreq_interactive.c @@ -50,6 +50,7 @@ struct cpufreq_interactive_cpuinfo { unsigned int target_freq; unsigned int floor_freq; u64 floor_validate_time; + u64 hispeed_validate_time; int governor_enabled; }; @@ -207,7 +208,7 @@ static void cpufreq_interactive_timer(unsigned long data) if (pcpu->target_freq == hispeed_freq && new_freq > hispeed_freq && cputime64_sub(pcpu->timer_run_time, - pcpu->target_set_time) + pcpu->hispeed_validate_time) < above_hispeed_delay_val) { trace_cpufreq_interactive_notyet(data, cpu_load, pcpu->target_freq, @@ -219,6 +220,9 @@ static void cpufreq_interactive_timer(unsigned long data) new_freq = pcpu->policy->max * cpu_load / 100; } + if (new_freq <= hispeed_freq) + pcpu->hispeed_validate_time = pcpu->timer_run_time; + if (cpufreq_frequency_table_target(pcpu->policy, pcpu->freq_table, new_freq, CPUFREQ_RELATION_H, &index)) { @@ -507,6 +511,7 @@ static void cpufreq_interactive_boost(void) cpumask_set_cpu(i, &up_cpumask); pcpu->target_set_time_in_idle = get_cpu_idle_time_us(i, &pcpu->target_set_time); + pcpu->hispeed_validate_time = pcpu->target_set_time; anyboost = 1; } @@ -840,6 +845,8 @@ static int cpufreq_governor_interactive(struct cpufreq_policy *policy, pcpu->floor_freq = pcpu->target_freq; pcpu->floor_validate_time = pcpu->target_set_time; + pcpu->hispeed_validate_time = + pcpu->target_set_time; pcpu->governor_enabled = 1; smp_wmb(); } |