diff --git a/litex_boards/targets/efinix_xyloni_dev_kit.py b/litex_boards/targets/efinix_xyloni_dev_kit.py index 918af07..5d1d497 100755 --- a/litex_boards/targets/efinix_xyloni_dev_kit.py +++ b/litex_boards/targets/efinix_xyloni_dev_kit.py @@ -44,17 +44,15 @@ class _CRG(Module): # BaseSoC ------------------------------------------------------------------------------------------ class BaseSoC(SoCCore): - mem_map = {**SoCCore.mem_map, **{"spiflash": 0x80000000}} def __init__(self, bios_flash_offset, sys_clk_freq, with_led_chaser=True, **kwargs): platform = efinix_xyloni_dev_kit.Platform() - # Disable Integrated ROM since too large for this device. + # Disable Integrated ROM. kwargs["integrated_rom_size"] = 0 # Set CPU variant / reset address if kwargs.get("cpu_type", "vexriscv") == "vexriscv": kwargs["cpu_variant"] = "minimal" - kwargs["cpu_reset_address"] = self.mem_map["spiflash"] + bios_flash_offset # SoCCore ---------------------------------------------------------------------------------- SoCCore.__init__(self, platform, sys_clk_freq, @@ -72,10 +70,13 @@ class BaseSoC(SoCCore): # Add ROM linker region -------------------------------------------------------------------- self.bus.add_region("rom", SoCRegion( - origin = self.mem_map["spiflash"] + bios_flash_offset, + origin = self.bus.regions["spiflash"].origin + bios_flash_offset, size = 32*kB, linker = True) ) + # Set CPU reset address to ROM. + if hasattr(self.cpu, "set_reset_address"): + self.cpu.set_reset_address(self.bus.regions["rom"].origin) # Leds ------------------------------------------------------------------------------------- if with_led_chaser: