Cull more tests if EFER.NXE=0. Signed-off-by: Paolo Bonzini <pbonzini@xxxxxxxxxx> --- x86/access.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/x86/access.c b/x86/access.c index 6285c8c..4725bbd 100644 --- a/x86/access.c +++ b/x86/access.c @@ -324,6 +324,8 @@ static _Bool ac_test_legal(ac_test_t *at) */ reserved = (AC_PDE_BIT51_MASK | AC_PDE_BIT36_MASK | AC_PDE_BIT13_MASK | AC_PTE_BIT51_MASK | AC_PTE_BIT36_MASK); + if (!F(AC_CPU_EFER_NX)) + reserved |= AC_PDE_NX_MASK | AC_PTE_NX_MASK; /* Only test one reserved bit at a time. */ reserved &= flags; -- 2.27.0