mirror of
https://github.com/torvalds/linux.git
synced 2024-12-03 09:31:26 +00:00
cpufreq: intel_pstate: Minor cleanup for FRAC_BITS
785ee27
("cpufreq: intel_pstate: Fix limits->max_perf rounding error") hardcodes the value of FRAC_BITS. This patch fixes that minor issue. Fixes:785ee27881
(cpufreq: intel_pstate: Fix limits->max_perf rounding error) Signed-off-by: Prarit Bhargava <prarit@redhat.com> Acked-by: Viresh Kumar <viresh.kumar@linaro.org> Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com>
This commit is contained in:
parent
b5832e4b62
commit
88b7b7c0c2
@ -1123,7 +1123,7 @@ static int intel_pstate_set_policy(struct cpufreq_policy *policy)
|
||||
limits->max_sysfs_pct);
|
||||
limits->max_perf_pct = max(limits->min_policy_pct,
|
||||
limits->max_perf_pct);
|
||||
limits->max_perf = round_up(limits->max_perf, 8);
|
||||
limits->max_perf = round_up(limits->max_perf, FRAC_BITS);
|
||||
|
||||
/* Make sure min_perf_pct <= max_perf_pct */
|
||||
limits->min_perf_pct = min(limits->max_perf_pct, limits->min_perf_pct);
|
||||
|
Loading…
Reference in New Issue
Block a user