qemu-irix/include/hw
Marcel Apfelbaum 4cae4d5aca hmp: fix regression of HMP device_del auto-completion
The commits:
 - 6a1fa9f5 (monitor: add del completion for peripheral device)
 - 66e56b13 (qdev: add qdev_build_hotpluggable_device_list helper)

cause a QEMU crash when trying to use HMP device_del auto-completion.
It can be easily reproduced by:
    <qemu-bin> -enable-kvm  ~/images/fedora.qcow2 -monitor stdio -device virtio-net-pci,id=vnet

    (qemu) device_del
    /home/mapfelba/git/upstream/qemu/hw/core/qdev.c:941:qdev_build_hotpluggable_device_list: Object 0x7f6ce04e4fe0 is not an instance of type device
    Aborted (core dumped)

The root cause is qdev_build_hotpluggable_device_list going recursively over
all peripherals and their children assuming all are devices. It doesn't work
since PCI devices have at least on child which is a memory region (bus master).

Solved by observing that all devices appear as direct children of
/machine/peripheral container. No need of going recursively
over all the children.

Signed-off-by: Marcel Apfelbaum <marcel.a@redhat.com>
Reported-by: Gal Hammer <ghammer@redhat.com>
Reviewed-by: Igor Mammedov <imammedo@redhat.com>
Message-id: 1417002601-20799-1-git-send-email-marcel.a@redhat.com
Signed-off-by: Peter Maydell <peter.maydell@linaro.org>
2014-11-27 14:36:20 +00:00
..
acpi cpu-hotplug: rename function for better readability 2014-11-02 13:44:12 +02:00
arm hw: Convert from BlockDriverState to BlockBackend, mostly 2014-10-20 14:02:25 +02:00
audio
block hw: Convert from BlockDriverState to BlockBackend, mostly 2014-10-20 14:02:25 +02:00
char
cpu
cris
i2c
i386 -machine vmport=auto: Fix handling of VMWare ioport emulation for xen 2014-11-26 12:11:27 +01:00
input
intc
ipack
isa pc87312: Drop unused members of PC87312State 2014-10-20 14:03:50 +02:00
kvm
lm32
m68k
mem pc: limit DIMM address and size to page aligned values 2014-11-23 12:11:30 +02:00
mips hw/mips: Add API to convert KVM guest KSEG0 <-> GPA 2014-06-18 16:58:10 +02:00
misc vfio: Add vfio_container_ioctl() 2014-06-27 13:48:23 +02:00
net
nvram fw_cfg: add fw_cfg_machine_reset function 2014-10-15 09:52:15 +02:00
pci megasas: add MegaRAID SAS 2108 emulation 2014-10-31 11:29:00 +01:00
pci-host Patch queue for ppc - 2014-09-08 2014-09-08 12:02:07 +01:00
ppc spapr_pci: map the MSI window in each PHB 2014-09-08 12:50:53 +02:00
s390x s390x: remove duplicate defines in SCLP code 2014-09-23 14:10:17 +02:00
scsi esp: Do not overwrite ESP_TCHI after reset 2014-11-12 10:27:03 +01:00
sh4
sparc
timer
tricore target-tricore: Add board for systemmode 2014-09-01 14:49:20 +01:00
unicore32
usb
virtio virtio-scsi: Fix comment for VirtIOSCSIReq 2014-11-12 12:43:45 +01:00
xen xen-hvm.c: Add support for Xen access to vmport 2014-10-30 14:16:38 +00:00
boards.h sysbus: Make devices spawnable via -device 2014-11-04 23:26:14 +01:00
bt.h
compat.h virtio-pci: fix migration for pci bus master 2014-11-02 12:03:03 +02:00
devices.h
elf_ops.h loader: g_realloc(p, 0) frees and returns NULL, simplify 2014-09-29 19:44:04 +03:00
empty_slot.h
fw-path-provider.h
hotplug.h qdev: HotplugHandler: Provide unplug callback 2014-10-15 05:03:13 +02:00
hw.h
ide.h
irq.h irq: Remove qemu_irq_intercept_out 2014-10-23 16:41:25 +02:00
loader.h acpi-build: mark RAM dirty on table update 2014-11-24 20:57:10 +02:00
nmi.h cpus: Define callback for QEMU "nmi" command 2014-08-25 13:25:16 +02:00
pcmcia.h hmp: Remove "info pcmcia" 2014-10-24 12:19:11 +01:00
platform-bus.h sysbus: Add new platform bus helper device 2014-11-04 23:26:14 +01:00
ptimer.h
qdev-core.h hmp: fix regression of HMP device_del auto-completion 2014-11-27 14:36:20 +00:00
qdev-dma.h
qdev-properties.h hw: Convert from BlockDriverState to BlockBackend, mostly 2014-10-20 14:02:25 +02:00
qdev.h
sd.h hw: Convert from BlockDriverState to BlockBackend, mostly 2014-10-20 14:02:25 +02:00
ssi.h
stream.h
sysbus.h trivial patches for 2014-11-11 2014-11-11 14:50:10 +00:00
usb.h usb-bus: introduce a wrapper function to check speed 2014-09-23 12:51:08 +02:00