From: Alan Cox Date: Fri, 10 Aug 2018 23:32:42 +0000 (+0100) Subject: z80fixedbank-banked: apply the same SP fix as to the main fixedbank code X-Git-Url: https://git.ndcode.org/public/gitweb.cgi?a=commitdiff_plain;h=0df9fc570cb4990463a12680c81ad7896bdc32e3;p=FUZIX.git z80fixedbank-banked: apply the same SP fix as to the main fixedbank code --- diff --git a/Kernel/lib/z80fixedbank-banked.s b/Kernel/lib/z80fixedbank-banked.s index bd0b4ac2..54a7ecb6 100644 --- a/Kernel/lib/z80fixedbank-banked.s +++ b/Kernel/lib/z80fixedbank-banked.s @@ -159,6 +159,11 @@ not_swapped: ldir exx + ; Restore the stack in case we are not swap based so we don't + ; scribble the bank stack + + ld sp, (U_DATA__U_SP) + call map_kernel_restore ; check u_data->u_ptab matches what we wanted @@ -183,7 +188,6 @@ skip_copyback: ; restore machine state -- note we may be returning from either ; _switchout or _dofork - ld sp, (U_DATA__U_SP) pop af pop iy