Skip to content

Commit

Permalink
cpufreq: Simplify cpufreq_can_do_remote_dvfs()
Browse files Browse the repository at this point in the history
The if () in cpufreq_can_do_remote_dvfs() is superfluous, so drop
it and simply return the value of the expression under it.

Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com>
Acked-by: Viresh Kumar <viresh.kumar@linaro.org>
Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com>
  • Loading branch information
Rafael J. Wysocki committed Aug 8, 2017
1 parent 99d14d0 commit d6344d4
Showing 1 changed file with 2 additions and 5 deletions.
7 changes: 2 additions & 5 deletions include/linux/cpufreq.h
Original file line number Diff line number Diff line change
Expand Up @@ -578,11 +578,8 @@ static inline bool cpufreq_can_do_remote_dvfs(struct cpufreq_policy *policy)
* - dvfs_possible_from_any_cpu flag is set
* - the local and remote CPUs share cpufreq policy
*/
if (policy->dvfs_possible_from_any_cpu ||
cpumask_test_cpu(smp_processor_id(), policy->cpus))
return true;

return false;
return policy->dvfs_possible_from_any_cpu ||
cpumask_test_cpu(smp_processor_id(), policy->cpus);
}

/*********************************************************************
Expand Down

0 comments on commit d6344d4

Please sign in to comment.