aboutsummaryrefslogtreecommitdiff
path: root/src
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
parent8e52f3ff03eeaac35a9d7a792cdedff6a92434b4 (diff)
Moved IRQ inlines
Diffstat (limited to 'src')
-rw-r--r--src/cpu/irq.h13
-rw-r--r--src/sys/core.h13
2 files changed, 13 insertions, 13 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
diff --git a/src/sys/core.h b/src/sys/core.h
index 3727a2b..d720e17 100644
--- a/src/sys/core.h
+++ b/src/sys/core.h
@@ -16,19 +16,6 @@ static inline void delay(unsigned long cycles) {
: "=r"(cycles): [cycles]"0"(cycles) : "cc");
}
-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");
-}
-
enum
{
// The offset for the MMIO area