public
/
FUZIX.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
261e0ea
)
Kernel: Bug fix -- on system call, touch kernel_flag only after switching to the...
author
Will Sowerbutts
<will@sowerbutts.com>
Sat, 27 Dec 2014 11:26:25 +0000
(11:26 +0000)
committer
Will Sowerbutts
<will@sowerbutts.com>
Sat, 27 Dec 2014 11:40:28 +0000
(11:40 +0000)
Kernel/lowlevel-z80.s
patch
|
blob
|
history
diff --git
a/Kernel/lowlevel-z80.s
b/Kernel/lowlevel-z80.s
index
3088cdc
..
c43c4f6
100644
(file)
--- a/
Kernel/lowlevel-z80.s
+++ b/
Kernel/lowlevel-z80.s
@@
-77,10
+77,6
@@
unix_syscall_entry:
push ix
push iy
- ; make sure the interrupt logic knows we are in kernel mode
- ld a, #1
- ld (_kernel_flag), a
-
; locate function call arguments on the userspace stack
ld hl, #18 ; 16 bytes machine state, plus 2 bytes return address
add hl, sp
@@
-103,6
+99,10
@@
unix_syscall_entry:
; map in kernel keeping common
call map_kernel
+ ; make sure the interrupt logic knows we are in kernel mode (flag lives in kernel bank)
+ ld a, #1
+ ld (_kernel_flag), a
+
; re-enable interrupts
ei