aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMike Chan <mike@android.com>2008-12-04 15:19:17 -0500
committerDave Jones <davej@redhat.com>2008-12-05 15:20:11 -0500
commit187d9f4ed4fc089f1f25a875fb485e27626972f9 (patch)
tree321746d8966250b00698361dfc1cadeec8d0560f
parent8529154ec3f3ac20344c65b7a040c604c7af7651 (diff)
[CPUFREQ] Fix on resume, now preserves user policy min/max.
Previously driver resume would always set the current policy min/max with the cpuinfo min/max, defined by user_policy.min/max. Resulting in a reset of policy settings when policy.min/max != cpuinfo.min/max when coming out of suspend. Now user_policy is saved as the policy instead of cpuinfo to preserve what the user actually set. Signed-off-by: Mike Chan <mike@android.com> Signed-off-by: Dave Jones <davej@redhat.com>
-rw-r--r--drivers/cpufreq/cpufreq.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/drivers/cpufreq/cpufreq.c b/drivers/cpufreq/cpufreq.c
index 9044b911d8ae..01dde80597f7 100644
--- a/drivers/cpufreq/cpufreq.c
+++ b/drivers/cpufreq/cpufreq.c
@@ -827,8 +827,8 @@ static int cpufreq_add_dev(struct sys_device *sys_dev)
827 dprintk("initialization failed\n"); 827 dprintk("initialization failed\n");
828 goto err_out; 828 goto err_out;
829 } 829 }
830 policy->user_policy.min = policy->cpuinfo.min_freq; 830 policy->user_policy.min = policy->min;
831 policy->user_policy.max = policy->cpuinfo.max_freq; 831 policy->user_policy.max = policy->max;
832 832
833 blocking_notifier_call_chain(&cpufreq_policy_notifier_list, 833 blocking_notifier_call_chain(&cpufreq_policy_notifier_list,
834 CPUFREQ_START, policy); 834 CPUFREQ_START, policy);