Commit 36d014d3 authored by Fabiano Rosas's avatar Fabiano Rosas Committed by Michael Ellerman

KVM: PPC: Book3S HV: Stop returning internal values to userspace

Our kvm_arch_vcpu_ioctl_run currently returns the RESUME_HOST values
to userspace, against the API of the KVM_RUN ioctl which returns 0 on
success.
Signed-off-by: default avatarFabiano Rosas <farosas@linux.ibm.com>
Reviewed-by: default avatarNicholas Piggin <npiggin@gmail.com>
Signed-off-by: default avatarMichael Ellerman <mpe@ellerman.id.au>
Link: https://lore.kernel.org/r/20220125215655.1026224-2-farosas@linux.ibm.com
parent 26291c54
...@@ -1841,6 +1841,14 @@ int kvm_arch_vcpu_ioctl_run(struct kvm_vcpu *vcpu) ...@@ -1841,6 +1841,14 @@ int kvm_arch_vcpu_ioctl_run(struct kvm_vcpu *vcpu)
#ifdef CONFIG_ALTIVEC #ifdef CONFIG_ALTIVEC
out: out:
#endif #endif
/*
* We're already returning to userspace, don't pass the
* RESUME_HOST flags along.
*/
if (r > 0)
r = 0;
vcpu_put(vcpu); vcpu_put(vcpu);
return r; return r;
} }
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment