Add optional production build mode

parent 54102b7c
......@@ -44,6 +44,12 @@ from opencoresi2c.opencoresi2c import OpenCoresI2CMaster
kB = 1024
mB = 1024*kB
# Production mode
# When enabled, boot time is prioritized
# and internal Flash is used as the boot source
# Various self-tests are disabled as well
production_mode = False
# CRG ----------------------------------------------------------------------------------------------
class _CRG(Module):
......@@ -434,9 +440,14 @@ def main():
)
builder = Builder(soc, **builder_argdict(args))
# DRAM controller setup
if production_mode:
soc.add_constant("SDRAM_TEST_DISABLE")
# Flash boot setup
flash_boot_adr = soc.mem_map["bmcspiflash"] + 0x800000
soc.add_constant("FLASH_BOOT_ADDRESS", flash_boot_adr)
if production_mode:
soc.add_constant("FLASH_BOOT_ADDRESS", flash_boot_adr)
soc.set_gateware_dir(builder.gateware_dir)
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment