qemu-devel.nongnu.org archive mirror
 help / color / mirror / Atom feed
From: Jamie Lokier <jamie@shareable.org>
To: qemu-devel@nongnu.org
Subject: Re: [Qemu-devel] Re: [PATCH] Reboot CPU on triple fault
Date: Wed, 16 Apr 2008 12:34:58 +0100	[thread overview]
Message-ID: <20080416113458.GA29762@shareable.org> (raw)
In-Reply-To: <4805CC9B.7050809@suse.de>

Kevin Wolf wrote:
> > Not many, only those users running old MS-DOS apps / OSes.
> 
> MS-DOS is running in Real Mode, you'd additionally need an application
> which uses 286 PM. Apparently there aren't too many users relying on
> triple faults as in the past qemu aborted (or in earlier versions even
> hung) on triple faults and nobody complained.

That's true. I think they use Bochs instead.

> > For old MS-DOS apps / OSes, I have the impression this can happen
> > hundreds of times per second.  It's part of task context switching and
> > BIOS calls.
> 
> I have to admit that I'm all but an 286 PM expert. What exactly is a
> triple fault doing there? If it leads to a reset as implemented here, I
> can hardly imagine that it is of much use in regular context switching.

CPU reset is the only way to exit 286 protected mode, and that is
needed when context switching between real and protected mode tasks.

So apps set a byte in the CMOS NVRAM, trigger a processor reset, then
the BIOS reset code immediately jumps back to the app in real mode,
avoiding the normal reboot process.

It's slow and silly, but faster than the other method, asking the
keyboard controller to do it.

-- Jamie

  parent reply	other threads:[~2008-04-16 11:35 UTC|newest]

Thread overview: 40+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2008-03-29 18:13 [Qemu-devel] [PATCH] Reboot CPU on triple fault Hervé Poussineau
2008-03-30  1:36 ` Alexander Graf
2008-03-31  9:52   ` Kevin Wolf
2008-04-15 16:05     ` [Qemu-devel] " Jan Kiszka
2008-04-15 16:57       ` Paul Brook
2008-04-16  8:37         ` Kevin Wolf
2008-04-16  9:23           ` Jamie Lokier
2008-04-16  9:51             ` Antoine Kaufmann
2008-04-16  9:53             ` Kevin Wolf
2008-04-16 10:17               ` Michal Schulz
2008-04-16 10:25                 ` Michal Schulz
2008-04-16 12:08                 ` Kevin Wolf
2008-04-16 10:22               ` Jan Kiszka
2008-04-16 11:34               ` Jamie Lokier [this message]
2008-04-16 14:44         ` Anthony Liguori
2008-04-16  8:18       ` Kevin Wolf
2008-04-16 12:02         ` Jan Kiszka
2008-04-16 12:09           ` Avi Kivity
2008-04-16 12:36           ` Kevin Wolf
2008-04-16 12:57             ` Jamie Lokier
2008-04-16 12:44       ` [Qemu-devel] [PATCH] x86: Reboot CPU on triple fault - Version 3 Jan Kiszka
2008-04-16 13:35         ` [Qemu-devel] [PATCH] x86: Reboot CPU on triple fault - Version 4 Kevin Wolf
2008-04-16 14:18           ` [Qemu-devel] " Jan Kiszka
2008-04-16 14:33             ` [Qemu-devel] [PATCH] x86: Reboot CPU on triple fault - Version 5 Kevin Wolf
2008-04-16 14:57               ` [Qemu-devel] [PATCH] x86: Reboot CPU on triple fault - Version 6 Kevin Wolf
2008-04-17  9:52                 ` [Qemu-devel] " Jan Kiszka
2008-04-18 14:06                 ` [Qemu-devel] " Anthony Liguori
2008-04-21 11:53                   ` Kevin Wolf
2008-05-26 14:46                     ` [Qemu-devel] " Jan Kiszka
2008-05-27 16:01                       ` [Qemu-devel] [PATCH] x86: Reboot CPU on triple fault - Version 8 Jan Kiszka
2008-05-27 16:17                         ` [Qemu-devel] " Jan Kiszka
2008-04-16 14:37           ` [Qemu-devel] Re: [PATCH] x86: Reboot CPU on triple fault - Version 4 Anthony Liguori
2008-04-17  8:07             ` Jan Kiszka
2008-04-17 12:49               ` Anthony Liguori
2008-04-17 14:10                 ` Jan Kiszka
2008-04-17 18:30                   ` Anthony Liguori
2008-04-17 19:24                     ` Jan Kiszka
2008-04-18  8:38                     ` Kevin Wolf
2008-04-18 14:08                       ` Anthony Liguori
2008-04-21  9:37                         ` Kevin Wolf

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=20080416113458.GA29762@shareable.org \
    --to=jamie@shareable.org \
    --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).