target-i386: fix disassembly with PAE=1, PG=0
commitf2f8560c7a5303065a2a3207ec475dfb3a622a0e
authorPaolo Bonzini <pbonzini@redhat.com>
Fri, 30 Aug 2013 09:58:45 +0000 (30 11:58 +0200)
committerRichard Henderson <rth@twiddle.net>
Thu, 12 Sep 2013 18:20:42 +0000 (12 11:20 -0700)
tree6270568fe70db2f5b9ec9b5b1d52f13d44f3b1c3
parent2d1fe1873a984d1c2c89ffa3d12949cafc718551
target-i386: fix disassembly with PAE=1, PG=0

CR4.PAE=1 will not enable paging if CR0.PG=0, but the "if" chain
in x86_cpu_get_phys_page_debug says otherwise.  Check CR0.PG
before everything else.

Fixes "-d in_asm" for a code section at the beginning of OVMF.

Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
Signed-off-by: Richard Henderson <rth@twiddle.net>
Reviewed-by: Max Filippov <jcmvbkbc@gmail.com>
target-i386/helper.c