Skip to content

Commit

Permalink
Improve private area decoding.
Browse files Browse the repository at this point in the history
  • Loading branch information
cr1901 committed Feb 8, 2025
1 parent 2d8dffa commit badb8a0
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions litex/soc/cores/cpu/sentinel/core.py
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,7 @@ class Sentinel(CPU):
gcc_triple = CPU_GCC_TRIPLE_RISCV32
linker_output_format = "elf32-littleriscv"
nop = "nop"
io_regions = {0x0000_0000: 32, # Private data area.
io_regions = {0x0000_0000: 0x1000_0000, # Private data area.
0x8000_0000: 0x8000_0000} # Origin, Length.

# GCC Flags.
Expand All @@ -54,6 +54,7 @@ def gcc_flags(self):
@property
def mem_map(self):
return {
"private" : 0x0000_0000,
"spiflash" : 0x1000_0000,
"rom" : 0x2000_0000,
"sram" : 0x2100_0000,
Expand Down Expand Up @@ -154,7 +155,7 @@ def __init__(self, io_lim):
bus_dat_r_override = Signal(32)
bus_ack_override = Signal()

decode_expr = bus.adr < (self.io_lim // 4)
decode_expr = bus.adr[-4:] == 0

self.comb += [
bus.ack.eq(self.litex_bus.ack | bus_ack_override),
Expand Down

0 comments on commit badb8a0

Please sign in to comment.