From 27c2878d0b3ca1a4cb148c7901d2e09c75c2e23d Mon Sep 17 00:00:00 2001 From: Matt Harlum Date: Mon, 2 Jun 2025 08:20:00 +0000 Subject: [PATCH] Get first configdev before restoring SP Previously it was read after restoring the stack pointer, if an interrupt occured the data would have been overwritten --- source/AT-Apollo.device_v5.03.s | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/source/AT-Apollo.device_v5.03.s b/source/AT-Apollo.device_v5.03.s index 7414654..2fecc8b 100644 --- a/source/AT-Apollo.device_v5.03.s +++ b/source/AT-Apollo.device_v5.03.s @@ -330,11 +330,10 @@ InitRoutine move.l a7,a0 ;A0: CurrentBinding structure move.l #CurrentBinding_SIZEOF,d0 ;D0: Size of CurrentBinding jsr _LVOGetCurrentBinding(a6) - move.l a7,a0 ;Restore CurrentBinding pointer + move.l cb_ConfigDev(a7),a0 ;A0: First ConfigDev add.l #CurrentBinding_SIZEOF,a7 ;Restore stack pointer tst.l d0 beq.w .End ;No binding, end - move.l cb_ConfigDev(a0),a0 ;A0: First ConfigDev .Loop cmp.l #0,a0 ;Check if ConfigDev exists