mirror of
git://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
synced 2025-08-05 16:54:27 +00:00
KVM: Unregister cpufreq notifier on unload
Properly unregister cpufreq notifier on onload if it was registered during init. Signed-off-by: Jan Kiszka <jan.kiszka@siemens.com> Signed-off-by: Avi Kivity <avi@redhat.com>
This commit is contained in:
parent
7f1ea20896
commit
888d256e9c
1 changed files with 3 additions and 0 deletions
|
@ -2775,6 +2775,9 @@ out:
|
||||||
|
|
||||||
void kvm_arch_exit(void)
|
void kvm_arch_exit(void)
|
||||||
{
|
{
|
||||||
|
if (!boot_cpu_has(X86_FEATURE_CONSTANT_TSC))
|
||||||
|
cpufreq_unregister_notifier(&kvmclock_cpufreq_notifier_block,
|
||||||
|
CPUFREQ_TRANSITION_NOTIFIER);
|
||||||
kvm_x86_ops = NULL;
|
kvm_x86_ops = NULL;
|
||||||
kvm_mmu_module_exit();
|
kvm_mmu_module_exit();
|
||||||
}
|
}
|
||||||
|
|
Loading…
Add table
Reference in a new issue