aboutsummaryrefslogtreecommitdiff
path: root/src/cpu
diff options
context:
space:
mode:
authorChristian Cunningham <cc@localhost>2021-12-21 20:22:40 -0800
committerChristian Cunningham <cc@localhost>2021-12-21 20:22:40 -0800
commite43a2696a9eb948f7e08674da766d8971bd4d296 (patch)
tree160c7e266d2bd57c440b8402bf4a2902cd313c6e /src/cpu
parent8e52f3ff03eeaac35a9d7a792cdedff6a92434b4 (diff)
Moved IRQ inlines
Diffstat (limited to 'src/cpu')
-rw-r--r--src/cpu/irq.h13
1 files changed, 13 insertions, 0 deletions
diff --git a/src/cpu/irq.h b/src/cpu/irq.h
index 0403038..971d0b9 100644
--- a/src/cpu/irq.h
+++ b/src/cpu/irq.h
@@ -1,6 +1,19 @@
#ifndef CPU_IRQ_H
#define CPU_IRQ_H
+static inline void enableirq() {
+ asm volatile("cpsie i");
+}
+static inline void disableirq() {
+ asm volatile("cpsid i");
+}
+static inline void enablefiq() {
+ asm volatile("cpsie f");
+}
+static inline void disablefiq() {
+ asm volatile("cpsid f");
+}
+
void c_irq_handler(void);
#endif