00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018
00019
00020 #ifndef _RTAI_NUCLEUS_INTR_H
00021 #define _RTAI_NUCLEUS_INTR_H
00022
00023 #include <nucleus/types.h>
00024
00025 #define XN_ISR_HANDLED 0x0
00026 #define XN_ISR_CHAINED 0x1
00027 #define XN_ISR_ENABLE 0x2
00028
00029 #if defined(__KERNEL__) || defined(__RTAI_UVM__) || defined(__RTAI_SIM__)
00030
00031 struct xnintr;
00032
00033 typedef struct xnintr {
00034
00035 unsigned irq;
00036
00037 xnisr_t isr;
00038
00039 xniack_t iack;
00040
00041 unsigned long hits;
00042
00043 void *cookie;
00044
00045 } xnintr_t;
00046
00047 extern xnintr_t nkclock;
00048
00049 #ifdef __cplusplus
00050 extern "C" {
00051 #endif
00052
00053 void xnintr_clock_handler(void);
00054
00055
00056
00057 int xnintr_init(xnintr_t *intr,
00058 unsigned irq,
00059 xnisr_t isr,
00060 xniack_t iack,
00061 xnflags_t flags);
00062
00063 int xnintr_destroy(xnintr_t *intr);
00064
00065 int xnintr_attach(xnintr_t *intr,
00066 void *cookie);
00067
00068 int xnintr_detach(xnintr_t *intr);
00069
00070 int xnintr_enable(xnintr_t *intr);
00071
00072 int xnintr_disable(xnintr_t *intr);
00073
00074 xnarch_cpumask_t xnintr_affinity(xnintr_t *intr,
00075 xnarch_cpumask_t cpumask);
00076
00077 #ifdef __cplusplus
00078 }
00079 #endif
00080
00081 #endif
00082
00083 #endif