[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <0aedd0e5-f5eb-54d8-6f77-e7a12c65fed5@redhat.com>
Date: Fri, 9 Feb 2018 13:42:51 +0100
From: Paolo Bonzini <pbonzini@...hat.com>
To: Xiao Guangrong <guangrong.xiao@...il.com>,
Wanpeng Li <kernellwp@...il.com>, linux-kernel@...r.kernel.org,
kvm@...r.kernel.org
Cc: Radim Krčmář <rkrcmar@...hat.com>,
Dmitry Vyukov <dvyukov@...gle.com>
Subject: Re: [PATCH] KVM: X86: Fix SMRAM accessing even if VM is shutdown
On 09/02/2018 04:22, Xiao Guangrong wrote:
>>
>
> That is a good question... :)
>
> This case (with KVM_MEMSLOT_INVALID is set) can be easily constructed,
> userspace should avoid this case by itself (avoiding vCPU accessing the
> memslot which is being updated). If it happens, it's a operation issue
> rather than INTERNAL ERROR.
>
> Maybe treat it as MMIO accessing and return to userspace with MMIO_EXIT
> is a better solution...
Yeah, that's what emulation would do (except if it's an instruction
fetch, which will cause emulation to fail). I think it's a bug in the
non-EPT #PF case that we return with -EFAULT.
Paolo
Powered by blists - more mailing lists