From: Keir Fraser Subject: Re: [PATCH] VMX support for MMIO/PIO in VM8086 mode Date: Sat, 2 Apr 2005 08:25:51 +0100 Message-ID: <9f0e2e06957f5558366ff86d73f7f84e@cl.cam.ac.uk> References: <20050402064934.297AE106B@huxley.watson.ibm.com> Mime-Version: 1.0 (Apple Message framework v619.2) Content-Type: text/plain; charset=US-ASCII; format=flowed Content-Transfer-Encoding: 7bit Return-path: In-Reply-To: <20050402064934.297AE106B@huxley.watson.ibm.com> List-Unsubscribe: , List-Post: List-Help: List-Subscribe: , Sender: xen-devel-bounces@lists.xensource.com Errors-To: xen-devel-bounces@lists.xensource.com To: Leendert van Doorn Cc: xen-devel@lists.xensource.com List-Id: xen-devel@lists.xenproject.org On 2 Apr 2005, at 07:49, Leendert van Doorn wrote: > Memory mapped and port I/O is currently broken under VMX when the > partition is running in VM8086 mode. The reason is that the instruction > decoding support uses 32-bit opcode/address decodes rather 16-bit > decodes. This patch fixes that. In addition, the patch adds support for > the "stos" instruction decoding because this is a frequently used way > to clear MMIO areas such as the screen. > > As an aside, vmx_platform.c should really reuse x86_emulate.c as much > as possible. The memory-fault emulator needs proper support for 16-bit addressing and vm86 mode, which won't be hard to hard. I also need to pull the privileged-op emulator out of traps.c, and abstract out the action parts of it (e.g., actual move to/from CR, move to/from I/O port) in the same way I abstracted memory accesses in the mem-fault emulator. There's less of a win in sharing the priv-op emulator since it is so much simpler, but it should still clean up the code a bunch. -- Keir