Unit testing framework and devicetree framework refactoring (#50)
[lunaix-os.git] / lunaix-os / arch / x86 / includes / asm / x86_isrm.h
1 #ifndef __LUNAIX_X86_ISRM_H
2 #define __LUNAIX_X86_ISRM_H
3
4 #include <asm-generic/isrm.h>
5
6 /**
7  * @brief Bind a given irq and associated handler to an iv
8  *
9  * @param iv iv allocated by system
10  */
11 int
12 isrm_bindirq(int irq, isr_cb irq_handler);
13
14 /**
15  * @brief Bind given iv with it's associated handler
16  *
17  * @param iv
18  * @param handler
19  */
20 void
21 isrm_bindiv(int iv, isr_cb handler);
22
23 void
24 isrm_irq_attach(int irq, int iv, cpu_t dest, u32_t flags);
25
26 /**
27  * @brief Allocate an iv resource for os services
28  *
29  * @param iv
30  */
31 int
32 isrm_ivosalloc(isr_cb handler);
33
34 /**
35  * @brief Allocate an iv resource for external events
36  *
37  * @param iv
38  */
39 int
40 isrm_ivexalloc(isr_cb handler);
41
42 #endif /* __LUNAIX_X86_ISRM_H */