home *** CD-ROM | disk | FTP | other *** search
- #ifndef QUARK_INTERRUPT_H
- #define QUARK_INTERRUPT_H
-
- typedef unsigned long long q_iid_t;
-
- /* Level0=Spurios Amiga Int...that may be
- * used by other unknown sources.
- */
- #define INTID_AMIGA_TBE 0
- #define INTID_AMIGA_DSKBLK 1
- #define INTID_AMIGA_SOFTINT 2
- #define INTID_AMIGA_PORTS 3
- #define INTID_AMIGA_COPER 4
- #define INTID_AMIGA_VERTB 5
- #define INTID_AMIGA_BLIT 6
- #define INTID_AMIGA_AUD0 7
- #define INTID_AMIGA_AUD1 8
- #define INTID_AMIGA_AUD2 9
- #define INTID_AMIGA_AUD3 10
- #define INTID_AMIGA_RBF 11
- #define INTID_AMIGA_DSKSYNC 12
- #define INTID_AMIGA_EXTER 13
- #define INTID_AMIGA_COPPERINTEN 14
- #define INTID_AMIGA_NMI 15
-
- #define INTID_DECREMENTER 16 /* Exclusive */
- #define INTID_SYSTEMANAGEMENT 17 /* Exclusive */
-
- #define INTID_ENTRIES 18
-
-
-
-
-
- /*
- * a shared INT line of units those ints aren`t locked after an
- * Int(so the event can happen again any microsecond).
- * Here..int latency is the factor.
- * While processing Ints the interrupt must be disabled.
- * Example:
- * several microsecond timer share one INT line
- */
-
- #define INTTYPE_QUICK 0
-
-
- /*
- * a shared INT line of units those ints aren`t locked after an
- * Int(so the event can happen again...but NOT at once)n.
- * While processing Ints the interrupt may not be disabled
- * because the same int is unlikely to occur again until it`s
- * handled..even under worst case
- * Example:
- * several vblank timer share one INT line
- */
-
- #define INTTYPE_SLOW 1
-
- /*
- * a shared INT line of units those int causing units are locked
- * after an Int, so we have a lot time to react on these ints and the
- * interrupt must not be disabled.
- * While processing Ints the interrupt can be enabled because
- * the same int won`t occur again.
- * Example:
- * a SCSI controller.
- * Here the scsi stateengine is stopped until the interrupt
- * is handled.
- */
-
- #define INTTYPE_LOCKED 2
-
- /***************************************************************/
-
- #define INTFLAG_RESCHEDULE 0x1
-
-
-
- /***************************************************************/
-
-
-
-
- #define INTTAG_Dummy 0x00001000
-
- /* Name of the Interrupt Server Node
- */
- #define INTTAG_NAME (INTTAG_Dummy+0x0)
-
- /* Ptr to a PCDOE routine which can be used to
- * move the check of the interrupt source into the
- * kernel and therefore cause less thread context switches
- */
- #define INTTAG_PCODE (INTTAG_Dummy+0x1)
-
- /* Allow the thread`s intnode to be rescheduled.
- * This way we would speed up average interrupt
- * processing if the interrupts types which happen
- * the most times are also the first in the shared
- * interrupt chain.
- */
- #define INTTAG_PRIORITY (INTTAG_Dummy+0x2)
-
- /* Allow the thread`s intnode to be rescheduled.
- * This way we would speed up average interrupt
- * processing if the interrupts types which happen
- * the most times are also the first in the shared
- * interrupt chain.
- */
- #define INTTAG_RESCHEDULE (INTTAG_Dummy+0x3)
-
- /* The IntThread is sent a signal instead of
- * being started synchron.
- * Only useful with the PCODE tag.
- * That`s a very easy and quick way to handle
- * ints.
- */
- #define INTTAG_SIGNAL (INTTAG_Dummy+0x4)
-
-
-
- /* The mask which define the
- * base state of an interrupt
- */
- #define WAITINTSTATE_MASK 0x7fff
-
- /* WaitInterrupt(State)
- */
-
- /* No success..go to next entry
- * Interrupt OFF state
- */
- #define WAITINTSTATE_FALSE 0
-
- /* Hit and no other hits possible
- * Interrupt ON/OFF state
- */
- #define WAITINTSTATE_OK_DONE 1
-
-
- /* Hit but there may be more than one hit
- * shared TRUE line..vblank for example
- * Interrupt ON/OFF state
- */
- #define WAITINTSTATE_OK_NEXT 2
-
-
- /* Ignore the entry
- */
- #define WAITINTSTATE_SKIP 0x8000
-
-
- /* Ignore the entry as the thread isn`t
- * done yet.
- * mostly used for reactivating ints very
- * quickly and to return to the Intthread
- * in Interrupt ON state so do some real
- * work. While this work is done other
- * ints ignore this node.
- */
- #define WAITINTSTATE_OK_RETURN 0x8001
-
-
-
- #endif
-
-