qemu-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Qemu-devel] Register uhci_reset() callback.


From: Jamie Lokier
Subject: Re: [Qemu-devel] Register uhci_reset() callback.
Date: Tue, 16 Jun 2009 16:43:00 +0100
User-agent: Mutt/1.5.13 (2006-08-11)

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 via email to

[Prev in Thread] Current Thread [Next in Thread]