diff options
author | Viresh Kumar <viresh.kumar@linaro.org> | 2015-11-21 09:06:49 +0530 |
---|---|---|
committer | Rafael J. Wysocki <rafael.j.wysocki@intel.com> | 2015-11-23 22:49:42 +0100 |
commit | f344dae0fe9f88d3c7ec45f2d7bba84d6ce1ac00 (patch) | |
tree | c2dac58bfd7504fcbf141dc62fb92d9bae04a6ec /fs/gfs2 | |
parent | 3bf7f56e70c9f0edb4f91cbb73a393c3b1d24801 (diff) | |
download | op-kernel-dev-f344dae0fe9f88d3c7ec45f2d7bba84d6ce1ac00.zip op-kernel-dev-f344dae0fe9f88d3c7ec45f2d7bba84d6ce1ac00.tar.gz |
cpufreq: Always remove sysfs cpuX/cpufreq link on ->remove_dev()
Subsys interface's ->remove_dev() is called when the cpufreq driver is
unregistering or the CPU is getting physically removed. We keep removing
the cpuX/cpufreq link for all CPUs except the last one, which is a
mistake as all CPUs contain a link now.
Because of this, one CPU from each policy will still contain a link (to
an already removed policyX directory), after the cpufreq driver is
unregistered.
Fix that by removing the link first and then only see if the policy is
required to be freed. That will make sure that no links are left out.
Fixes: 96bdda61f58b ("cpufreq: create cpu/cpufreq/policyX directories")
Reported-and-tested-by: Srinivas Pandruvada <srinivas.pandruvada@linux.intel.com>
Signed-off-by: Viresh Kumar <viresh.kumar@linaro.org>
Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com>
Diffstat (limited to 'fs/gfs2')
0 files changed, 0 insertions, 0 deletions