Searched hist:ce1bcfe94db895cbd6876e176af5824742b29e25 (Results 1 – 1 of 1) sorted by relevance
/openbmc/linux/drivers/cpufreq/ |
H A D | cpufreq.c | diff ce1bcfe94db895cbd6876e176af5824742b29e25 Fri Jan 02 01:04:35 CST 2015 Viresh Kumar <viresh.kumar@linaro.org> cpufreq: check cpufreq_policy_list instead of scanning policies for all CPUs
CPUFREQ_STICKY flag is set by drivers which don't want to get unregistered even if cpufreq-core isn't able to initialize policy for any CPU.
When this flag isn't set, we try to unregister the driver. To find out which CPUs are registered and which are not, we try to check per_cpu cpufreq_cpu_data for all CPUs. Because we have a list of valid policies available now, we better check if the list is empty or not instead of the 'for' loop. That will be much more efficient.
Signed-off-by: Viresh Kumar <viresh.kumar@linaro.org> Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com>
|