aboutsummaryrefslogtreecommitdiff
path: root/VexRiscvSocSoftware/libs/interrupt.h
diff options
context:
space:
mode:
authorFriedrich Beckmann <friedrich.beckmann@hs-augsburg.de>2022-07-25 17:55:39 +0200
committerFriedrich Beckmann <friedrich.beckmann@hs-augsburg.de>2022-07-25 17:55:39 +0200
commit3fff6023602822531efdae30bc8ebf862967f1ef (patch)
tree16028102b8d850f8ab3115d28a8539ca6bc5f51d /VexRiscvSocSoftware/libs/interrupt.h
Initial Commit
Diffstat (limited to 'VexRiscvSocSoftware/libs/interrupt.h')
-rw-r--r--VexRiscvSocSoftware/libs/interrupt.h17
1 files changed, 17 insertions, 0 deletions
diff --git a/VexRiscvSocSoftware/libs/interrupt.h b/VexRiscvSocSoftware/libs/interrupt.h
new file mode 100644
index 0000000..23b7d27
--- /dev/null
+++ b/VexRiscvSocSoftware/libs/interrupt.h
@@ -0,0 +1,17 @@
+#ifndef INTERRUPTCTRL_H_
+#define INTERRUPTCTRL_H_
+
+#include <stdint.h>
+
+typedef struct
+{
+ volatile uint32_t PENDINGS;
+ volatile uint32_t MASKS;
+} InterruptCtrl_Reg;
+
+static void interruptCtrl_init(InterruptCtrl_Reg* reg){
+ reg->MASKS = 0;
+ reg->PENDINGS = 0xFFFFFFFF;
+}
+
+#endif /* INTERRUPTCTRL_H_ */