about summary refs log tree commit diff
path: root/src/thread
diff options
context:
space:
mode:
Diffstat (limited to 'src/thread')
-rw-r--r--src/thread/i386/__set_thread_area.s6
1 files changed, 5 insertions, 1 deletions
diff --git a/src/thread/i386/__set_thread_area.s b/src/thread/i386/__set_thread_area.s
index ad538151..1d852689 100644
--- a/src/thread/i386/__set_thread_area.s
+++ b/src/thread/i386/__set_thread_area.s
@@ -6,7 +6,11 @@ __set_thread_area:
 	push $0x51
 	push $0xfffff
 	push 16(%esp)
-	push $-1
+	xor %edx,%edx
+	mov %gs,%dx
+	sub $3,%edx
+	sar $3,%edx
+	push %edx
 	mov %esp,%ebx
 	xor %eax,%eax
 	mov $243,%al