Skip site navigation (1)Skip section navigation (2)
Date:      Wed, 30 Oct 1996 14:13:01 -0500
From:      Luoqi Chen <luoqi@watermarkgroup.com>
To:        hackers@freebsd.org
Subject:   wine crash mystery
Message-ID:  <3277A807.7FE8@watermarkgroup.com>

next in thread | raw e-mail | index | archive | help
Hi,

I have been playing with wine recently. I noticed that wine would
mysteriously crash my machine whenever I tried to run wine with
a non-existing exe file (it was a typo initially). It seemed that
wine had somehow triggered the shutdown condition on the cpu,
because there was no panic when the system crashed.

According to the 80x86 manual, this shutdown condition is caused
by a triple fault -- fault while trying to execute double fault
exception vector. Now I have a few questions I hope more experienced 
hackers out there can help me on.

1. For the double fault to occur, an LDT entry has to be corrupted.
After looking at the kernel sources, I could see one reason this
might happen. In sys_machdep.c, syscall i386_set_ldt does NOT load
new ldt immediately, instead it relies on swtch to do the trick.
Chances are one of the new selectors is referenced before rescheduling
has taken place. There is a commented out need_reschedule() call
in the code, could anyone tell me why it is commented out?

2. Another reason could be the user LDT is not incore. Is this
possible? I see user ldt are allocated from kernel map, does it
mean user ldt should always be resident? How is it handled in
FreeBSD when the 2nd fault is a page fault?

3. For the shutdown condition to occur, the IDT vector for double
fault should also be corrupted. How could this happen?

I am running wine961023 on FreeBSD 2.1.5R. Do you fellow wine
users have the same crashes? I'm really interested in solving
this problem. Any advice is greatly appreciated.

Thanks
-lq



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?3277A807.7FE8>