qemu-devel.nongnu.org archive mirror
 help / color / mirror / Atom feed
From: Alexander Graf <agraf@suse.de>
To: qemu-devel@nongnu.org
Subject: [Qemu-devel] [PATCH] Don't trap STGI within VMRUN
Date: Wed, 04 Jun 2008 17:39:18 +0200	[thread overview]
Message-ID: <4846B726.2040409@suse.de> (raw)

[-- Attachment #1: Type: text/plain, Size: 236 bytes --]

If VMRUN gets called with the STGI trap set active, it traps within the 
VMRUN call itself, creating an endless loop.

This patch makes VMRUN set the GIF flag manually without calling 
helper_stgi. Thus it eliminates the trap.

Alex




[-- Attachment #2: qemu-svn-stgi.patch --]
[-- Type: text/x-patch, Size: 459 bytes --]

Index: target-i386/op_helper.c
===================================================================
--- target-i386/op_helper.c	(revision 4661)
+++ target-i386/op_helper.c	(working copy)
@@ -4910,7 +4910,8 @@
         break;
     }
 
-    helper_stgi();
+    /* STGI to enable interrupts again */
+    env->hflags |= HF_GIF_MASK;
 
     /* maybe we need to inject an event */
     event_inj = ldl_phys(env->vm_vmcb + offsetof(struct vmcb, control.event_inj));

                 reply	other threads:[~2008-06-04 16:36 UTC|newest]

Thread overview: [no followups] expand[flat|nested]  mbox.gz  Atom feed

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=4846B726.2040409@suse.de \
    --to=agraf@suse.de \
    --cc=qemu-devel@nongnu.org \
    /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;
as well as URLs for NNTP newsgroup(s).