cpufreq: governors: implement generic policy_is_shared
Implement a generic helper function policy_is_shared() to replace the current dbs_sw_coordinated_cpus() at cpufreq level, so that it can be used by code other than cpufreq governors. Suggested-by: Viresh Kumar <viresh.kumar@linaro.org> Signed-off-by: Fabio Baltieri <fabio.baltieri@linaro.org> Acked-by: Viresh Kumar <viresh.kumar@linaro.org> Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com>
This commit is contained in:

committed by
Rafael J. Wysocki

parent
6f35a65fbb
commit
2624f90c16
@@ -277,7 +277,7 @@ static void od_dbs_timer(struct work_struct *work)
|
||||
struct od_cpu_dbs_info_s *dbs_info =
|
||||
container_of(work, struct od_cpu_dbs_info_s, cdbs.work.work);
|
||||
|
||||
if (dbs_sw_coordinated_cpus(&dbs_info->cdbs)) {
|
||||
if (policy_is_shared(dbs_info->cdbs.cur_policy)) {
|
||||
od_timer_coordinated(dbs_info, dw);
|
||||
} else {
|
||||
mutex_lock(&dbs_info->cdbs.timer_mutex);
|
||||
|
Reference in New Issue
Block a user