Skip to content

Commit

Permalink
Move CLINT to the other address
Browse files Browse the repository at this point in the history
  • Loading branch information
chiangkd committed May 27, 2024
1 parent a100317 commit 60db9e2
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
4 changes: 2 additions & 2 deletions main.c
Original file line number Diff line number Diff line change
Expand Up @@ -105,7 +105,7 @@ static void mem_load(vm_t *vm, uint32_t addr, uint8_t width, uint32_t *value)
emu_update_vblk_interrupts(vm);
return;
#endif
case 0x43: /* CLINT */
case 0x44: /* CLINT */
aclint_read(vm, &data->aclint, addr & 0xFFFF, width, value);
aclint_update_interrupts(vm, &data->aclint);
return;
Expand Down Expand Up @@ -147,7 +147,7 @@ static void mem_store(vm_t *vm, uint32_t addr, uint8_t width, uint32_t value)
emu_update_vblk_interrupts(vm);
return;
#endif
case 0x43: /* CLINT */
case 0x44: /* CLINT */
aclint_write(vm, &data->aclint, addr & 0xFFFF, width, value);
aclint_update_interrupts(vm, &data->aclint);
return;
Expand Down
4 changes: 2 additions & 2 deletions minimal.dts
Original file line number Diff line number Diff line change
Expand Up @@ -81,10 +81,10 @@
interrupts = <3>;
};
#endif
clint0: clint@4300000 {
clint0: clint@4400000 {
#interrupt-cells = <1>;
compatible = "sifive,clint0";
reg = <0x4300000 0x000C000>;
reg = <0x4400000 0x000C000>;
interrupts-extended = <&cpu0_intc 1 &cpu0_intc 5>;
};
};
Expand Down

0 comments on commit 60db9e2

Please sign in to comment.