summaryrefslogtreecommitdiff
path: root/swtch.S
diff options
context:
space:
mode:
Diffstat (limited to 'swtch.S')
-rw-r--r--swtch.S4
1 files changed, 4 insertions, 0 deletions
diff --git a/swtch.S b/swtch.S
index 786e9ac..8aa4c2e 100644
--- a/swtch.S
+++ b/swtch.S
@@ -16,10 +16,14 @@ swtch:
movl %esi, 20(%eax)
movl %edi, 24(%eax)
movl %ebp, 28(%eax)
+ movl %ss, %ebx
+ movl %ebx, 32(%eax)
# Load new registers
movl 4(%esp), %eax # not 8(%esp) - popped return address above
+ movl 32(%eax), %ebx
+ movl %ebx, %ss
movl 28(%eax), %ebp
movl 24(%eax), %edi
movl 20(%eax), %esi