public inbox for kvm@vger.kernel.org
 help / color / mirror / Atom feed
From: Jan Kiszka <jan.kiszka@siemens.com>
To: Avi Kivity <avi@redhat.com>
Cc: Marcelo Tosatti <mtosatti@redhat.com>, kvm <kvm@vger.kernel.org>,
	Gleb Natapov <gleb@redhat.com>
Subject: Re: KVM: x86: Push potential exception error code on task switches
Date: Wed, 14 Apr 2010 15:19:28 +0200	[thread overview]
Message-ID: <4BC5C0E0.6000805@siemens.com> (raw)
In-Reply-To: <4BC5BE25.8090800@redhat.com>

Avi Kivity wrote:
> On 04/14/2010 03:58 PM, Jan Kiszka wrote:
>>> The TSS descriptor (gate doesn't have a size).  But isn't it possible to
>>> have a 32-bit TSS with a 16-bit CS/SS?
>>>      
>> Might be possible, but will cause troubles as the spec says:
>>
>> "The error code is pushed on the stack as a doubleword or word
>> (depending on the default interrupt, trap, or task gate size)."
>>    
> 
> My guess is that this is an error and that the 32-bitness of a TSS only 
> refers to the format of the TSS, and has nothing to do with the code 
> that actually runs.  I'll ask Intel about it.  Meanwhile this can be 
> applied, if there's a problem with 16-bit exception handlers running 
> through a 32-bit task referenced by a task gate in the IDT, it can be 
> fixed later.

Go ahead. But architecturally this looks fairly consistent to me as the
processor simply derives the error code width from the corresponding
entry in the IDT.

Jan

-- 
Siemens AG, Corporate Technology, CT T DE IT 1
Corporate Competence Center Embedded Linux

  parent reply	other threads:[~2010-04-14 13:19 UTC|newest]

Thread overview: 15+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2010-04-14 12:11 KVM: x86: Push potential exception error code on task switches Jan Kiszka
2010-04-14 12:22 ` Avi Kivity
2010-04-14 12:37   ` Jan Kiszka
2010-04-14 12:39     ` Jan Kiszka
2010-04-14 12:52     ` Avi Kivity
2010-04-14 12:58       ` Jan Kiszka
2010-04-14 13:07         ` Avi Kivity
2010-04-14 13:08           ` Avi Kivity
2010-04-14 13:19           ` Jan Kiszka [this message]
2010-04-15  8:41             ` Avi Kivity
2010-04-15  8:47               ` Jan Kiszka
2010-04-14 12:38 ` Gleb Natapov
2010-04-14 12:43   ` Jan Kiszka
2010-04-14 13:00   ` Jan Kiszka
2010-04-14 14:09     ` Gleb Natapov

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=4BC5C0E0.6000805@siemens.com \
    --to=jan.kiszka@siemens.com \
    --cc=avi@redhat.com \
    --cc=gleb@redhat.com \
    --cc=kvm@vger.kernel.org \
    --cc=mtosatti@redhat.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