1 |*****************************************************************************
5 | __AROS_LH0(APTR
, SuperState
,
10 | struct ExecBase
*, SysBase
, 25, Exec
)
13 | Enter supervisor
mode (like
Supervisor()), but
return on the normal
14 | user stack
, so that user stack variables are still there
. A call
15 | to
Userstate() will end
this mode
.
20 | Old supervisor stack
. NULL
if called from supervisor mode
.
23 | The user stack must be big enough to hold all possible nestings
31 | UserState(), Supervisor()
37 |******************************************************************************
41 .globl _Exec_SuperState
43 | Goto supervisor mode
. Preserve a5 in
d0 (faster than stack space
)
47 | Do
not change user stack
- use jmp
53 | Check
if called from supervisor mode
57 | Called from supervisor mode
. Just
return NULL
.
62 | Called from user mode
. Restore sp
and return supervisor sp
.
66 | usp already points to the returnaddress
for the
SuperState() call
.