diff options
author | viresh kumar <viresh.kumar@linaro.org> | 2014-03-04 11:43:59 +0800 |
---|---|---|
committer | Rafael J. Wysocki <rafael.j.wysocki@intel.com> | 2014-03-06 14:38:44 +0100 |
commit | 6e2c89d16d987e6e11c531b039a42d3f5f1d7c32 (patch) | |
tree | 99eebd82caf833fba1b904db638946cb3cf44cf6 /init/do_mounts_md.c | |
parent | 3b4aff047275574bff8f50a654d51166d9574079 (diff) | |
download | linux-6e2c89d16d987e6e11c531b039a42d3f5f1d7c32.tar.bz2 |
cpufreq: move call to __find_governor() to cpufreq_init_policy()
We call __find_governor() during the addition of the first CPU of
each policy from __cpufreq_add_dev() to find the last governor used
for this CPU before it was hot-removed.
After that we call cpufreq_parse_governor() in cpufreq_init_policy(),
either with this governor, or with the default governor. Right after
that policy->governor is set to NULL.
While that code is not functionally problematic, the structure of it
is suboptimal, because some of the code required in cpufreq_init_policy()
is being executed by its caller, __cpufreq_add_dev(). So, it would make
more sense to get all of it together in a single place to make code more
readable.
Accordingly, move the code needed for policy initialization to
cpufreq_init_policy() and initialize policy->governor to NULL at the
beginning.
In order to clean up the code a bit more, some of the #ifdefs for
CONFIG_HOTPLUG_CPU are dropped too.
Signed-off-by: Viresh Kumar <viresh.kumar@linaro.org>
[rjw: Changelog]
Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com>
Diffstat (limited to 'init/do_mounts_md.c')
0 files changed, 0 insertions, 0 deletions