mirror of
https://github.com/tbsdtv/linux_media.git
synced 2025-07-23 04:33:26 +02:00
KVM: Drop kvm_arch_{init,exit}() hooks
Drop kvm_arch_init() and kvm_arch_exit() now that all implementations are nops. No functional change intended. Signed-off-by: Sean Christopherson <seanjc@google.com> Reviewed-by: Eric Farman <farman@linux.ibm.com> # s390 Reviewed-by: Philippe Mathieu-Daudé <philmd@linaro.org> Acked-by: Anup Patel <anup@brainfault.org> Message-Id: <20221130230934.1014142-30-seanjc@google.com> Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
This commit is contained in:
committed by
Paolo Bonzini
parent
6c30cd2ef4
commit
a578a0a9e3
@@ -5921,20 +5921,8 @@ int kvm_init(void *opaque, unsigned vcpu_size, unsigned vcpu_align,
|
||||
int r;
|
||||
int cpu;
|
||||
|
||||
/*
|
||||
* FIXME: Get rid of kvm_arch_init(), vendor code should call arch code
|
||||
* directly. Note, kvm_arch_init() _must_ be called before anything
|
||||
* else as x86 relies on checks buried in kvm_arch_init() to guard
|
||||
* against multiple calls to kvm_init().
|
||||
*/
|
||||
r = kvm_arch_init(opaque);
|
||||
if (r)
|
||||
return r;
|
||||
|
||||
if (!zalloc_cpumask_var(&cpus_hardware_enabled, GFP_KERNEL)) {
|
||||
r = -ENOMEM;
|
||||
goto err_hw_enabled;
|
||||
}
|
||||
if (!zalloc_cpumask_var(&cpus_hardware_enabled, GFP_KERNEL))
|
||||
return -ENOMEM;
|
||||
|
||||
c.ret = &r;
|
||||
c.opaque = opaque;
|
||||
@@ -6022,8 +6010,6 @@ out_free_3:
|
||||
cpuhp_remove_state_nocalls(CPUHP_AP_KVM_STARTING);
|
||||
out_free_2:
|
||||
free_cpumask_var(cpus_hardware_enabled);
|
||||
err_hw_enabled:
|
||||
kvm_arch_exit();
|
||||
return r;
|
||||
}
|
||||
EXPORT_SYMBOL_GPL(kvm_init);
|
||||
@@ -6051,7 +6037,6 @@ void kvm_exit(void)
|
||||
on_each_cpu(hardware_disable_nolock, NULL, 1);
|
||||
kvm_irqfd_exit();
|
||||
free_cpumask_var(cpus_hardware_enabled);
|
||||
kvm_arch_exit();
|
||||
}
|
||||
EXPORT_SYMBOL_GPL(kvm_exit);
|
||||
|
||||
|
Reference in New Issue
Block a user