From: Avi Kivity Subject: Re: [PATCH v3 4/9] target-i386: Add infrastructure for reporting TPR MMIO accesses Date: Thu, 16 Feb 2012 17:21:53 +0200 Message-ID: <4F3D1F11.5070804@redhat.com> References: <3ac2ae28b19aabebd3937b87ff365b481f990779.1329232393.git.jan.kiszka@siemens.com> Mime-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit Cc: Anthony Liguori , Gleb Natapov , kvm@vger.kernel.org, Marcelo Tosatti , qemu-devel , Blue Swirl To: Jan Kiszka Return-path: In-Reply-To: <3ac2ae28b19aabebd3937b87ff365b481f990779.1329232393.git.jan.kiszka@siemens.com> List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: qemu-devel-bounces+gceq-qemu-devel=gmane.org@nongnu.org Sender: qemu-devel-bounces+gceq-qemu-devel=gmane.org@nongnu.org List-Id: kvm.vger.kernel.org On 02/14/2012 05:13 PM, Jan Kiszka wrote: > Note that KVM without in-kernel irqchip will report the address after > the instruction that triggered a write access. In contrast, read > accesses will return the precise information. > Well this is wierd. We could retro-doc one or the other behaviour, but this-on-read-but-that-on-write is just too strange. The documented way of dealing with this is to queue a signal and reenter the guest. kvm will perform anything it needs to complete the instruction (perhaps issuing more mmio, say if someone used movsd to read the APIC) and then exit on the signal. By then rip will point exactly after the instruction. -- error compiling committee.c: too many arguments to function