From: Izik Eidus Date: Sun, 11 Nov 2007 12:40:48 +0000 (+0200) Subject: KVM: x86 emulator: fix JMP_REL X-Git-Tag: MMI-PSA29.97-13-9~38246^2~4 X-Git-Url: https://git.stricted.de/?a=commitdiff_plain;h=e826ec9ae2baf9980402e85f0bbe1dac53ceb110;p=GitHub%2FMotorolaMobilityLLC%2Fkernel-slsi.git KVM: x86 emulator: fix JMP_REL Change JMP_REL to call to register_address_increment(): the operands size should not effect the calculation of the eip, instead the ad_bytes should affect it. Signed-off-by: Izik Eidus Signed-off-by: Avi Kivity --- diff --git a/drivers/kvm/x86_emulate.c b/drivers/kvm/x86_emulate.c index 33b181451557..a1a9c9be39b3 100644 --- a/drivers/kvm/x86_emulate.c +++ b/drivers/kvm/x86_emulate.c @@ -448,8 +448,7 @@ struct operand { #define JMP_REL(rel) \ do { \ - _eip += (int)(rel); \ - _eip = ((op_bytes == 2) ? (uint16_t)_eip : (uint32_t)_eip); \ + register_address_increment(_eip, rel); \ } while (0) /*