With these in place we appear to be good except for some kind of net
breakage that needs resolving.
.import _inint
.import _platform_monitor
.import _platform_switchout
+ .import _chksigs
.import push0
.import incaxy
lda #1
sta U_DATA__U_INSYS
;
+ ; Check for signals (the kstack is sane at this point)
+ ;
+ jsr _chksigs
+ ;
; Mark outselves as idle
;
ldx U_DATA__U_PTAB
; Pre emption occurs on the task stack. Conceptually its a
; not quite a syscall
lds #kstack_top
+ jsr _chksigs ; check signal state
+ ;
ldx U_DATA__U_PTAB
; Move to ready state
lda #P_READY
ldd istack_switched_sp
std U_DATA__U_SYSCALL_SP
lds #kstack_top
+ jsr chksigs
ldx U_DATA__U_PTAB
ldab #P_READY
stab P_TAB__P_STATUS_OFFSET,x
- jsr switchout
+ jsr platform_switchout
jsr map_process_always
; caller will switch back to stack in X
ldx U_DATA__U_SYSCALL_SP
;
intret2:call map_kernel
-
;
; Semantically we are doing a null syscall for pre-empt. We need
; to record ourselves as in a syscall so we can't be recursively
;
ld a, #1
ld (U_DATA__U_INSYS), a
+ ;
+ ; Check for signals
+ ;
+ push af
+ call chksigs
+ pop af
+
;
; Process status is offset 0
;
;
intret2:call map_kernel
-
;
; Semantically we are doing a null syscall for pre-empt. We need
; to record ourselves as in a syscall so we can't be recursively
ld a, #1
ld (U_DATA__U_INSYS), a
;
+ ; Check for signals
+ ;
+ call _chksigs
+ ;
; Process status is offset 0
;
ld hl, (U_DATA__U_PTAB)