From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([140.186.70.92]:59788) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1RsBL1-0007UP-0R for qemu-devel@nongnu.org; Tue, 31 Jan 2012 05:53:28 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1RsBKw-0005O6-Du for qemu-devel@nongnu.org; Tue, 31 Jan 2012 05:53:22 -0500 Received: from mx1.redhat.com ([209.132.183.28]:30613) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1RsBKw-0005O0-3m for qemu-devel@nongnu.org; Tue, 31 Jan 2012 05:53:18 -0500 Message-ID: <4F27C875.8080503@redhat.com> Date: Tue, 31 Jan 2012 11:54:45 +0100 From: Laszlo Ersek MIME-Version: 1.0 References: <4F27B5AD.9050709@redhat.com> <4F27D232020000780007012B@nat28.tlf.novell.com> In-Reply-To: <4F27D232020000780007012B@nat28.tlf.novell.com> Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit Subject: Re: [Qemu-devel] [Xen-devel] qemu(-dm): aborting on wrong mmio size? List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Jan Beulich Cc: Miroslav Rezanina , "xen-devel@lists.xensource.com" , Petr Matousek , qemu-devel@nongnu.org On 01/31/12 11:36, Jan Beulich wrote: >>>> On 31.01.12 at 10:34, Laszlo Ersek wrote: >> in the qemu-xen-unstable tree >> (git://xenbits.xen.org/qemu-xen-unstable.git), the do_inp() function >> [i386-dm/helper2.c] makes the process exit if the operand size is wrong. >> Blame: 6040eea5 ("More files imported from xen-unstable >> 17192:59b8768d0d0d"). >> >> In the qemu tree (git://git.qemu.org/qemu.git), the do_inp() function >> [xen-all.c] does the same (via hw_error() / abort()). Blame: 9ce94e7c >> ("xen: Initialize event channels and io rings"). >> >> Is it justified to kill the emulator when this happens (eg. memory >> mapped IO with 64-bit operand)? > > Afaict, this is not about MMIO, but PIO. One possible way seems to be (see http://xenbits.xensource.com/hg/linux-2.6.18-xen.hg/rev/1141): vmx_hpw_miss() [xen/arch/ia64/vmx/vmx_fault.c] -> emulate_io_inst() [xen/arch/ia64/vmx/mmio.c] -> mmio_access() -> legacy_io_access() -> vmx_send_assist_req() [xen/arch/ia64/vmx/vmx_support.c] -> notify_via_xen_event_channel() [xen/common/event_channel.c] and in qemu-xen-unstable, cpu_handle_ioreq() [i386-dm/helper2.c], set up in main_loop() -> __handle_ioreq() -> cpu_ioreq_pio() -> do_inp() Thanks, Laszlo