aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--armclock.h21
1 files changed, 10 insertions, 11 deletions
diff --git a/armclock.h b/armclock.h
index 3e65d27..2b2aec9 100644
--- a/armclock.h
+++ b/armclock.h
@@ -5,16 +5,15 @@
#include "global.h"
-#define ARMCLK_LOAD (ARM_BASE + 0x400)
-#define ARMCLK_VALUE (ARM_BASE + 0x404)
-#define ARMCLK_CONTROL (ARM_BASE + 0x408)
-#define ARMCLK_IRQ_CLR_ACK (ARM_BASE + 0x40C)
-#define ARMCLK_LOAD_RAW_IRQ (ARM_BASE + 0x410)
-#define ARMCLK_LOAD_MASKED_IRQ (ARM_BASE + 0x414)
-#define ARMCLK_LOAD_RELOAD (ARM_BASE + 0x418)
-// the last 2 are said to not exist on the actual Pi
-#define ARMCLK_LOAD_PRE_DRIVER (ARM_BASE + 0x41C)
-#define ARMCLK_LOAD_FREE_RUNNING_COUNTER (ARM_BASE + 0x420)
+#define ARMCLK_LOAD (ARM_BASE + 0x400)
+#define ARMCLK_VALUE (ARM_BASE + 0x404)
+#define ARMCLK_CONTROL (ARM_BASE + 0x408)
+#define ARMCLK_IRQ_CLR_ACK (ARM_BASE + 0x40C)
+#define ARMCLK_RAW_IRQ (ARM_BASE + 0x410)
+#define ARMCLK_MASKED_IRQ (ARM_BASE + 0x414)
+#define ARMCLK_RELOAD (ARM_BASE + 0x418)
+#define ARMCLK_PRE_DRIVER (ARM_BASE + 0x41C)
+#define ARMCLK_FREE_RUNNING_COUNTER (ARM_BASE + 0x420)
typedef union armclk_control
{
@@ -63,7 +62,7 @@ static inline void armclk_irq_settimeout(uint32_t timeout)
static inline _Bool armclk_irq_pending(void)
{
- return *(uint32_t volatile*) ARMCLK_LOAD_RAW_IRQ;
+ return *(uint32_t volatile*) ARMCLK_RAW_IRQ;
}
#endif // ARMCLOCK_H