fix off-by-1 screen title fill
[AROS.git] / rom / exec / doresetcallbacks.c
blob2c4fdbdc80c1477a581b4731bf4e08ab9dd70ef9
1 /*
2 Copyright © 1995-2012, The AROS Development Team. All rights reserved.
3 $Id$
5 Desc: Execute installed reset handlers.
6 Lang: english
7 */
9 #include <aros/asmcall.h>
10 #include <exec/interrupts.h>
12 #include "exec_intern.h"
13 #include "exec_util.h"
16 This function executes installed reset handlers.
17 It stores the supplied shutdown action type (SD_ACTION_#?) in the
18 ln_Type field of each reset interrupt structure. Typically this
19 information is needed by system reset handlers (EFI, ACPI etc.), but
20 not by peripheral-device reset handlers (USB HCs, NICs etc.).
21 For improved safety callbacks are called in a Disable()d state.
22 This function does not need to Enable().
25 void Exec_DoResetCallbacks(struct IntExecBase *IntSysBase, UBYTE action)
27 struct Interrupt *i;
29 Disable();
31 for (i = (struct Interrupt *)IntSysBase->ResetHandlers.lh_Head; i->is_Node.ln_Succ;
32 i = (struct Interrupt *)i->is_Node.ln_Succ)
34 i->is_Node.ln_Type = action;
35 AROS_INTC1(i->is_Code, i->is_Data);