aboutsummaryrefslogtreecommitdiff
path: root/src/sys/core.h
diff options
context:
space:
mode:
authorChristian Cunningham <cc@localhost>2021-12-24 15:21:54 -0800
committerChristian Cunningham <cc@localhost>2021-12-24 15:21:54 -0800
commit3a366988a0077474075d8f33ad76514d2fa0c5d6 (patch)
tree7aa293e59bee8308825e029069d395c628d230cd /src/sys/core.h
parentd44bf5acb015edaeacc022f423bae4743b868f53 (diff)
Standardized Formatting
Diffstat (limited to 'src/sys/core.h')
-rw-r--r--src/sys/core.h13
1 files changed, 8 insertions, 5 deletions
diff --git a/src/sys/core.h b/src/sys/core.h
index 74bac74..d70f406 100644
--- a/src/sys/core.h
+++ b/src/sys/core.h
@@ -3,15 +3,18 @@
extern unsigned long cntfrq;
-static inline unsigned long load32(unsigned long addr) {
+static inline unsigned long load32(unsigned long addr)
+{
return *(volatile unsigned long*)addr;
}
-static inline void store32(unsigned long value, unsigned long addr) {
+static inline void store32(unsigned long value, unsigned long addr)
+{
*(volatile unsigned long*)addr = value;
}
-static inline void delay(unsigned long cycles) {
+static inline void delay(unsigned long cycles)
+{
asm volatile("__delay_%=: subs %[cycles], %[cycles], #1;bne __delay_%=\n"
: "=r"(cycles): [cycles]"0"(cycles) : "cc");
}
@@ -113,7 +116,7 @@ enum
PM_RSTC_RESET = 0x00000102,
};
-void sysinit();
-void postinit();
+void sysinit(void);
+void postinit(void);
#endif