mirror_qemu/hw/ppc
Michael Roth df18b2db69 spapr_drc: fix aborts during DRC-count based hotplug
CPU/memory resources can be signalled en-masse via
spapr_hotplug_req_add_by_count(), and when doing so, actually change
the meaning of the 'drc' parameter passed to
spapr_hotplug_req_event() to be a count rather than an index.

f40eb92 added a hook in spapr_hotplug_req_event() to record when a
device had been 'signalled' to the guest, but that code assumes that
drc is always an index. In cases where it's a count, such as memory
hotplug, the DRC lookup will fail, leading to an assert.

Fix this by only explicitly setting the signalled state for cases where
we are doing PCI hotplug.

For other resources types, since we cannot selectively track whether a
resource has been signalled in cases where we signal attach as a count,
set the 'signalled' state to true immediately upon making the
resource available via drck->attach().

Reported-by: Bharata B Rao <bharata@linux.vnet.ibm.com>
Cc: Bharata B Rao <bharata@linux.vnet.ibm.com>
Cc: david@gibson.dropbear.id.au
Cc: qemu-ppc@nongnu.org
Signed-off-by: Michael Roth <mdroth@linux.vnet.ibm.com>
Signed-off-by: David Gibson <david@gibson.dropbear.id.au>
2016-04-26 11:16:08 +10:00
..
Makefile.objs ppc/spapr: Implement H_RANDOM hypercall in QEMU 2015-09-23 10:51:11 +10:00
e500-ccsr.h ppc: do not use ../ in include files 2013-03-01 13:57:33 +01:00
e500.c include/qemu/osdep.h: Don't include qapi/error.h 2016-03-22 22:20:15 +01:00
e500.h PPC: e500 pci host: Add support for ATMUs 2015-01-07 16:16:24 +01:00
e500plat.c ppc: Clean up includes 2016-01-29 15:07:22 +00:00
mac.h cuda: port SET_DEVICE_LIST command to new framework 2016-02-17 09:59:30 +11:00
mac_newworld.c util: move declarations out of qemu-common.h 2016-03-22 22:20:17 +01:00
mac_oldworld.c util: move declarations out of qemu-common.h 2016-03-22 22:20:17 +01:00
mpc8544_guts.c hw: explicitly include qemu-common.h and cpu.h 2016-03-22 22:20:17 +01:00
mpc8544ds.c ppc: Clean up includes 2016-01-29 15:07:22 +00:00
ppc.c Replaced get_tick_per_sec() by NANOSECONDS_PER_SECOND 2016-03-22 22:20:17 +01:00
ppc4xx_devs.c ppc: Clean up includes 2016-01-29 15:07:22 +00:00
ppc4xx_pci.c ppc: Clean up includes 2016-01-29 15:07:22 +00:00
ppc405.h hw: move private headers to hw/ subdirectories. 2013-04-08 18:13:16 +02:00
ppc405_boards.c hw: explicitly include qemu-common.h and cpu.h 2016-03-22 22:20:17 +01:00
ppc405_uc.c Replaced get_tick_per_sec() by NANOSECONDS_PER_SECOND 2016-03-22 22:20:17 +01:00
ppc440_bamboo.c loader: Add data swap option to load-elf 2016-03-04 11:30:21 +00:00
ppc_booke.c Replaced get_tick_per_sec() by NANOSECONDS_PER_SECOND 2016-03-22 22:20:17 +01:00
ppce500_spin.c ppc: Clean up includes 2016-01-29 15:07:22 +00:00
prep.c util: move declarations out of qemu-common.h 2016-03-22 22:20:17 +01:00
spapr.c hw/ppc/spapr: Fix crash when specifying bad parameters to spapr-pci-host-bridge 2016-04-23 16:52:20 +10:00
spapr_drc.c spapr_drc: fix aborts during DRC-count based hotplug 2016-04-26 11:16:08 +10:00
spapr_events.c spapr_drc: fix aborts during DRC-count based hotplug 2016-04-26 11:16:08 +10:00
spapr_hcall.c ppc: Rework POWER7 & POWER8 exception model 2016-04-05 10:38:24 +10:00
spapr_iommu.c ppc: Clean up includes 2016-01-29 15:07:22 +00:00
spapr_pci.c hw/ppc/spapr: Fix crash when specifying bad parameters to spapr-pci-host-bridge 2016-04-23 16:52:20 +10:00
spapr_pci_vfio.c hw: explicitly include qemu-common.h and cpu.h 2016-03-22 22:20:17 +01:00
spapr_rng.c hw: explicitly include qemu-common.h and cpu.h 2016-03-22 22:20:17 +01:00
spapr_rtas.c spapr: Fix ibm,lrdr-capacity 2016-04-08 11:18:10 +10:00
spapr_rtc.c util: move declarations out of qemu-common.h 2016-03-22 22:20:17 +01:00
spapr_vio.c include/qemu/osdep.h: Don't include qapi/error.h 2016-03-22 22:20:15 +01:00
virtex_ml507.c loader: Add data swap option to load-elf 2016-03-04 11:30:21 +00:00