cpufreq, intel_pstate, minor cleanup for FRAC_BITS
Subsystems (2)
PATCH 1/1 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.
Cc Srinivas Pandruvada <[email protected]>
Cc Len Brown <[email protected]>
Cc "Rafael J. Wysocki" <[email protected]>
Cc Viresh Kumar <[email protected]>
Signed-off-by Prarit Bhargava <[email protected]>
--- drivers/cpufreq/intel_pstate.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
drivers/cpufreq/intel_pstate.c +1 -1
@@ -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);
Signature · 1 line
1.7.9.3
Quoted 17 lines · Prarit Bhargava
785ee27 ("cpufreq:
intel_pstate: Fixlimits->max_perfrounding error") hardcodes the value ofFRAC_BITS. This patch fixes that minor issue.Cc Srinivas Pandruvada <[email protected]>Cc Len Brown <[email protected]>Cc "Rafael J. Wysocki" <[email protected]>Cc Viresh Kumar <[email protected]>Signed-off-by Prarit Bhargava <[email protected]>--- drivers/cpufreq/intel_pstate.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)drivers/cpufreq/intel_pstate.c +0
-0
drivers/cpufreq/intel_pstate.c static int intel_pstate_set_policy(struct cpufreq_policy *policy) · line 1129
Quoted 8 lines
drivers/cpufreq/intel_pstate.c +1
-1@@ -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);
Acked-by Viresh Kumar <[email protected]>
Signature · 1 line
viresh
Rafael J. Wysocki
AppliedQuoted 8 lines · Prarit Bhargava
785ee27 ("cpufreq:
intel_pstate: Fixlimits->max_perfrounding error") hardcodes the value ofFRAC_BITS. This patch fixes that minor issue.Cc Srinivas Pandruvada <[email protected]>Cc Len Brown <[email protected]>Cc "Rafael J. Wysocki" <[email protected]>Cc Viresh Kumar <[email protected]>Signed-off-by Prarit Bhargava <[email protected]>
Applied, thanks!
Rafael