make sure that the stack page is in place before disabling interrupts.
git-svn-id: file:///srv/svn/repos/haiku/trunk/current@2125 a95241bf-73f2-0310-859d-f6bbb57e9c96
This commit is contained in:
@@ -189,6 +189,11 @@ arch_thread_enter_uspace(addr entry, void *args, addr ustack_top)
|
|||||||
|
|
||||||
// make sure the fpu is in a good state
|
// make sure the fpu is in a good state
|
||||||
asm("fninit");
|
asm("fninit");
|
||||||
|
|
||||||
|
// access the new stack to make sure the memory page is present
|
||||||
|
// while interrupts are disabled.
|
||||||
|
// XXX does this belong there, should caller take care of it?
|
||||||
|
*(uint32 *)(ustack_top - 8) = 0;
|
||||||
|
|
||||||
disable_interrupts();
|
disable_interrupts();
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user