On Mon, Dec 18, 2023 at 02:37:55PM +1000, Alistair Francis wrote: ... > > +void riscv_isa_write_fdt(RISCVCPU *cpu, void *fdt, char *nodename) > > +{ > > + const size_t maxlen = sizeof("rv128i"); > > + g_autofree char *isa_base = g_new(char, maxlen); > > + g_autofree char *riscv_isa; > > + char **isa_extensions; > > + int count = 0; > > + > > + riscv_isa = riscv_isa_string(cpu); > > + qemu_fdt_setprop_string(fdt, nodename, "riscv,isa", riscv_isa); > > + > > + snprintf(isa_base, maxlen, "rv%di", TARGET_LONG_BITS); > > This should dynamically come from misa_mxl_max not the compile time target >
Need to also fix riscv_isa_string() Thanks, drew