summaryrefslogtreecommitdiff
path: root/kernel/asm.s
diff options
context:
space:
mode:
Diffstat (limited to 'kernel/asm.s')
-rw-r--r--kernel/asm.s7
1 files changed, 2 insertions, 5 deletions
diff --git a/kernel/asm.s b/kernel/asm.s
index 655dcfc..4e1e376 100644
--- a/kernel/asm.s
+++ b/kernel/asm.s
@@ -15,11 +15,7 @@ switch_to:
; abort if we're switching to the current task
mov ebx, [ctask]
cmp ebx, [ebp+12]
- jne .skip
- pop ebx
- pop ebp
- ret
-.skip:
+ je .end
; update ctask and ctaskn
mov ebx, [ebp+12]
mov [ctask], ebx
@@ -31,6 +27,7 @@ switch_to:
shl ebx, 3
mov [.tmp+4], bx
jmp far [.tmp]
+.end:
pop ebx
pop ebp
ret