soc: remove cpu_boot_file argument

This commit is contained in:
Sebastien Bourdeauducq 2015-04-01 17:32:45 +08:00
parent fb86445d14
commit 9599eb6fae
2 changed files with 4 additions and 4 deletions

View File

@ -88,6 +88,8 @@ if __name__ == "__main__":
memory_regions = soc.get_memory_regions()
csr_regions = soc.get_csr_regions()
bios_file = "software/bios/bios.bin"
# decode actions
action_list = ["clean", "build-bitstream", "build-headers", "build-csr-csv", "build-bios",
"load-bitstream", "flash-bitstream", "flash-bios", "all"]
@ -175,7 +177,7 @@ CPU type: {}
if actions["build-bitstream"]:
if soc.with_integrated_rom:
with open(soc.cpu_boot_file, "rb") as boot_file:
with open(bios_file, "rb") as boot_file:
boot_data = []
while True:
w = boot_file.read(4)
@ -209,4 +211,4 @@ CPU type: {}
if actions["flash-bios"]:
prog = platform.create_programmer()
prog.set_flash_proxy_dir(args.flash_proxy_dir)
prog.flash(soc.cpu_reset_address, soc.cpu_boot_file)
prog.flash(soc.cpu_reset_address, bios_file)

View File

@ -34,7 +34,6 @@ class SoC(Module):
}
def __init__(self, platform, clk_freq,
cpu_type="lm32", cpu_reset_address=0x00000000,
cpu_boot_file="software/bios/bios.bin",
with_integrated_rom=False, rom_size=0x8000,
with_integrated_sram=True, sram_size=4096,
with_integrated_main_ram=False, main_ram_size=64*1024,
@ -50,7 +49,6 @@ class SoC(Module):
self.cpu_reset_address = 0
else:
self.cpu_reset_address = cpu_reset_address
self.cpu_boot_file = cpu_boot_file
self.with_integrated_rom = with_integrated_rom
self.rom_size = rom_size