All of lore.kernel.org
 help / color / mirror / Atom feed
From: "H. Peter Anvin" <hpa@zytor.com>
To: Glauber Costa <glommer@redhat.com>
Cc: kvm@vger.kernel.org, linux-kernel@vger.kernel.org, avi@redhat.com
Subject: Re: [PATCH] do not keep interrupt window closed by sti in real mode
Date: Wed, 08 Apr 2009 09:11:55 -0700	[thread overview]
Message-ID: <49DCCCCB.9000201@zytor.com> (raw)
In-Reply-To: <20090408145545.GA25323@poweredge.glommer>

Glauber Costa wrote:
> 
> I get the idea from the pseudocode in sti description.
> It says:
> IF PE = 0 (* Executing in real-address mode *)
>     THEN
>         IF <- 1; (* Set Interrupt Flag *)
>     ELSE (* Executing in protected mode or virtual-8086 mode *)
> 
> There is no mention to any other activity besides setting the if flag.

But the same is true for the protected mode side of the instruction 
description!

> Also, sti is used extensively in many places like the linux kernel for the
> guest, and it works just fine in kvm. So I was led to believe that real mode
> in fact behaving differently.

The difference is that at least under current Intel VT, VT only handles 
protected mode -- the real mode runs purely in the interpreter.

> I'll take a look at avi's suggestion.

	-hpa

      reply	other threads:[~2009-04-08 16:13 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2009-04-08  3:23 [PATCH] do not keep interrupt window closed by sti in real mode Glauber Costa
2009-04-08  4:14 ` H. Peter Anvin
2009-04-08  5:45   ` Avi Kivity
2009-04-08  6:25     ` H. Peter Anvin
2009-04-08  8:16       ` Avi Kivity
2009-04-08 14:55   ` Glauber Costa
2009-04-08 16:11     ` H. Peter Anvin [this message]

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=49DCCCCB.9000201@zytor.com \
    --to=hpa@zytor.com \
    --cc=avi@redhat.com \
    --cc=glommer@redhat.com \
    --cc=kvm@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.