[PATCH v4 2/9] KVM: arm64: Drop an incomplete MMIO access when resetting a vcpu
Steffen Eiden
seiden at linux.ibm.com
Fri Dec 4 01:24:04 PST 2026
On Fri, Dec 04, 2026 at 11:48:06AM +0300, Dan Carpenter wrote:
> When a vcpu exits to userspace for an MMIO access, the next KVM_RUN
> completes it. So for a read, the next run increments the PC counter
> and copies data from userspace to the destination vcpu register.
>
> A reset should cancel the MMIO read/write access. Otherwise the next
> run will copy memory from userspace to the vcpu and increment the PC
> which skips the first instruction.
>
> Clear vcpu->mmio_needed in kvm_reset_vcpu().
>
> Fixes: 45e96ea6b369 ("KVM: ARM: Handle I/O aborts")
> Cc: stable at vger.kernel.org
> Signed-off-by: Dan Carpenter <dan at pereq.eu>
Reviewed-by: Steffen Eiden <seiden at linux.ibm.com>
More information about the linux-arm-kernel
mailing list