]> git.karo-electronics.de Git - linux-beck.git/commit
KVM: x86 emulator: preserve an operand's segment identity
authorAvi Kivity <avi@redhat.com>
Wed, 17 Nov 2010 13:28:21 +0000 (15:28 +0200)
committerAvi Kivity <avi@redhat.com>
Wed, 12 Jan 2011 09:29:35 +0000 (11:29 +0200)
commit90de84f50b425805bf7ddc430143ed2e224ebd8e
tree259b70846fc9972c77e60c85e0afe172b4d87d7d
parentd53db5efc2f6026f7cb0871c91b887ed55e0f265
KVM: x86 emulator: preserve an operand's segment identity

Currently the x86 emulator converts the segment register associated with
an operand into a segment base which is added into the operand address.
This loss of information results in us not doing segment limit checks properly.

Replace struct operand's addr.mem field by a segmented_address structure
which holds both the effetive address and segment.  This will allow us to
do the limit check at the point of access.

Signed-off-by: Avi Kivity <avi@redhat.com>
Signed-off-by: Marcelo Tosatti <mtosatti@redhat.com>
arch/x86/include/asm/kvm_emulate.h
arch/x86/kvm/emulate.c