public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
From: Kasper Dupont <kasperd@daimi.au.dk>
To: stas.orel@mailcity.com, linux-kernel@vger.kernel.org
Subject: Re: [patch] vm86: Clear AC on INT
Date: Thu, 01 Aug 2002 15:43:34 +0200	[thread overview]
Message-ID: <3D493B06.3C20A88@daimi.au.dk> (raw)
In-Reply-To: 3D4419F5.3000104@yahoo.com

Stas Sergeev wrote:
> 
> Hello.
> 
> According to this:
> http://support.intel.com/design/intarch/techinfo/Pentium/instrefi.htm#89126
> AC flag is cleared by an INT
> instruction executed in real mode.
> The attached patch implements that
> functionality and solves some
> problems recently discussed in
> dosemu mailing list.

This sounds a little strange to me. AC is in the upper 16 bit
of the EFLAGS register, so it is not saved on an interrupt
where only lower 16 bits is saved. This means that when we
clear it on the interrupt, the value will be lost for good.

I can see the spec says it, so we'd better do that. But does
the spec make any sense? And does the CPU really loose the
AC flag on every interrupt in real mode?

A few other things got me wondering, it says there is tested
for enough space in the stack. Does this mean something like
if (SP<6) trap(); ? If it does, we should change do_int to
actually do this. And how should we actually trap if there
is not enough space for pushing values?

And does this testing apply to other instructions as well?

And it also says the IDT size is tested. But does that
concept even exist in real mode?

And finally, why do we have a 32 bit IRET instruction, but
no 32 bit INT instruction? Is that really correct?

-- 
Kasper Dupont -- der bruger for meget tid på usenet.
For sending spam use mailto:razrep@daimi.au.dk
or mailto:mcxumhvenwblvtl@skrammel.yaboo.dk

  parent reply	other threads:[~2002-08-01 13:40 UTC|newest]

Thread overview: 15+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2002-07-28 16:21 [patch] vm86: Clear AC on INT Stas Sergeev
2002-08-01 12:19 ` Kasper Dupont
2002-08-01 13:43 ` Kasper Dupont [this message]
2002-08-01 15:15   ` Richard B. Johnson
2002-08-01 15:49     ` Kasper Dupont
2002-08-01 16:52     ` Alan Cox
2002-08-01 15:55       ` Kasper Dupont
2002-08-01 17:28         ` Alan Cox
2002-08-01 16:21           ` Kasper Dupont
2002-08-01 16:40             ` Maciej W. Rozycki
2002-08-01 17:04               ` Kasper Dupont
2002-08-01 17:38                 ` Richard B. Johnson
2002-08-01 17:48                   ` Kasper Dupont
2002-08-01 17:47             ` Alan Cox
2002-08-01 16:33   ` Maciej W. Rozycki

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=3D493B06.3C20A88@daimi.au.dk \
    --to=kasperd@daimi.au.dk \
    --cc=linux-kernel@vger.kernel.org \
    --cc=stas.orel@mailcity.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