diff options
author | Bernhard Beschow <shentey@gmail.com> | 2022-09-22 09:52:32 +0200 |
---|---|---|
committer | Alistair Francis <alistair@alistair23.me> | 2022-09-27 07:04:38 +1000 |
commit | 9dfa6c2aec299fda9946c327e889087365a715b5 (patch) | |
tree | 4cd5dd763a5e45d2df9e443e8a462e5d8af31b0f /target/loongarch/cpu.c | |
parent | 9e37653b5c73d8e43013ed78ee9d7644f23d146c (diff) | |
download | qemu-9dfa6c2aec299fda9946c327e889087365a715b5.zip qemu-9dfa6c2aec299fda9946c327e889087365a715b5.tar.gz qemu-9dfa6c2aec299fda9946c327e889087365a715b5.tar.bz2 |
hw/riscv/sifive_e: Fix inheritance of SiFiveEState
SiFiveEState inherits from SysBusDevice while it's TypeInfo claims it to
inherit from TYPE_MACHINE. This is an inconsistency which can cause
undefined behavior such as memory corruption.
Change SiFiveEState to inherit from MachineState since it is registered
as a machine.
Fixes: 0869490b1c ("riscv: sifive_e: Manually define the machine")
Signed-off-by: Bernhard Beschow <shentey@gmail.com>
Reviewed-by: Alistair Francis <alistair.francis@wdc.com>
Reviewed-by: Philippe Mathieu-Daudé <f4bug@amsat.org>
Message-Id: <20220922075232.33653-1-shentey@gmail.com>
Signed-off-by: Alistair Francis <alistair.francis@wdc.com>
Diffstat (limited to 'target/loongarch/cpu.c')
0 files changed, 0 insertions, 0 deletions