]> git.ipfire.org Git - thirdparty/qemu.git/commit
target/riscv: convert profile CPU models to RISCVCPUDef
authorPaolo Bonzini <pbonzini@redhat.com>
Thu, 27 Feb 2025 13:56:30 +0000 (14:56 +0100)
committerPaolo Bonzini <pbonzini@redhat.com>
Tue, 20 May 2025 06:18:53 +0000 (08:18 +0200)
commit198265df8a71e6743d42d5003c29a060fea7d019
treef2e7234260ec3bb01a969de43ac03747345b4eab
parent4e012d36c8654e7fa12762002150334bf591628a
target/riscv: convert profile CPU models to RISCVCPUDef

Profile CPUs reuse the instance_init function for bare CPUs; make them
proper subclasses instead.  Enabling a profile is now done based on the
RISCVCPUDef struct: even though there is room for only one in RISCVCPUDef,
subclasses check that the parent class's profile is enabled through the
parent profile mechanism.

Reviewed-by: Alistair Francis <alistair.francis@wdc.com>
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
target/riscv/cpu.c
target/riscv/cpu.h