Re: [PATCH/RFC 01/21] KVM: remove unneeded return value of vcpu_postcreate

Paolo Bonzini
2015-01-22T16:55:39Z

On 15/01/2015 14:43, Christian Borntraeger wrote:
> From: Dominik Dingel <dingel@linux.vnet.ibm.com>
>
> Only x86 and s390 provides such vcpu_postcreate implementation.
> On s390 it can't fail and on x86 a fail is also impossible.
> Additionally common code didn't care about return value.
> So we just get rid of it.

s390 doesn't provide it as of this patch. Perhaps clarify:

The return value of kvm_arch_vcpu_postcreate is not checked in its
caller. This is okay, because only x86 provides vcpu_postcreate right
now and it could only fail if vcpu_load failed. But that is not
possible during KVM_CREATE_VCPU (kvm_arch_vcpu_load is void, too), so
just get rid of the unchecked return value.

Paolo

> Signed-off-by: Dominik Dingel <dingel@linux.vnet.ibm.com>
> Acked-by: Cornelia Huck <cornelia.huck@de.ibm.com>
> Signed-off-by: Christian Borntraeger <borntraeger@de.ibm.com>