diff options
author | Dave Jones <davej@redhat.com> | 2011-06-12 16:35:28 -0400 |
---|---|---|
committer | Greg Kroah-Hartman <gregkh@suse.de> | 2011-06-23 15:05:40 -0700 |
commit | 89ae106c9a9c2747e11ae1bacd7f5a65207a9296 (patch) | |
tree | 9dd50d133262771bbfb9e4fa71b2a9835753b7a0 | |
parent | 28223659e8b6af5d7303849f64cc3e7a4003bcbc (diff) |
CPUFREQ: Remove cpufreq_stats sysfs entries on module unload.
commit 13f067537f34456443f61c950cd6dc37d1d5f3ee upstream.
cpufreq_stats leaves behind its sysfs entries, which causes a panic
when something stumbled across them.
(Discovered by unloading cpufreq_stats while powertop was loaded).
Signed-off-by: Dave Jones <davej@redhat.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
-rw-r--r-- | drivers/cpufreq/cpufreq_stats.c | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/drivers/cpufreq/cpufreq_stats.c b/drivers/cpufreq/cpufreq_stats.c index 4f1b8de2c9f..7c7a1e481c0 100644 --- a/drivers/cpufreq/cpufreq_stats.c +++ b/drivers/cpufreq/cpufreq_stats.c @@ -388,6 +388,7 @@ static void __exit cpufreq_stats_exit(void) unregister_hotcpu_notifier(&cpufreq_stat_cpu_notifier); for_each_online_cpu(cpu) { cpufreq_stats_free_table(cpu); + cpufreq_stats_free_sysfs(cpu); } } |