qemu-devel.nongnu.org archive mirror
 help / color / mirror / Atom feed
From: Jamie Lokier <jamie@shareable.org>
To: Avi Kivity <avi@redhat.com>
Cc: Paul Brook <paul@codesourcery.com>,
	Gleb Natapov <gleb@redhat.com>,
	qemu-devel@nongnu.org
Subject: Re: [Qemu-devel] Register uhci_reset() callback.
Date: Tue, 16 Jun 2009 16:43:00 +0100	[thread overview]
Message-ID: <20090616154300.GK29040@shareable.org> (raw)
In-Reply-To: <4A37B7B9.5050105@redhat.com>

Avi Kivity wrote:
> On 06/16/2009 06:00 PM, Jamie Lokier wrote:
> >Avi Kivity wrote:
> >   
> >>On 06/11/2009 07:40 PM, Gleb Natapov wrote:
> >>     
> >>>>Now, a CPU-only reset, such as triple fault on x86, that's a bit
> >>>>different.
> >>>>
> >>>>
> >>>>         
> >>>On x86 triple fault wired to system reset.
> >>>
> >>>       
> >>Some actually wire triple fault (shutdown) to init.  It's pretty broken.
> >>     
> >
> >That sounds useful, actually, for those 286 OSes which use
> >triple-fault to switch from protected mode to real mode.  No need to
> >reinitialise all the hardware if it just restarts the CPU.
> >   
> 
> Ah, I remember now.  But on modern hardware it breaks badly.  Intel 
> processors block INIT if vmx is enabled, and the rest of the hardware 
> isn't reset so it could be dmaing all over the place.

When running 286 code, continuing to DMA is actually correct if using
triple-fault to switch to real mode.  (Yes I still have some 286 code
lying around somewhere).  It's to context switch, not stop devices :-)

Obviously nowadays if you have 286 code that you need to run, you'd
run it in a VM, not real hardware, so that backward compatibility is
quite unnecessary now, and actively unhelpful.

But a VM should offer it, either as an option or always, so you can
run old 286 code in the VM.

Perhaps the ideal thing to do in a VM (i.e. QEMU) is map triple-fault
to CPU reset and BIOS fast restart when in 286 protected mode, and map
triple-fault to full system reset when not in 286 protected mode.

-- Jamie

  reply	other threads:[~2009-06-16 15:43 UTC|newest]

Thread overview: 39+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2009-06-11  8:48 [Qemu-devel] Register uhci_reset() callback Gleb Natapov
2009-06-11 13:41 ` Paul Brook
2009-06-11 13:46   ` Gleb Natapov
2009-06-11 13:53     ` Paul Brook
2009-06-11 14:00       ` Gleb Natapov
2009-06-11 16:38         ` Jamie Lokier
2009-06-11 16:40           ` Gleb Natapov
2009-06-15 16:20             ` Avi Kivity
2009-06-16 15:00               ` Jamie Lokier
2009-06-16 15:18                 ` Avi Kivity
2009-06-16 15:43                   ` Jamie Lokier [this message]
2009-06-15 16:21     ` Avi Kivity
2009-06-15 17:02       ` Gleb Natapov
2009-06-15 17:17         ` Avi Kivity
2009-06-15 17:21           ` Gleb Natapov
2009-06-15 17:56         ` Paul Brook
2009-06-15 18:16           ` Gleb Natapov
2009-06-15 18:57             ` Blue Swirl
2009-06-15 19:30               ` Gleb Natapov
2009-06-15 19:50                 ` Blue Swirl
2009-06-15 20:05                   ` Gleb Natapov
2009-06-16 15:14                     ` Blue Swirl
2009-06-16 15:20                       ` Gleb Natapov
2009-06-16 16:54                         ` Blue Swirl
2009-06-16 17:09                           ` Gleb Natapov
2009-06-16 17:19                             ` Blue Swirl
2009-06-16 18:39                               ` Gleb Natapov
2009-06-18  9:20                               ` Avi Kivity
2009-06-16 16:54                         ` Paul Brook
2009-06-16 17:12                           ` Blue Swirl
2009-06-16 18:00                             ` Paul Brook
2009-06-16 18:10                               ` Blue Swirl
2009-06-16 18:52                                 ` Jamie Lokier
2009-06-16 19:05                                   ` Jamie Lokier
2009-06-16 19:10                                     ` Blue Swirl
2009-06-16 19:23                                       ` Gleb Natapov
2009-06-16 19:16                                   ` Paul Brook
2009-06-16 17:47                           ` Gleb Natapov
2009-06-16 17:04                 ` Paul Brook

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=20090616154300.GK29040@shareable.org \
    --to=jamie@shareable.org \
    --cc=avi@redhat.com \
    --cc=gleb@redhat.com \
    --cc=paul@codesourcery.com \
    --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).