mips_r4k: do not use isa_mmio
This fixes endianness bugs in I/O port access.
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>Reviewed-by: Anthony Liguori <aliguori@us.ibm.com>Message-id: 1374501278-31549-8-git-send-email-pbonzini@redhat.comSigned-off-by: Anthony Liguori <aliguori@us.ibm.com>
mips_malta: do not use isa_mmio
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>Reviewed-by: Anthony Liguori <aliguori@us.ibm.com>Message-id: 1374501278-31549-9-git-send-email-pbonzini@redhat.comSigned-off-by: Anthony Liguori <aliguori@us.ibm.com>
ppc440_bamboo: do not use isa_mmio
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>Reviewed-by: Anthony Liguori <aliguori@us.ibm.com>Message-id: 1374501278-31549-10-git-send-email-pbonzini@redhat.comSigned-off-by: Anthony Liguori <aliguori@us.ibm.com>
mipssim: do not use isa_mmio
Untested, this board does not support PCI so it cannot run endianness-test.It should fix endianness bugs in I/O port access.
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>Reviewed-by: Anthony Liguori <aliguori@us.ibm.com>...
mips_fulong2e: do not use isa_mmio
This board is little-endian, but still isa_mmio should die. :)
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>Reviewed-by: Anthony Liguori <aliguori@us.ibm.com>Message-id: 1374501278-31549-12-git-send-email-pbonzini@redhat.com...
sparc64: remove indirection for I/O port access
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>Reviewed-by: Anthony Liguori <aliguori@us.ibm.com>Message-id: 1374501278-31549-13-git-send-email-pbonzini@redhat.com...
ebus: do not use isa_mmio
This is untested, because ebus does not have a libqos module.
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>Reviewed-by: Anthony Liguori <aliguori@us.ibm.com>Message-id: 1374501278-31549-14-git-send-email-pbonzini@redhat.com...
isa_mmio: delete
It is not used anymore.
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>Reviewed-by: Anthony Liguori <aliguori@us.ibm.com>Message-id: 1374501278-31549-15-git-send-email-pbonzini@redhat.comSigned-off-by: Anthony Liguori <aliguori@us.ibm.com>
ppc_newworld: do not use isa_mmio
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>Reviewed-by: Anthony Liguori <aliguori@us.ibm.com>Message-id: 1374501278-31549-4-git-send-email-pbonzini@redhat.comSigned-off-by: Anthony Liguori <aliguori@us.ibm.com>
spapr_pci: remove indirection for I/O port access
Signed-off-by: Alexey Kardashevskiy <aik@ozlabs.ru>Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>Reviewed-by: Anthony Liguori <aliguori@us.ibm.com>Message-id: 1374501278-31549-5-git-send-email-pbonzini@redhat.com...
prep: fix I/O port endianness
Do not swap endianness here, it will happen during cpu_{in,out}{b,w,l}.
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>Reviewed-by: Anthony Liguori <aliguori@us.ibm.com>Message-id: 1374501278-31549-6-git-send-email-pbonzini@redhat.com...
mips_jazz: do not use isa_mmio
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>Reviewed-by: Anthony Liguori <aliguori@us.ibm.com>Message-id: 1374501278-31549-7-git-send-email-pbonzini@redhat.comSigned-off-by: Anthony Liguori <aliguori@us.ibm.com>
sh4: do not use isa_mmio
This fixes endianness bugs in I/O port access (for sh4eb).
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>Reviewed-by: Anthony Liguori <aliguori@us.ibm.com>Message-id: 1374501278-31549-2-git-send-email-pbonzini@redhat.comSigned-off-by: Anthony Liguori <aliguori@us.ibm.com>
ppc_oldworld: do not use isa_mmio
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>Reviewed-by: Anthony Liguori <aliguori@us.ibm.com>Message-id: 1374501278-31549-3-git-send-email-pbonzini@redhat.comSigned-off-by: Anthony Liguori <aliguori@us.ibm.com>
Merge remote-tracking branch 'afaerber/tags/qom-cpu-for-anthony' into staging
QOM CPUState refactorings
cpu: Turn cpu_get_phys_page_debug() into a CPUClass hook
Change breakpoint_invalidate() argument to CPUState alongside.
Since all targets now assign a softmmu-only field, we can drop helperscpu_class_set_{do_unassigned_access,vmsd}() and device_class_set_vmsd()....
exec: Change cpu_memory_rw_debug() argument to CPUState
Propagate X86CPU in kvmvapic for simplicity.
Signed-off-by: Andreas Färber <afaerber@suse.de>
hpet: QOM'ify some more
Introduce type constant, avoid FROM_SYSBUS().
Signed-off-by: Hu Tao <hutao@cn.fujitsu.com>[AF: Renamed parent field and renamed variable]Signed-off-by: Andreas Färber <afaerber@suse.de>
kvm/clock: QOM'ify some more
Introduce type constant and avoid FROM_SYSBUS().
Signed-off-by: Hu Tao <hutao@cn.fujitsu.com>[AF: Renamed parent field]Signed-off-by: Andreas Färber <afaerber@suse.de>
fdc: Use QOM realize for fdc
Signed-off-by: Hu Tao <hutao@cn.fujitsu.com>[AF: Renamed SysBusDevice variable]Signed-off-by: Andreas Färber <afaerber@suse.de>
fdc: Improve error propagation for QOM realize
Rename fdctrl_init_common() to fdctrl_realize_common() and letfdctrl_connect_drives() propagate an Error through it.
Reviewed-by: Hu Tao <hutao@cn.fujitsu.com>Reviewed-by: Stefan Hajnoczi <stefanha@redhat.com>...
pflash_cfi01: Use QOM realize for pflash_cfi01
Signed-off-by: Hu Tao <hutao@cn.fujitsu.com>[AF: Renamed argument]Signed-off-by: Andreas Färber <afaerber@suse.de>
pflash_cfi02: Use QOM realize for pflash_cfi02
Signed-off-by: Hu Tao <hutao@cn.fujitsu.com>Signed-off-by: Andreas Färber <afaerber@suse.de>
ahci: Use QOM realize for ahci
Signed-off-by: Hu Tao <hutao@cn.fujitsu.com>[AF: Avoided repeated SYS_BUS_DEVICE() casts]Signed-off-by: Andreas Färber <afaerber@suse.de>
fw_cfg: Use QOM realize for fw_cfg
Signed-off-by: Hu Tao <hutao@cn.fujitsu.com>[AF: Moved sysbus_init_mmio() to instance_init, renamed variable]Signed-off-by: Andreas Färber <afaerber@suse.de>
scsi/esp: Use QOM realize for scsi esp
Signed-off-by: Hu Tao <hutao@cn.fujitsu.com>[AF: Drop sysbus_esp_init()]Signed-off-by: Andreas Färber <afaerber@suse.de>
megasas: Legacy command line handling fix
Only apply legacy command line handling when the device has not beenhot-plugged. Propagate failure of legacy command line handling.
Cc: qemu-stable@nongnu.orgAcked-by: Paolo Bonzini <pbonzini@redhat.com>Signed-off-by: Andreas Färber <afaerber@suse.de>
scsi: Improve error propagation for scsi_bus_legacy_handle_cmdline()
Let scsi_bus_legacy_add_drive() and scsi_bus_legacy_handle_cmdline()return an Error**. Prepare qdev initfns for QOM realize error model.
hpet: Use QOM realize for hpet
Signed-off-by: Hu Tao <hutao@cn.fujitsu.com>[AF: Avoided SYS_BUS_DEVICE() in loop]Signed-off-by: Andreas Färber <afaerber@suse.de>
kvm/clock: Use QOM realize for kvmclock
kvmvapic: Use QOM realize
Signed-off-by: Hu Tao <hutao@cn.fujitsu.com>[AF: Renamed variable]Signed-off-by: Andreas Färber <afaerber@suse.de>
ioapic: Use QOM realize for ioapic
Signed-off-by: Hu Tao <hutao@cn.fujitsu.com>[AF: Tweaked error message]Signed-off-by: Andreas Färber <afaerber@suse.de>
isa-bus: Drop isabus_bridge_init() since it does nothing
This works since commit 4ce5dae88ecf2bafa0cd663de7e923728b1b3672.
Signed-off-by: Hu Tao <hutao@cn.fujitsu.com>[AF: Edited]Signed-off-by: Andreas Färber <afaerber@suse.de>
misc/pci-testdev: QOM parent field cleanup
Replace direct uses of PCITestDevState::dev with QOM casts and rename itto parent_obj.
Acked-by: Peter Crosthwaite <peter.crosthwaite@xilinx.com>Signed-off-by: Andreas Färber <afaerber@suse.de>
display/vmware_vga: QOM casting sweep
Define and use standard QOM cast macro. Remove usages of DO_UPCAST() anddirect -> style casting.
Signed-off-by: Peter Crosthwaite <peter.crosthwaite@xilinx.com>[AF: Renamed to TYPE_VMWARE_VGA and VMWARE_VGA()]Signed-off-by: Andreas Färber <afaerber@suse.de>
display/vmware_vga: QOM parent field cleanup
Replace direct uses of pci_vmsvga_state_s::card with QOM casts andrename it to parent_obj.
misc/ivshmem: QOM Upcast Sweep
Define and use standard QOM cast macro. Remove usages of DO_UPCAST()and direct -> style upcasting.
Signed-off-by: Peter Crosthwaite <peter.crosthwaite@xilinx.com>[AF: Simplified casts and converted two more DO_UPCAST()s]...
misc/ivshmem: QOM parent field cleanup
Replace direct uses of IVShmemState::dev with QOM casts and rename it toparent_obj.
xen/xen_platform: QOM casting sweep
Signed-off-by: Peter Crosthwaite <peter.crosthwaite@xilinx.com>[AF: Dropped opaque casts]Signed-off-by: Andreas Färber <afaerber@suse.de>
xen/xen_platform: QOM parent field cleanup
Replace direct uses of PCIXenPlatformState::pci_dev field with QOM castsand rename it to parent_obj.
ohci: QOM'ify some more
Introduce type constant and avoid DO_UPCAST().
Signed-off-by: Hu Tao <hutao@cn.fujitsu.com>[AF: Avoid remaining OHCIPCIState::pci_dev uses, rename parent fields]Signed-off-by: Andreas Färber <afaerber@suse.de>
ohci: Use QOM realize for OHCI
i440fx: Use type-safe cast instead of direct access of parent dev
Signed-off-by: Hu Tao <hutao@cn.fujitsu.com>[AF: Converted remaining accesses and renamed to parent_obj]Signed-off-by: Andreas Färber <afaerber@suse.de>
i440fx-pcihost: Use QOM realize for i440fx-pcihost
q35: Use type-safe cast instead of direct access of parent dev
And remove variables if possible.
Signed-off-by: Hu Tao <hutao@cn.fujitsu.com>[AF: Converted remaining access and renamed to parent_obj]Signed-off-by: Andreas Färber <afaerber@suse.de>
q35: Use QOM realize for q35 host bridge
And split off MemoryRegion initialization into instance_init.
fdc: QOM'ify some more
Introduce type constant and avoid DO_UPCAST(), container_of(),and use DEVICE to avoid accessing parent qdev directly.
Signed-off-by: Hu Tao <hutao@cn.fujitsu.com>[AF: Renamed parent field and avoided repeated SYS_BUS_DEVICE() casts]...
pflash-cfi01: QOM'ify some more
Introduce type constant and replace FROM_SYSBUS().
pflash-cfi02: QOM'ify some more
ahci: QOM'ify some more
fwcfg: QOM'ify some more
Use type constant if possible and avoid DO_UPCAST().
scsi/esp: QOM'ify some more
net/e1000: QOM Upcast Sweep
Signed-off-by: Peter Crosthwaite <peter.crosthwaite@xilinx.com>Signed-off-by: Andreas Färber <afaerber@suse.de>
net/e1000: QOM parent field cleanup
Replace direct uses of E1000State::dev field with QOM casts and renameit to parent_obj.
net/rtl8139: QOM Upcast Sweep
net/rtl8139: QOM parent field cleanup
Replace direct uses of RTL8139State::dev with QOM casts and rename it toparent_obj.
net/pcnet-pci: QOM Upcast Sweep
Signed-off-by: Peter Crosthwaite <peter.crosthwaite@xilinx.com>[AF: Renamed parent field, renamed from PC_NET to PCNET]Signed-off-by: Andreas Färber <afaerber@suse.de>
usb/hcd-xhci: QOM Upcast Sweep
Signed-off-by: Peter Crosthwaite <peter.crosthwaite@xilinx.com>[AF: Dropped usb_xhci_init() DeviceState argument and renamed variable]...
usb/hcd-xhci: QOM parent field cleanup
Replace direct uses of XHCIState::pci_dev with QOM casts and rename itto parent_obj.
scsi/lsi53c895a: QOM Upcast Sweep
scsi/lsi53c895a: QOM parent field cleanup
Replace direct uses of LSIState::dev with QOM casts and rename it toparent_obj.
scsi/megasas: QOM Upcast Sweep
scsi/megasas: QOM parent field cleanup
Replace direct uses of MegasasState::dev with QOM casts and rename it toparent_obj.
scsi/esp-pci: QOM Upcast Sweep
scsi/esp-pci: QOM parent field cleanup
Replace direct uses of PCIESPState::dev with QOM casts and rename it toparent_obj.
ide/ich: QOM Upcast Sweep
Signed-off-by: Peter Crosthwaite <peter.crosthwaite@xilinx.com>[AF: Renamed to TYPE_ICH9_AHCI and used typedef in pci_ich9_reset()]...
ide/ich: QOM parent field cleanup
Replace direct uses of AHCIPCIState::card with QOM casts and rename itto parent_obj.
acpi/piix4: QOM Upcast Sweep
acpi/piix4: QOM parent field cleanup
Replace direct uses of PIIX4PMState::dev with QOM casts and rename it toparent_obj.
misc/pci-testdev: QOM Upcast Sweep
Signed-off-by: Peter Crosthwaite <peter.crosthwaite@xilinx.com>[AF: Replaced another DO_UPCAST()]Signed-off-by: Andreas Färber <afaerber@suse.de>
hw: Avoid use of QOM type name macros in VMStateDescriptions
The name field in a VMStateDescription is part of the migration stateversioning, so changing it will break migration. It's therefore abad idea to use a QOM typename macro to initialize it, because in...
Merge remote-tracking branch 'pmaydell/tags/pull-arm-devs-20130722' into staging
arm-devs queue
Merge remote-tracking branch 'mjt/trivial-patches' into staging
Merge remote-tracking branch 'stefanha/block' into staging
Merge remote-tracking branch 'rth/axp-next' into staging
Message-id: 1374161033-11449-1-git-send-email-rth@twiddle.net...
Merge remote-tracking branch 'stefanha/tracing' into staging
hw/arm: Use 'load_ramdisk()' for loading ramdisks w/ U-Boot header
The load_ramdisk function is used to load ramdisk featuring a U-Bootheader.
Signed-off-by: Soren Brinkmann <soren.brinkmann@xilinx.com>Reviewed-by: Peter Maydell <peter.maydell@linaro.org>...
hw/loader: Support ramdisk with u-boot header
Introduce 'load_ramdisk()' which can load "normal" ramdisks and ramdiskswith a u-boot header.To enable this and leverage synergies 'load_uimage()' is refactored toaccomodate this additional use case.
Signed-off-by: Soren Brinkmann <soren.brinkmann@xilinx.com>...
virtio: Implement MMIO based virtio transport
Add support for the generic MMIO based virtio transport.
This patch includes some fixes for bugs spotted byYing-Shiuan Pan <yspan@itri.org.tw>.
Signed-off-by: Peter Maydell <peter.maydell@linaro.org>Signed-off-by: KONRAD Frederic <fred.konrad@greensocs.com>...
arm/boot: Allow boards to modify the FDT blob
Add a callback hook in arm_boot_info to allow board models tomodify the device tree blob if they need to. (The major expecteduse case is to add virtio-mmio nodes for virtio-mmio transportsthat exist in QEMU but not in the hardware.)...
vexpress: Make VEDBoardInfo extend arm_boot_info
Make the VEDBoardInfo struct extend arm_boot_info; this willallow us to get at the VEDBoardInfo information inside callbacksfrom arm/boot code.
Signed-off-by: Peter Maydell <peter.maydell@linaro.org>Message-id: 1373977512-28932-8-git-send-email-peter.maydell@linaro.org
vexpress: Add virtio-mmio transports
Add some virtio-mmio transports to the vexpress board model,together with a modify_dtb hook which adds them to the devicetree so that the kernel will probe for them. We put themin a reserved area of the address map....
arm/boot: Use qemu_devtree_setprop_sized_cells()
Replace the opencoded assembly of the reg property array for the/memory node with a call to qemu_devtree_setprop_sized_cells().
Signed-off-by: Peter Maydell <peter.maydell@linaro.org>Reviewed-by: Peter Crosthwaite <peter.crosthwaite@xilinx.com>...
virtio: Add support for guest setting of queue size
The MMIO virtio transport spec allows the guest to tell the host howlarge the queue size is. Add virtio_queue_set_num() function whichimplements this in the QEMU common virtio support code.
Signed-off-by: Peter Maydell <peter.maydell@linaro.org>...
virtio: Support transports which can specify the vring alignment
Support virtio transports which can specify the vring alignment(ie where the guest communicates this to the host) by providinga new virtio_queue_set_align() function. (The default alignment...
block/m25p80: Update Micron entries
- Split 32Mb and 256Mb parts into a11 and a13 variants.- Add the 4K sector flag to the 128Mb parts. (These entries were taken from the Linux kernel list, which is missing the flag.)- Fill out the table of sizes with entries for 64Mb parts....
dataplane: sync virtio.c and vring.c virtqueue state
Load the virtio.c state into vring.c when we start dataplane mode andvice versa when stopping dataplane mode. This patch makes it possibleto start and stop dataplane any time while the guest is running....
target-alpha: Move alarm to vm_clock
Basing the alarm off the rtc_clock was silly. It leads to horriblespinning in the guest after being suspended and resumed, as it triesto catch up with lost ticks.
This requires adding an accessor for reading the vm_clock too....
Merge remote-tracking branch 'awilliam/tags/vfio-for-qemu-1.6' into staging
vfio: enhanced VGA quirks + AER error containment
Merge remote-tracking branch 'mst/tags/for_anthony' into staging
pci,net,pc enhancements
This includes some fixes and enhancements that accumulated in my tree:pci fixes by dkoch, virtio-net enhancements by akong and mst,and a fix for xen pc by mst.
Signed-off-by: Michael S. Tsirkin <mst@redhat.com>...
slavio_misc: Fix slavio_led_mem_readw/_writew tracepoints
Broken since they got added in commit 97bf485.
Signed-off-by: Markus Armbruster <armbru@redhat.com>Signed-off-by: Stefan Hajnoczi <stefanha@redhat.com>
milkymist-minimac2: Fix minimac2_read/_write tracepoints
Broken in milkymist-minimac.c from the start (commit 0742454),faithfully moved to milkymist-minimac2.c (commit 57aa265).
vfio: QEMU-AER: Qemu changes to support AER for VFIO-PCI devices
Add support for error containment when a VFIO device assigned to a KVMguest encounters an error. This is for PCIe devices/drivers that support AERfunctionality. When the host OS is notified of an error in a device either...
vfio-pci: VGA quirk update
Turns out all the suspicions for AMD devices were correct, everywherewe read a BAR address that the address matches the config space offset,there's full access to PCI config space. Attempt to generalize somehelpers to allow quirks to easily be added for mirrors and windows....
Merge remote-tracking branch 'cohuck/virtio-ccw-upstr' into staging
Message-id: 1373903207-27085-1-git-send-email-cornelia.huck@de.ibm.com...
Merge remote-tracking branch 'pmaydell/tags/pull-arm-devs-20130715' into staging
pc: don't access fw cfg if NULL
commit f8c457b88d72a48989f190bc3d7b79f4f3b7d11c "pc: pass PCI hole ranges to Guests" broke Xen as it has no fw_cfg.Check for this configuration and boil out.
Signed-off-by: Michael S. Tsirkin <mst@redhat.com>Tested-by: Stefano Stabellini <stefano.stabellini@eu.citrix.com>
net: add support of mac-programming over macvtap in QEMU side
Currently macvtap based macvlan device is working in promiscuousmode, we want to implement mac-programming over macvtap throughLibvirt for better performance.
Design: QEMU notifies Libvirt when rx-filter config is changed in guest,...
virtio-ccw: Enable x-data-plane for virtio-ccw-blk
Add property x-data-plane to virtio-ccw-blk devices.
Signed-off-by: Dominik Dingel <dingel@linux.vnet.ibm.com>Signed-off-by: Cornelia Huck <cornelia.huck@de.ibm.com>