From: Jan Beulich Date: Thu, 19 Jan 2017 09:34:21 +0000 (+0100) Subject: x86emul: simplify prefix handling for VMFUNC X-Git-Tag: archive/raspbian/4.11.1-1+rpi1~1^2~66^2~2954 X-Git-Url: https://dgit.raspbian.org/?a=commitdiff_plain;h=be832fdc089af84f393f1c8d234c5944d5a2b4e3;p=xen.git x86emul: simplify prefix handling for VMFUNC LOCK prefixes get dealt with elsewhere, and 66, F2, and F3 can all be checked for in one go by looking at vex.pfx. Signed-off-by: Jan Beulich Reviewed-by: Andrew Cooper --- diff --git a/xen/arch/x86/x86_emulate/x86_emulate.c b/xen/arch/x86/x86_emulate/x86_emulate.c index d264d5951f..880d565eb9 100644 --- a/xen/arch/x86/x86_emulate/x86_emulate.c +++ b/xen/arch/x86/x86_emulate/x86_emulate.c @@ -4690,8 +4690,7 @@ x86_emulate( #endif case 0xd4: /* vmfunc */ - generate_exception_if(lock_prefix | rep_prefix() | (vex.pfx == vex_66), - EXC_UD); + generate_exception_if(vex.pfx, EXC_UD); fail_if(!ops->vmfunc); if ( (rc = ops->vmfunc(ctxt)) != X86EMUL_OKAY ) goto done;