# HG changeset patch # Parent 0ecb8ffe61b2ffff4331fcf49487c956ccb297a0 x86_emulate: Force #UD if lock prefix used with NOP instruction. DTRACE uses 0xF0 0x90 0x90 0x90 0x90 (LOCK NOP NOP NOP NOP) to try and recieve a #UD, but currently get GPF instead. Fix x86_emulate, as #UD is the correct exception in this case. Reported-by: Mukesh Rathor Signed-off-by: Andrew Cooper diff -r 0ecb8ffe61b2 xen/arch/x86/x86_emulate/x86_emulate.c --- a/xen/arch/x86/x86_emulate/x86_emulate.c +++ b/xen/arch/x86/x86_emulate/x86_emulate.c @@ -2255,6 +2255,7 @@ x86_emulate( break; case 0x90: /* nop / xchg %%r8,%%rax */ + generate_exception_if(lock_prefix, EXC_UD, -1); if ( !(rex_prefix & 1) ) break; /* nop */