提交 06056bfb 编写于 作者: W Wei Yongjun 提交者: Avi Kivity

KVM: PPC: Do not create debugfs if fail to create vcpu

If fail to create the vcpu, we should not create the debugfs
for it.
Signed-off-by: NWei Yongjun <yjwei@cn.fujitsu.com>
Acked-by: NAlexander Graf <agraf@suse.de>
Cc: stable@kernel.org
Signed-off-by: NAvi Kivity <avi@redhat.com>
上级 7b06bf2f
......@@ -194,7 +194,8 @@ struct kvm_vcpu *kvm_arch_vcpu_create(struct kvm *kvm, unsigned int id)
{
struct kvm_vcpu *vcpu;
vcpu = kvmppc_core_vcpu_create(kvm, id);
kvmppc_create_vcpu_debugfs(vcpu, id);
if (!IS_ERR(vcpu))
kvmppc_create_vcpu_debugfs(vcpu, id);
return vcpu;
}
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册