2 Copyright © 1995-2001, The AROS Development Team. All rights reserved.
5 Desc: Enable() - Allow interrupts to occur after Disable().
9 #include <exec/types.h>
10 #include <exec/execbase.h>
11 #include <aros/libcall.h>
12 #include <asm/registers.h>
15 #include <aros/debug.h>
17 /*****************************************************************************/
24 #include <proto/exec.h>
26 AROS_LH0(void, Enable
,
29 struct ExecBase
*, SysBase
, 21, Exec
)
32 This function will allow interrupts to occur after they have
33 been disabled by Disable().
35 Note that calls to Disable() nest, and for every call to
36 Disable() you need a matching call to Enable().
40 Using this function is considered very harmful, and it is
41 not recommended to use this function for ** ANY ** reason.
43 It is quite possible to either crash the system, or to prevent
44 normal activities (disk/port i/o) from occuring.
46 Note: As taskswitching is driven by the interrupts subsystem,
47 this function has the side effect of disabling
54 Interrupts will be enabled again when this call returns.
57 This function preserves all registers.
59 To prevent deadlocks calling Wait() in disabled state breaks
60 the disable - thus interrupts may happen again.
63 No you DEFINITATELY don't want to use this function.
66 The only architecture that you can rely on the registers being
67 saved is on the Motorola mc68000 family.
70 Forbid(), Permit(), Disable(), Wait()
73 This function must be replaced in the $(KERNEL) or $(ARCH)
74 directories in order to do some work.
78 ******************************************************************************/
84 if( --SysBase
->IDNestCnt
< 0) {
86 * Enable interrupt by allowing all of them.