From 860ca8673e8f81231f445e17e9a56c23cc7e08fe Mon Sep 17 00:00:00 2001 From: Mateusz Karlic Date: Thu, 22 Sep 2022 13:25:45 +0200 Subject: [PATCH] json2renode: Use opensbi->base for bios binary --- litex/tools/litex_json2renode.py | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/litex/tools/litex_json2renode.py b/litex/tools/litex_json2renode.py index 22c6e5d54..d5e6e2050 100755 --- a/litex/tools/litex_json2renode.py +++ b/litex/tools/litex_json2renode.py @@ -774,15 +774,15 @@ showAnalyzer sysbus.uart showAnalyzer sysbus.uart Antmicro.Renode.Analyzers.LoggingUartAnalyzer """.format(cpu_type, args.repl) - rom_base = csr['memories']['rom']['base'] if 'rom' in csr['memories'] else None - if rom_base is not None and args.bios_binary: + opensbi_base = csr['memories']['opensbi']['base'] if 'opensbi' in csr['memories'] else None + if opensbi_base is not None and args.bios_binary: # load LiteX BIOS to ROM result += """ sysbus LoadBinary @{} {} -""".format(args.bios_binary, hex(rom_base)) +""".format(args.bios_binary, hex(opensbi_base)) for cpu_id in range(0, number_of_cores): - result += f"cpu{cpu_id} PC {hex(rom_base)}\n" + result += f"cpu{cpu_id} PC {hex(opensbi_base)}\n" if args.tftp_ip: result += """