summaryrefslogtreecommitdiff
path: root/Source/Kernel/SyscallManager/IDT.wtf.asm
diff options
context:
space:
mode:
authorAlexis211 <alexis211@gmail.com>2009-08-29 13:39:06 +0200
committerAlexis211 <alexis211@gmail.com>2009-08-29 13:39:06 +0200
commitc92beeedda51487696ce476ee30604f22e7b2270 (patch)
tree29b89d31b0b35792e1ed2bc5861be0439e7e40d9 /Source/Kernel/SyscallManager/IDT.wtf.asm
parent5deab22107fc38bd2bea19f07889b14c376754e0 (diff)
downloadMelon-c92beeedda51487696ce476ee30604f22e7b2270.tar.gz
Melon-c92beeedda51487696ce476ee30604f22e7b2270.zip
The Melon kernel now has support for simple multitasking
Diffstat (limited to 'Source/Kernel/SyscallManager/IDT.wtf.asm')
-rw-r--r--Source/Kernel/SyscallManager/IDT.wtf.asm13
1 files changed, 12 insertions, 1 deletions
diff --git a/Source/Kernel/SyscallManager/IDT.wtf.asm b/Source/Kernel/SyscallManager/IDT.wtf.asm
index b76d912..7980d13 100644
--- a/Source/Kernel/SyscallManager/IDT.wtf.asm
+++ b/Source/Kernel/SyscallManager/IDT.wtf.asm
@@ -28,7 +28,7 @@ idt_flush:
%endmacro
%macro IRQ 2
- global irq%1
+ [GLOBAL irq%1]
irq%1:
cli
push byte 0
@@ -36,6 +36,15 @@ idt_flush:
jmp interrupt_common_stub
%endmacro
+%macro SYSCALL 1
+ [GLOBAL int%1]
+ int%1:
+ cli
+ push byte 0
+ push byte %1
+ jmp interrupt_common_stub
+%endmacro
+
; ********************************************************************
ISR_NOERRCODE 0
@@ -88,6 +97,8 @@ IRQ 13, 45
IRQ 14, 46
IRQ 15, 47
+SYSCALL 64 ; this syscall requests a task switch
+
; ******************************************************************
interrupt_common_stub: