Re: [PATCH -tip v3 1/2] x86: xen: insn: Decode Xen and KVM emulate-prefix signature

2019-09-06 Thread Masami Hiramatsu
On Fri, 6 Sep 2019 09:34:36 +0200 Peter Zijlstra wrote: > On Fri, Sep 06, 2019 at 10:45:48AM +0900, Masami Hiramatsu wrote: > > > diff --git a/arch/x86/include/asm/xen/interface.h > > b/arch/x86/include/asm/xen/interface.h > > index 62ca03ef5c65..fe33a9798708 100644 > > ---

Re: [PATCH -tip v3 1/2] x86: xen: insn: Decode Xen and KVM emulate-prefix signature

2019-09-06 Thread Peter Zijlstra
On Fri, Sep 06, 2019 at 05:51:43PM +0900, Masami Hiramatsu wrote: > On Fri, 6 Sep 2019 17:45:19 +0900 > Masami Hiramatsu wrote: > > > > > > > How about we make this asm/virt_prefix.h or something and include: > > > > > > /* > > > * Virt escape sequences to trigger instruction emulation; > > >

Re: [PATCH -tip v3 1/2] x86: xen: insn: Decode Xen and KVM emulate-prefix signature

2019-09-06 Thread Masami Hiramatsu
On Fri, 6 Sep 2019 17:45:19 +0900 Masami Hiramatsu wrote: > > > > How about we make this asm/virt_prefix.h or something and include: > > > > /* > > * Virt escape sequences to trigger instruction emulation; > > * ideally these would decode to 'whole' instruction and not destroy > > * the

Re: [PATCH -tip v3 1/2] x86: xen: insn: Decode Xen and KVM emulate-prefix signature

2019-09-06 Thread Masami Hiramatsu
On Fri, 6 Sep 2019 09:34:36 +0200 Peter Zijlstra wrote: > On Fri, Sep 06, 2019 at 10:45:48AM +0900, Masami Hiramatsu wrote: > > > diff --git a/arch/x86/include/asm/xen/interface.h > > b/arch/x86/include/asm/xen/interface.h > > index 62ca03ef5c65..fe33a9798708 100644 > > ---

Re: [PATCH -tip v3 1/2] x86: xen: insn: Decode Xen and KVM emulate-prefix signature

2019-09-06 Thread Peter Zijlstra
On Fri, Sep 06, 2019 at 10:45:48AM +0900, Masami Hiramatsu wrote: > diff --git a/arch/x86/include/asm/xen/interface.h > b/arch/x86/include/asm/xen/interface.h > index 62ca03ef5c65..fe33a9798708 100644 > --- a/arch/x86/include/asm/xen/interface.h > +++ b/arch/x86/include/asm/xen/interface.h > @@

[PATCH -tip v3 1/2] x86: xen: insn: Decode Xen and KVM emulate-prefix signature

2019-09-05 Thread Masami Hiramatsu
Decode Xen and KVM's emulate-prefix signature by x86 insn decoder. It is called "prefix" but actually not x86 instruction prefix, so this adds insn.emulate_prefix_size field instead of reusing insn.prefixes. If x86 decoder finds a special sequence of instructions of XEN_EMULATE_PREFIX and 'ud2a;