From 1def3e9a740a609f4363c96c153ab96699a38671 Mon Sep 17 00:00:00 2001 From: Chih-Min Chao Date: Thu, 23 Apr 2020 19:19:29 -0700 Subject: fdt: restructure dtb create and config flow 1. pass dtb option from constructor 2. separate dtb generation from rom initialization 3. setup clint base from dtb Signed-off-by: Chih-Min Chao --- spike_main/spike.cc | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) (limited to 'spike_main') diff --git a/spike_main/spike.cc b/spike_main/spike.cc index d88f5b8..da3e22c 100644 --- a/spike_main/spike.cc +++ b/spike_main/spike.cc @@ -312,7 +312,7 @@ int main(int argc, char** argv) sim_t s(isa, priv, varch, nprocs, halted, real_time_clint, initrd_start, initrd_end, start_pc, mems, plugin_devices, htif_args, - std::move(hartids), dm_config, log_path); + std::move(hartids), dm_config, log_path, dtb_enabled, dtb_file); std::unique_ptr remote_bitbang((remote_bitbang_t *) NULL); std::unique_ptr jtag_dtm( new jtag_dtm_t(&s.debug_module, dmi_rti)); @@ -320,8 +320,6 @@ int main(int argc, char** argv) remote_bitbang.reset(new remote_bitbang_t(rbb_port, &(*jtag_dtm))); s.set_remote_bitbang(&(*remote_bitbang)); } - s.set_dtb_enabled(dtb_enabled); - s.set_dtb_file(dtb_file); if (dump_dts) { printf("%s", s.get_dts()); -- cgit v1.1