From: Alan Cox Date: Sat, 30 May 2015 14:23:53 +0000 (+0100) Subject: zx128: update to new interrupt scheme X-Git-Url: https://git.ndcode.org/public/gitweb.cgi?a=commitdiff_plain;h=839b53f15a8ab8294867f54f40a3d562cbf4e096;p=FUZIX.git zx128: update to new interrupt scheme Untested as banked not yet converted --- diff --git a/Kernel/platform-zx128/tricks.s b/Kernel/platform-zx128/tricks.s index d6245590..41519b3c 100644 --- a/Kernel/platform-zx128/tricks.s +++ b/Kernel/platform-zx128/tricks.s @@ -11,7 +11,6 @@ .globl _getproc .globl _trap_monitor .globl trap_illegal - .globl _inint .globl _switchout .globl _switchin .globl _low_bank @@ -59,10 +58,6 @@ _switchout: ; here ; - ; set inint to false - xor a - ld (_inint), a - ; Stash the uarea back into process memory ld hl, (U_DATA__U_PAGE) ld a, l @@ -247,9 +242,9 @@ nofliplow: pop hl ; return code ; enable interrupts, if the ISR isn't already running - ld a, (_inint) + ld a, (U_DATA__U_ININTERRUPT) or a - ret z ; in ISR, leave interrupts off + ret nz ; in ISR, leave interrupts off ei ret ; return with interrupts on diff --git a/Kernel/platform-zx128/zx128.s b/Kernel/platform-zx128/zx128.s index 47a51564..95a4e108 100644 --- a/Kernel/platform-zx128/zx128.s +++ b/Kernel/platform-zx128/zx128.s @@ -23,7 +23,7 @@ .globl current_map .globl switch_bank - .globl _kernel_flag + .globl _need_resched ; exported debugging tools .globl _trap_monitor @@ -288,8 +288,6 @@ outchar: ret _tmpout: .db 1 -_kernel_flag: - .db 1 .area _COMMONDATA current_map: ; place to store current page number. Is needed @@ -301,6 +299,9 @@ map_store: ksave_map: .db 0 +_need_resched: + .db 0 + .area _COMMONMEM ; ; Banking helpers