Re: Sanitize CPU-state when switching from virtual-8086 mode to other task

2013-12-31 Thread H. Peter Anvin
On 12/31/2013 11:21 AM, Konrad Rzeszutek Wilk wrote: > > So, I am wondering if this is related to " x86/fpu: CR0.TS should be set > before trap > into PV guest's #NM exception handle" which does have a similar pattern - you > do enough of the task switches and the FPU is screwed. > > See > http

Re: Sanitize CPU-state when switching from virtual-8086 mode to other task

2013-12-31 Thread Konrad Rzeszutek Wilk
On Tue, Dec 31, 2013 at 10:42:47AM -0800, H. Peter Anvin wrote: > On 12/30/2013 07:52 AM, halfdog wrote: > >> > >> Still in VirtualBox? > > > > Yes, again: after comparing the results from initrd on real hardware > > with Vbox, I'm getting to understand the timing problem involved and why > > timi

Re: Sanitize CPU-state when switching from virtual-8086 mode to other task

2013-12-31 Thread H. Peter Anvin
On 12/30/2013 07:52 AM, halfdog wrote: >> >> Still in VirtualBox? > > Yes, again: after comparing the results from initrd on real hardware > with Vbox, I'm getting to understand the timing problem involved and why > timing in VBox is different: The test program usually OOPSes when > touching FPU m

Re: Sanitize CPU-state when switching from virtual-8086 mode to other task

2013-12-30 Thread halfdog
H. Peter Anvin wrote: > On 12/29/2013 12:44 PM, halfdog wrote: >> H. Peter Anvin wrote: >>> On 12/28/2013 02:02 PM, halfdog wrote: It seems that missing CPU-state sanitation during task switching triggers kernel-panic. This might be related to unhandled FPU-errors. See [1] for POC

Re: Sanitize CPU-state when switching from virtual-8086 mode to other task

2013-12-29 Thread H. Peter Anvin
On 12/29/2013 12:44 PM, halfdog wrote: > H. Peter Anvin wrote: >> On 12/28/2013 02:02 PM, halfdog wrote: >>> It seems that missing CPU-state sanitation during task >>> switching triggers kernel-panic. This might be related to >>> unhandled FPU-errors. See [1] for POC and serial console log >>> of

Re: Sanitize CPU-state when switching from virtual-8086 mode to other task

2013-12-29 Thread halfdog
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 H. Peter Anvin wrote: > On 12/28/2013 02:02 PM, halfdog wrote: >> It seems that missing CPU-state sanitation during task switching >> triggers kernel-panic. This might be related to unhandled >> FPU-errors. See [1] for POC and serial console log of O

Re: Sanitize CPU-state when switching from virtual-8086 mode to other task

2013-12-28 Thread H. Peter Anvin
On 12/28/2013 02:02 PM, halfdog wrote: > It seems that missing CPU-state sanitation during task switching > triggers kernel-panic. This might be related to unhandled > FPU-errors. See [1] for POC and serial console log of OOPs. Due to > missing real 32-bit x86-hardware it is not clear, if this iss