Skip to content
Commit 719d5a9b authored by Paolo Bonzini's avatar Paolo Bonzini
Browse files

KVM: x86: ensure emulator fetches do not span multiple pages



When the CS base is not page-aligned, the linear address of the code could
get close to the page boundary (e.g. 0x...ffe) even if the EIP value is
not.  So we need to first linearize the address, and only then compute
the number of valid bytes that can be fetched.

This happens relatively often when executing real mode code.

Signed-off-by: default avatarPaolo Bonzini <pbonzini@redhat.com>
parent 17052f16
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment