From: Wei Yongjun Date: Sun, 5 May 2013 12:03:40 +0000 (+0800) Subject: KVM: add missing misc_deregister() on error in kvm_init() X-Git-Tag: v3.11-rc1~104^2~75 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=afc2f792cdcb67f4257f0e68d10ee4a7b7eae57a;p=profile%2Fivi%2Fkernel-x86-ivi.git KVM: add missing misc_deregister() on error in kvm_init() Add the missing misc_deregister() before return from kvm_init() in the debugfs init error handling case. Signed-off-by: Wei Yongjun Signed-off-by: Gleb Natapov --- diff --git a/virt/kvm/kvm_main.c b/virt/kvm/kvm_main.c index 302681c..b547a1c 100644 --- a/virt/kvm/kvm_main.c +++ b/virt/kvm/kvm_main.c @@ -3181,6 +3181,7 @@ int kvm_init(void *opaque, unsigned vcpu_size, unsigned vcpu_align, out_undebugfs: unregister_syscore_ops(&kvm_syscore_ops); + misc_deregister(&kvm_dev); out_unreg: kvm_async_pf_deinit(); out_free: