irq.h
Go to the documentation of this file.
1 /*
2  * Copyright (C) 2013 Freie Universit├Ąt Berlin
3  *
4  * This file is subject to the terms and conditions of the GNU Lesser
5  * General Public License v2.1. See the file LICENSE in the top level
6  * directory for more details.
7  */
8 
21 #ifndef IRQ_H
22 #define IRQ_H
23 
24 #include <stdbool.h>
25 
26 #ifdef __cplusplus
27  extern "C" {
28 #endif
29 
39 unsigned irq_disable(void);
40 
50 unsigned irq_enable(void);
51 
61 void irq_restore(unsigned state);
62 
67 int irq_is_in(void);
68 
69 #ifdef __cplusplus
70 }
71 #endif
72 
73 #endif /* IRQ_H */
74 
void irq_restore(unsigned state)
This function restores the IRQ disable bit in the status register to the value contained within passe...
int irq_is_in(void)
Check whether called from interrupt service routine.
unsigned irq_enable(void)
This function clears the IRQ disable bit in the status register.
unsigned irq_disable(void)
This function sets the IRQ disable bit in the status register.