Updates the register addresses to match the OpenTitan spec. These changes were made in this commit: https://github.com/lowRISC/opentitan/commit/a25e162b8f91bd0ca32258c83d1d480f93327204
Signed-off-by: Tyler Ng <t...@rivosinc.com> --- hw/timer/ibex_timer.c | 20 ++++++++++---------- 1 file changed, 10 insertions(+), 10 deletions(-) diff --git a/hw/timer/ibex_timer.c b/hw/timer/ibex_timer.c index 8c2ca364da..9ffd4821e8 100644 --- a/hw/timer/ibex_timer.c +++ b/hw/timer/ibex_timer.c @@ -38,19 +38,19 @@ REG32(ALERT_TEST, 0x00) FIELD(ALERT_TEST, FATAL_FAULT, 0, 1) REG32(CTRL, 0x04) FIELD(CTRL, ACTIVE, 0, 1) -REG32(CFG0, 0x100) - FIELD(CFG0, PRESCALE, 0, 12) - FIELD(CFG0, STEP, 16, 8) -REG32(LOWER0, 0x104) -REG32(UPPER0, 0x108) -REG32(COMPARE_LOWER0, 0x10C) -REG32(COMPARE_UPPER0, 0x110) -REG32(INTR_ENABLE, 0x114) +REG32(INTR_ENABLE, 0x100) FIELD(INTR_ENABLE, IE_0, 0, 1) -REG32(INTR_STATE, 0x118) +REG32(INTR_STATE, 0x104) FIELD(INTR_STATE, IS_0, 0, 1) -REG32(INTR_TEST, 0x11C) +REG32(INTR_TEST, 0x108) FIELD(INTR_TEST, T_0, 0, 1) +REG32(CFG0, 0x10C) + FIELD(CFG0, PRESCALE, 0, 12) + FIELD(CFG0, STEP, 16, 8) +REG32(LOWER0, 0x110) +REG32(UPPER0, 0x114) +REG32(COMPARE_LOWER0, 0x118) +REG32(COMPARE_UPPER0, 0x11C) static uint64_t cpu_riscv_read_rtc(uint32_t timebase_freq) { -- 2.30.2