aboutsummaryrefslogtreecommitdiff
path: root/riscv/dts.cc
diff options
context:
space:
mode:
authorRupert Swarbrick <rswarbrick@gmail.com>2022-02-18 15:45:21 +0000
committerRupert Swarbrick <rswarbrick@gmail.com>2022-03-12 21:51:01 +0000
commitcb632586bdb1b57ea4e5a5543e21bbb257e47f3b (patch)
tree17720758321ebccff687f9d642ac5d14c49df95b /riscv/dts.cc
parent59ec157568d2a52feeec568ac042362db1c5ddbc (diff)
downloadspike-cb632586bdb1b57ea4e5a5543e21bbb257e47f3b.zip
spike-cb632586bdb1b57ea4e5a5543e21bbb257e47f3b.tar.gz
spike-cb632586bdb1b57ea4e5a5543e21bbb257e47f3b.tar.bz2
Construct an isa_parser_t and pass it to processor_t constructor
This is a minor change, turning processor_t from a child class of isa_parser_t into a class that contains an isa_parser_t as a field. The point is that it is a step toward separating out "configuration" (and ISA string parsing) from processor state. This should be helpful for rejigging things so that we construct more from a supplied device tree.
Diffstat (limited to 'riscv/dts.cc')
-rw-r--r--riscv/dts.cc4
1 files changed, 2 insertions, 2 deletions
diff --git a/riscv/dts.cc b/riscv/dts.cc
index 09accf9..c86fc2f 100644
--- a/riscv/dts.cc
+++ b/riscv/dts.cc
@@ -55,8 +55,8 @@ std::string make_dts(size_t insns_per_rtc_tick, size_t cpu_hz,
" reg = <" << i << ">;\n"
" status = \"okay\";\n"
" compatible = \"riscv\";\n"
- " riscv,isa = \"" << procs[i]->get_isa_string() << "\";\n"
- " mmu-type = \"riscv," << (procs[i]->get_max_xlen() <= 32 ? "sv32" : "sv48") << "\";\n"
+ " riscv,isa = \"" << procs[i]->get_isa().get_isa_string() << "\";\n"
+ " mmu-type = \"riscv," << (procs[i]->get_isa().get_max_xlen() <= 32 ? "sv32" : "sv48") << "\";\n"
" riscv,pmpregions = <16>;\n"
" riscv,pmpgranularity = <4>;\n"
" clock-frequency = <" << cpu_hz << ">;\n"