KVM: x86: Don't WARN if userspace mucks with RCX during string I/O exit
authorSean Christopherson <seanjc@google.com>
Mon, 25 Oct 2021 20:13:10 +0000 (13:13 -0700)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Tue, 14 Dec 2021 09:57:11 +0000 (10:57 +0100)
commiteea80da3472bc3e4bf11f1baf18962df4207f732
tree12b995416992dea7d3c2412da784ee8db7c7a10b
parentd6c37e679631761f8f2db0abb214d9e4aec0b036
KVM: x86: Don't WARN if userspace mucks with RCX during string I/O exit

commit d07898eaf39909806128caccb6ebd922ee3edd69 upstream.

Replace a WARN with a comment to call out that userspace can modify RCX
during an exit to userspace to handle string I/O.  KVM doesn't actually
support changing the rep count during an exit, i.e. the scenario can be
ignored, but the WARN needs to go as it's trivial to trigger from
userspace.

Cc: stable@vger.kernel.org
Fixes: 3b27de271839 ("KVM: x86: split the two parts of emulator_pio_in")
Signed-off-by: Sean Christopherson <seanjc@google.com>
Message-Id: <20211025201311.1881846-2-seanjc@google.com>
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
arch/x86/kvm/x86.c