qemu/hw/ppc
Greg Kurz 1105504100 spapr: Use spapr_drc_reset_all() at machine reset
Documentation of object_child_foreach_recursive() clearly stipulates
that "it is forbidden to add or remove children from @obj from the @fn
callback". But this is exactly what we do during machine reset. The call
to spapr_drc_reset() can finalize the hot-unplug sequence of a PHB or a
PCI bridge, both of which will then in turn destroy their PCI DRCs. This
could potentially invalidate the iterator used by do_object_child_foreach().
It is pure luck that this haven't caused any issues so far.

Use spapr_drc_reset_all() since it can cope with DRC removal.

Signed-off-by: Greg Kurz <groug@kaod.org>
Message-Id: <20201218103400.689660-5-groug@kaod.org>
Reviewed-by: Daniel Henrique Barboza <danielhb413@gmail.com>
Tested-by: Daniel Henrique Barboza <danielhb413@gmail.com>
Signed-off-by: David Gibson <david@gibson.dropbear.id.au>
2021-01-06 11:09:59 +11:00
..
e500-ccsr.h Use OBJECT_DECLARE_SIMPLE_TYPE when possible 2020-09-18 14:12:32 -04:00
e500.c vl: make qemu_get_machine_opts static 2020-12-15 12:51:55 -05:00
e500.h
e500plat.c
fdt.c
fw_cfg.c
Kconfig ppc: Convert PPC UIC to a QOM device 2021-01-06 11:09:59 +11:00
mac_newworld.c vl: extract softmmu/datadir.c 2020-12-10 12:15:18 -05:00
mac_oldworld.c vl: extract softmmu/datadir.c 2020-12-10 12:15:18 -05:00
mac.h mac_newworld: Allow loading binary ROM image 2020-10-19 08:11:21 +01:00
meson.build
mpc8544_guts.c Use OBJECT_DECLARE_SIMPLE_TYPE when possible 2020-09-18 14:12:32 -04:00
mpc8544ds.c
pnv_bmc.c
pnv_core.c non-virt: Fix Lesser GPL version number 2020-11-15 16:38:24 +01:00
pnv_homer.c
pnv_lpc.c non-virt: Fix Lesser GPL version number 2020-11-15 16:38:24 +01:00
pnv_occ.c
pnv_pnor.c qdev: Move softmmu properties to qdev-properties-system.h 2020-12-18 15:20:17 -05:00
pnv_psi.c non-virt: Fix Lesser GPL version number 2020-11-15 16:38:24 +01:00
pnv_xscom.c non-virt: Fix Lesser GPL version number 2020-11-15 16:38:24 +01:00
pnv.c vl: extract softmmu/datadir.c 2020-12-10 12:15:18 -05:00
ppc4xx_devs.c ppc: Convert PPC UIC to a QOM device 2021-01-06 11:09:59 +11:00
ppc4xx_pci.c Pull request trivial patches 20200919 2020-09-22 15:42:23 +01:00
ppc405_boards.c vl: extract softmmu/datadir.c 2020-12-10 12:15:18 -05:00
ppc405_uc.c
ppc405.h
ppc440_bamboo.c hw/ppc/ppc440_bamboo: Drop use of ppcuic_init() 2021-01-06 11:09:59 +11:00
ppc440_pcix.c Use OBJECT_DECLARE_SIMPLE_TYPE when possible 2020-09-18 14:12:32 -04:00
ppc440_uc.c Use OBJECT_DECLARE_SIMPLE_TYPE when possible 2020-09-18 14:12:32 -04:00
ppc440.h
ppc_booke.c
ppc.c hw/ppc: Do not re-read the clock on pre_save if doing savevm 2020-12-14 15:54:12 +11:00
ppce500_spin.c powerpc tcg: Fix Lesser GPL version number 2020-11-15 16:38:50 +01:00
prep_systemio.c Use OBJECT_DECLARE_SIMPLE_TYPE when possible 2020-09-18 14:12:32 -04:00
prep.c ppc: do not use ram_size global 2020-12-10 12:15:09 -05:00
rs6000_mc.c Use OBJECT_DECLARE_SIMPLE_TYPE when possible 2020-09-18 14:12:32 -04:00
sam460ex.c vl: extract softmmu/datadir.c 2020-12-10 12:15:18 -05:00
spapr_caps.c spapr: Add a return value to spapr_check_pagesize() 2020-10-09 10:15:06 +11:00
spapr_cpu_core.c spapr: Simplify spapr_cpu_core_realize() and spapr_cpu_core_unrealize() 2020-10-28 01:08:53 +11:00
spapr_drc.c spapr: Introduce spapr_drc_reset_all() 2021-01-06 11:09:59 +11:00
spapr_events.c spapr: Allow memory unplug to always succeed 2021-01-06 11:09:59 +11:00
spapr_hcall.c spapr: Introduce spapr_drc_reset_all() 2021-01-06 11:09:59 +11:00
spapr_iommu.c memory: Add IOMMUTLBEvent 2020-12-08 13:48:57 -05:00
spapr_irq.c spapr/xics: Drop unused argument to xics_kvm_has_broken_disconnect() 2020-12-14 15:50:55 +11:00
spapr_numa.c spapr_numa: consider user input when defining associativity 2020-10-09 15:06:11 +11:00
spapr_nvdimm.c ppc/spapr: cleanup -machine pseries,nvdimm=X handling 2020-12-15 12:51:53 -05:00
spapr_ovec.c
spapr_pci_nvlink2.c
spapr_pci_vfio.c
spapr_pci.c spapr: Don't use qdev_get_machine() in spapr_msi_write() 2020-12-14 15:54:12 +11:00
spapr_rng.c Use OBJECT_DECLARE_SIMPLE_TYPE when possible 2020-09-18 14:12:32 -04:00
spapr_rtas_ddw.c
spapr_rtas.c
spapr_rtc.c
spapr_tpm_proxy.c
spapr_vio.c ppc: do not use ram_size global 2020-12-10 12:15:09 -05:00
spapr.c spapr: Use spapr_drc_reset_all() at machine reset 2021-01-06 11:09:59 +11:00
trace-events hw/ppc/spapr_tpm_proxy: Fix hexadecimal format string specifier 2020-12-14 15:54:12 +11:00
trace.h
virtex_ml507.c hw/ppc/virtex_ml507: Drop use of ppcuic_init() 2021-01-06 11:09:59 +11:00