]> git.baikalelectronics.ru Git - kernel.git/commit
KVM: x86: check validity of argument to KVM_SET_MP_STATE
authorPaolo Bonzini <pbonzini@redhat.com>
Thu, 11 Aug 2022 16:41:25 +0000 (12:41 -0400)
committerPaolo Bonzini <pbonzini@redhat.com>
Thu, 1 Sep 2022 23:20:59 +0000 (19:20 -0400)
commita4b9e0304b2ba5c3bf9ec95cd16bc55c0838546c
tree246ddf94bf8b00929b920c1b92417b61664d963f
parent55466278f1723e3acafd3d284ab2d4034a5142d0
KVM: x86: check validity of argument to KVM_SET_MP_STATE

An invalid argument to KVM_SET_MP_STATE has no effect other than making the
vCPU fail to run at the next KVM_RUN.  Since it is extremely unlikely that
any userspace is relying on it, fail with -EINVAL just like for other
architectures.

Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
arch/x86/kvm/x86.c