On 9/18/23 09:02, Philippe Mathieu-Daudé wrote:
QDev instance is expected to be in an unknown state until full
object realization. Thus we shouldn't call DeviceReset() on an
unrealized instance. Move the cpu_reset() call from*before*
the parent realize() handler (effectively cpu_common_realizefn)
to*after*  it.

Signed-off-by: Philippe Mathieu-Daudé<phi...@linaro.org>
---
RFC:
I haven't audited all the call sites, but plan to do it,
amending the result to this patch description. This used
to be a problem on some targets, but as of today's master
this series pass make check-{qtest,avocado}.
---
  target/arm/cpu.c       | 2 +-
  target/avr/cpu.c       | 2 +-
  target/cris/cpu.c      | 2 +-
  target/hexagon/cpu.c   | 3 +--
  target/i386/cpu.c      | 2 +-
  target/loongarch/cpu.c | 2 +-
  target/m68k/cpu.c      | 2 +-
  target/mips/cpu.c      | 2 +-
  target/nios2/cpu.c     | 2 +-
  target/openrisc/cpu.c  | 2 +-
  target/riscv/cpu.c     | 2 +-
  target/rx/cpu.c        | 2 +-
  target/s390x/cpu.c     | 2 +-
  target/sh4/cpu.c       | 2 +-
  target/tricore/cpu.c   | 2 +-
  15 files changed, 15 insertions(+), 16 deletions(-)

Reviewed-by: Richard Henderson <richard.hender...@linaro.org>

r~

Reply via email to