preemption: rabbit also needs the fix
authorAlan Cox <alan@linux.intel.com>
Mon, 21 Jan 2019 22:19:59 +0000 (22:19 +0000)
committerAlan Cox <alan@linux.intel.com>
Mon, 21 Jan 2019 22:19:59 +0000 (22:19 +0000)
Kernel/lowlevel-rabbit.s

index 3d04d7f..9d1b926 100644 (file)
@@ -490,7 +490,11 @@ preemption:
                ; Process status is offset 0
                ;
                ld hl, (U_DATA__U_PTAB)
+               ld a,(hl)
+               cp #P_RUNNING
+               jr nz, not_running
                ld (hl), #P_READY
+not_running:
                call _platform_switchout
                ;
                ; We are no longer in an interrupt or a syscall