Re: [PATCH 2/9] KVM: x86: simplify read_emulated

2012-07-22 Thread Xiao Guangrong
On 07/21/2012 03:52 AM, Marcelo Tosatti wrote: > On Fri, Jul 20, 2012 at 09:15:44PM +0800, Xiao Guangrong wrote: >> On 07/20/2012 06:58 PM, Marcelo Tosatti wrote: >>> On Fri, Jul 20, 2012 at 10:17:36AM +0800, Xiao Guangrong wrote: On 07/20/2012 07:58 AM, Marcelo Tosatti wrote: >> -

Re: [PATCH 2/9] KVM: x86: simplify read_emulated

2012-07-20 Thread Marcelo Tosatti
On Fri, Jul 20, 2012 at 09:15:44PM +0800, Xiao Guangrong wrote: > On 07/20/2012 06:58 PM, Marcelo Tosatti wrote: > > On Fri, Jul 20, 2012 at 10:17:36AM +0800, Xiao Guangrong wrote: > >> On 07/20/2012 07:58 AM, Marcelo Tosatti wrote: > >> > -} > +rc = ctxt->ops->read_emulat

Re: [PATCH 2/9] KVM: x86: simplify read_emulated

2012-07-20 Thread Xiao Guangrong
On 07/20/2012 06:58 PM, Marcelo Tosatti wrote: > On Fri, Jul 20, 2012 at 10:17:36AM +0800, Xiao Guangrong wrote: >> On 07/20/2012 07:58 AM, Marcelo Tosatti wrote: >> - } + rc = ctxt->ops->read_emulated(ctxt, addr, mc->data + mc->end, size, +&ctxt->ex

Re: [PATCH 2/9] KVM: x86: simplify read_emulated

2012-07-20 Thread Marcelo Tosatti
On Fri, Jul 20, 2012 at 10:17:36AM +0800, Xiao Guangrong wrote: > On 07/20/2012 07:58 AM, Marcelo Tosatti wrote: > > >> - } > >> + rc = ctxt->ops->read_emulated(ctxt, addr, mc->data + mc->end, size, > >> +&ctxt->exception); > >> + if (rc != X86EMUL_CONTINUE) > >>

Re: [PATCH 2/9] KVM: x86: simplify read_emulated

2012-07-19 Thread Xiao Guangrong
On 07/20/2012 07:58 AM, Marcelo Tosatti wrote: >> -} >> +rc = ctxt->ops->read_emulated(ctxt, addr, mc->data + mc->end, size, >> + &ctxt->exception); >> +if (rc != X86EMUL_CONTINUE) >> +return rc; >> + >> +mc->end += size; >> + >> +read_c

Re: [PATCH 2/9] KVM: x86: simplify read_emulated

2012-07-19 Thread Marcelo Tosatti
On Tue, Jul 17, 2012 at 09:51:34PM +0800, Xiao Guangrong wrote: > No need split mmio read region into 8-bits pieces since we do it in > emulator_read_write_onepage > > Signed-off-by: Xiao Guangrong > --- > arch/x86/kvm/emulate.c | 29 - > 1 files changed, 12 inserti

[PATCH 2/9] KVM: x86: simplify read_emulated

2012-07-17 Thread Xiao Guangrong
No need split mmio read region into 8-bits pieces since we do it in emulator_read_write_onepage Signed-off-by: Xiao Guangrong --- arch/x86/kvm/emulate.c | 29 - 1 files changed, 12 insertions(+), 17 deletions(-) diff --git a/arch/x86/kvm/emulate.c b/arch/x86/kvm/em