From: Avi Kivity <avi@qumranet.com>
To: kvm@vger.kernel.org
Cc: linux-kernel@vger.kernel.org, Mohammed Gamal <m.gamal005@gmail.com>
Subject: [PATCH 13/19] KVM: x86 emulator: Fix HLT instruction
Date: Tue, 15 Jul 2008 15:12:32 +0300 [thread overview]
Message-ID: <1216123958-10717-14-git-send-email-avi@qumranet.com> (raw)
In-Reply-To: <1216123958-10717-1-git-send-email-avi@qumranet.com>
From: Mohammed Gamal <m.gamal005@gmail.com>
This patch fixes issue encountered with HLT instruction
under FreeDOS's HIMEM XMS Driver.
The HLT instruction jumped directly to the done label and
skips updating the EIP value, therefore causing the guest
to spin endlessly on the same instruction.
The patch changes the instruction so that it writes back
the updated EIP value.
Signed-off-by: Mohammed Gamal <m.gamal005@gmail.com>
Signed-off-by: Avi Kivity <avi@qumranet.com>
---
arch/x86/kvm/x86_emulate.c | 2 +-
1 files changed, 1 insertions(+), 1 deletions(-)
diff --git a/arch/x86/kvm/x86_emulate.c b/arch/x86/kvm/x86_emulate.c
index 18ca25c..8bc63f6 100644
--- a/arch/x86/kvm/x86_emulate.c
+++ b/arch/x86/kvm/x86_emulate.c
@@ -1731,7 +1731,7 @@ special_insn:
break;
case 0xf4: /* hlt */
ctxt->vcpu->arch.halt_request = 1;
- goto done;
+ break;
case 0xf5: /* cmc */
/* complement carry flag from eflags reg */
ctxt->eflags ^= EFLG_CF;
--
1.5.6.1
next prev parent reply other threads:[~2008-07-15 12:16 UTC|newest]
Thread overview: 20+ messages / expand[flat|nested] mbox.gz Atom feed top
2008-07-15 12:12 [PATCH 00/19] KVM Updates for the 2.6.27 (supplemental) Avi Kivity
2008-07-15 12:12 ` [PATCH 01/19] KVM: VMX: Fix a wrong usage of vmcs_config Avi Kivity
2008-07-15 12:12 ` [PATCH 02/19] KVM: VMX: Fake emulate Intel perfctr MSRs Avi Kivity
2008-07-15 12:12 ` [PATCH 03/19] KVM: move slots_lock acquision down to vapic_exit Avi Kivity
2008-07-15 12:12 ` [PATCH 04/19] KVM: s390: dont allocate dirty bitmap Avi Kivity
2008-07-15 12:12 ` [PATCH 05/19] KVM: Fix memory leak on guest exit Avi Kivity
2008-07-15 12:12 ` [PATCH 06/19] KVM: s390: Set guest storage limit and offset to sane values Avi Kivity
2008-07-15 12:12 ` [PATCH 07/19] KVM: s390: rename private structures Avi Kivity
2008-07-15 12:12 ` [PATCH 08/19] KVM: SVM: fix suspend/resume support Avi Kivity
2008-07-15 12:12 ` [PATCH 09/19] x86: KVM guest: make kvm_smp_prepare_boot_cpu() static Avi Kivity
2008-07-15 12:12 ` [PATCH 10/19] KVM: mmu_shrink: kvm_mmu_zap_page requires slots_lock to be held Avi Kivity
2008-07-15 12:12 ` [PATCH 11/19] KVM: VMX: Add ept_sync_context in flush_tlb Avi Kivity
2008-07-15 12:12 ` [PATCH 12/19] KVM: Apply the kernel sigmask to vcpus blocked due to being uninitialized Avi Kivity
2008-07-15 12:12 ` Avi Kivity [this message]
2008-07-15 12:12 ` [PATCH 14/19] KVM: check injected pic irq within valid pic irqs Avi Kivity
2008-07-15 12:12 ` [PATCH 15/19] KVM: Prefix some x86 low level function with kvm_, to avoid namespace issues Avi Kivity
2008-07-15 12:12 ` [PATCH 16/19] KVM: MMU: nuke shadowed pgtable pages and ptes on memslot destruction Avi Kivity
2008-07-15 12:12 ` [PATCH 17/19] KVM: MMU: improve invalid shadow root page handling Avi Kivity
2008-07-15 12:12 ` [PATCH 18/19] KVM: x86 emulator: emulate clflush Avi Kivity
2008-07-15 12:12 ` [PATCH 19/19] KVM: MMU: Fix potential race setting upper shadow ptes on nonpae hosts Avi Kivity
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=1216123958-10717-14-git-send-email-avi@qumranet.com \
--to=avi@qumranet.com \
--cc=kvm@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=m.gamal005@gmail.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
all inboxes | Powered by JetHome®