aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/kvm/x86_emulate.c
diff options
context:
space:
mode:
authorNitin A Kamble <nitin.a.kamble@intel.com>2007-09-18 19:34:25 -0400
committerAvi Kivity <avi@qumranet.com>2007-10-22 06:03:28 -0400
commit1a52e051368a0e29b26e8790bacd8d1d759e3287 (patch)
tree738df08e144b317d3a304d6ffca16060b25843f6 /drivers/kvm/x86_emulate.c
parent55b70a0300b873c0ec7ea6e33752af56f41250ce (diff)
KVM: x86 emulator: fix merge screwup due to emulator split
This code has gone to wrong place in the file. Moving it back to right location. Signed-off-by: Nitin A Kamble <nitin.a.kamble@intel.com> Signed-off-by: Avi Kivity <avi@qumranet.com>
Diffstat (limited to 'drivers/kvm/x86_emulate.c')
-rw-r--r--drivers/kvm/x86_emulate.c51
1 files changed, 26 insertions, 25 deletions
diff --git a/drivers/kvm/x86_emulate.c b/drivers/kvm/x86_emulate.c
index 9737c3b2f48c..b1026d2c8aec 100644
--- a/drivers/kvm/x86_emulate.c
+++ b/drivers/kvm/x86_emulate.c
@@ -1083,31 +1083,6 @@ push:
1083 case 0xd2 ... 0xd3: /* Grp2 */ 1083 case 0xd2 ... 0xd3: /* Grp2 */
1084 src.val = _regs[VCPU_REGS_RCX]; 1084 src.val = _regs[VCPU_REGS_RCX];
1085 goto grp2; 1085 goto grp2;
1086 case 0xe8: /* call (near) */ {
1087 long int rel;
1088 switch (op_bytes) {
1089 case 2:
1090 rel = insn_fetch(s16, 2, _eip);
1091 break;
1092 case 4:
1093 rel = insn_fetch(s32, 4, _eip);
1094 break;
1095 case 8:
1096 rel = insn_fetch(s64, 8, _eip);
1097 break;
1098 default:
1099 DPRINTF("Call: Invalid op_bytes\n");
1100 goto cannot_emulate;
1101 }
1102 src.val = (unsigned long) _eip;
1103 JMP_REL(rel);
1104 goto push;
1105 }
1106 case 0xe9: /* jmp rel */
1107 case 0xeb: /* jmp rel short */
1108 JMP_REL(src.val);
1109 no_wb = 1; /* Disable writeback. */
1110 break;
1111 case 0xf6 ... 0xf7: /* Grp3 */ 1086 case 0xf6 ... 0xf7: /* Grp3 */
1112 switch (modrm_reg) { 1087 switch (modrm_reg) {
1113 case 0 ... 1: /* test */ 1088 case 0 ... 1: /* test */
@@ -1350,6 +1325,32 @@ special_insn:
1350 case 0xae ... 0xaf: /* scas */ 1325 case 0xae ... 0xaf: /* scas */
1351 DPRINTF("Urk! I don't handle SCAS.\n"); 1326 DPRINTF("Urk! I don't handle SCAS.\n");
1352 goto cannot_emulate; 1327 goto cannot_emulate;
1328 case 0xe8: /* call (near) */ {
1329 long int rel;
1330 switch (op_bytes) {
1331 case 2:
1332 rel = insn_fetch(s16, 2, _eip);
1333 break;
1334 case 4:
1335 rel = insn_fetch(s32, 4, _eip);
1336 break;
1337 case 8:
1338 rel = insn_fetch(s64, 8, _eip);
1339 break;
1340 default:
1341 DPRINTF("Call: Invalid op_bytes\n");
1342 goto cannot_emulate;
1343 }
1344 src.val = (unsigned long) _eip;
1345 JMP_REL(rel);
1346 goto push;
1347 }
1348 case 0xe9: /* jmp rel */
1349 case 0xeb: /* jmp rel short */
1350 JMP_REL(src.val);
1351 no_wb = 1; /* Disable writeback. */
1352 break;
1353
1353 1354
1354 } 1355 }
1355 goto writeback; 1356 goto writeback;