summaryrefslogtreecommitdiff
path: root/hw/s390x
AgeCommit message (Collapse)AuthorFilesLines
2013-04-19vhost-scsi-s390: new device supporting the tcm_vhost Linux kernel modulePaolo Bonzini2-0/+65
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com> Signed-off-by: Asias He <asias@redhat.com> Cc: Michael S. Tsirkin <mst@redhat.com> Signed-off-by: Nicholas Bellinger <nab@linux-iscsi.org> Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
2013-04-19vhost-scsi-ccw: new device supporting the tcm_vhost Linux kernel modulePaolo Bonzini2-0/+65
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
2013-04-19virtio-scsi: create VirtIOSCSICommonPaolo Bonzini2-2/+2
This patch refactors existing virtio-scsi code into VirtIOSCSICommon in order to allow virtio_scsi_init_common() to be used by both internal virtio_scsi_init() and external vhost-scsi-pci code. Cc: Michael S. Tsirkin <mst@redhat.com> Cc: Asias He <asias@redhat.com> Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
2013-04-17virtio-net-ccw: switch to the new API.KONRAD Frederic2-16/+28
Here the virtio-net-ccw is modified for the new API. The device virtio-net-ccw extends virtio-ccw-device as before. It creates and connects a virtio-net-device during the init. The properties are not modified. Signed-off-by: KONRAD Frederic <fred.konrad@greensocs.com> Tested-by: Cornelia Huck <cornelia.huck@de.ibm.com> Message-id: 1365690602-22729-6-git-send-email-fred.konrad@greensocs.com Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
2013-04-17virtio-net-s390: switch to the new API.KONRAD Frederic2-12/+30
Here the virtio-net-s390 is modified for the new API. The device virtio-net-s390 extends virtio-s390-device as before. It creates and connects a virtio-net-device during the init. The properties are not modified. Signed-off-by: KONRAD Frederic <fred.konrad@greensocs.com> Tested-by: Cornelia Huck <cornelia.huck@de.ibm.com> Message-id: 1365690602-22729-5-git-send-email-fred.konrad@greensocs.com Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
2013-04-17virtio-net: add the virtio-net device.KONRAD Frederic2-10/+2
Create virtio-net-device which extends virtio-device, so it can be connected on virtio-bus. Signed-off-by: KONRAD Frederic <fred.konrad@greensocs.com> Tested-by: Cornelia Huck <cornelia.huck@de.ibm.com> Message-id: 1365690602-22729-3-git-send-email-fred.konrad@greensocs.com Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
2013-04-15virtio-balloon: fix dynamic properties.KONRAD Frederic1-0/+34
To keep compatibility with the old virtio-balloon-x, add the dynamic properties to virtio-balloon-pci and virtio-balloon-ccw. Cc: Luiz Capitulino <lcapitulino@redhat.com> Signed-off-by: KONRAD Frederic <fred.konrad@greensocs.com> Message-id: 1365941220-8114-1-git-send-email-fred.konrad@greensocs.com Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
2013-04-15virtio-serial-ccw: switch to the new API.KONRAD Frederic2-13/+27
Here the virtio-serial-ccw is modified for the new API. The device virtio-serial-ccw extends virtio-ccw-device as before. It creates and connects a virtio-serial during the init. The properties are not modified. Signed-off-by: KONRAD Frederic <fred.konrad@greensocs.com> Reviewed-by: Cornelia Huck <cornelia.huck@de.ibm.com> Reviewed-by: Peter Maydell <peter.maydell@linaro.org> Tested-by: Cornelia Huck <cornelia.huck@de.ibm.com> Acked-by: Amit Shah <amit.shah@redhat.com> Message-id: 1365512016-21944-5-git-send-email-fred.konrad@greensocs.com Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
2013-04-15virtio-serial-s390: switch to the new API.KONRAD Frederic2-11/+31
Here the virtio-serial-s390 is modified for the new API. The device virtio-serial-s390 extends virtio-s390-device as before. It creates and connects a virtio-serial during the init. The properties are not modified. Signed-off-by: KONRAD Frederic <fred.konrad@greensocs.com> Reviewed-by: Cornelia Huck <cornelia.huck@de.ibm.com> Reviewed-by: Peter Maydell <peter.maydell@linaro.org> Tested-by: Cornelia Huck <cornelia.huck@de.ibm.com> Acked-by: Amit Shah <amit.shah@redhat.com> Message-id: 1365512016-21944-4-git-send-email-fred.konrad@greensocs.com Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
2013-04-15virtio-serial: add the virtio-serial device.KONRAD Frederic2-4/+2
Create virtio-serial which extends virtio-device, so it can be connected on virtio-bus. Signed-off-by: KONRAD Frederic <fred.konrad@greensocs.com> Reviewed-by: Cornelia Huck <cornelia.huck@de.ibm.com> Reviewed-by: Peter Maydell <peter.maydell@linaro.org> Tested-by: Cornelia Huck <cornelia.huck@de.ibm.com> Acked-by: Amit Shah <amit.shah@redhat.com> Message-id: 1365512016-21944-2-git-send-email-fred.konrad@greensocs.com Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
2013-04-12Typo, spelling and grammatical fixesPeter Maydell2-2/+2
Minor fixes to documentation and code comments. Signed-off-by: Peter Maydell <peter.maydell@linaro.org> Signed-off-by: Stefan Hajnoczi <stefanha@redhat.com>
2013-04-08hw: move char devices to hw/char/, configure via default-configs/Paolo Bonzini2-306/+1
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
2013-04-08hw: move headers to include/Paolo Bonzini7-237/+23
Many of these should be cleaned up with proper qdev-/QOM-ification. Right now there are many catch-all headers in include/hw/ARCH depending on cpu.h, and this makes it necessary to compile these files per-target. However, fixing this does not belong in these patches. Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
2013-03-28virtio-balloon-ccw: switch to the new API.KONRAD Frederic2-11/+25
Here the virtio-balloon-ccw is modified for the new API. The device virtio-balloon-ccw extends virtio-ccw-device as before. It creates and connects a virtio-balloon during the init. The properties are not modified. Signed-off-by: KONRAD Frederic <fred.konrad@greensocs.com> Reviewed-by: Cornelia Huck <cornelia.huck@de.ibm.com> Reviewed-by: Peter Maydell <peter.maydell@linaro.org> Tested-by: Cornelia Huck <cornelia.huck@de.ibm.com> Message-id: 1364377755-15508-4-git-send-email-fred.konrad@greensocs.com Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
2013-03-26virtio-ccw: Queue sanity check for notify hypercall.Cornelia Huck1-0/+3
Verify that the virtio-ccw notify hypercall passed a reasonable value for queue. Cc: qemu-stable@nongnu.org Reported-by: Alexander Graf <agraf@suse.de> Signed-off-by: Cornelia Huck <cornelia.huck@de.ibm.com>
2013-03-26virtio-scsi-ccw: switch to new APIKONRAD Frederic2-13/+26
Here the virtio-scsi-ccw is modified for the new API. The device virtio-scsi-ccw extends virtio-ccw-device as before. It creates and connects a virtio-scsi during the init. The properties are not modified. Signed-off-by: KONRAD Frederic <fred.konrad@greensocs.com> Reviewed-by: Cornelia Huck <cornelia.huck@de.ibm.com> Reviewed-by: Peter Maydell <peter.maydell@linaro.org> Tested-by: Cornelia Huck <cornelia.huck@de.ibm.com> Message-id: 1363875320-7985-8-git-send-email-fred.konrad@greensocs.com Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
2013-03-26virtio-scsi-s390: switch to the new API.KONRAD Frederic2-9/+27
Here the virtio-scsi-s390 is modified for the new API. The device virtio-scsi-s390 extends virtio-s390-device as before. It creates and connects a virtio-scsi during the init. The properties are not modified. Signed-off-by: KONRAD Frederic <fred.konrad@greensocs.com> Reviewed-by: Cornelia Huck <cornelia.huck@de.ibm.com> Reviewed-by: Peter Maydell <peter.maydell@linaro.org> Tested-by: Cornelia Huck <cornelia.huck@de.ibm.com> Message-id: 1363875320-7985-7-git-send-email-fred.konrad@greensocs.com Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
2013-03-26virtio-scsi: moving host_features from properties to transport properties.KONRAD Frederic2-2/+4
host_features field is part of the transport device. So move all the host_features related properties into transport device. Signed-off-by: KONRAD Frederic <fred.konrad@greensocs.com> Reviewed-by: Cornelia Huck <cornelia.huck@de.ibm.com> Reviewed-by: Peter Maydell <peter.maydell@linaro.org> Tested-by: Cornelia Huck <cornelia.huck@de.ibm.com> Message-id: 1363875320-7985-4-git-send-email-fred.konrad@greensocs.com Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
2013-03-20virtio-ccw, s390-virtio: Use generic virtio-blk macro.Cornelia Huck2-14/+2
Now that virtio-ccw and s390-virtio define all common properties for virtio-blk, we can switch to using the generic DEFINE_VIRTIO_BLK_PROPERTIES macro. CC: Alexander Graf <agraf@suse.de> Signed-off-by: Cornelia Huck <cornelia.huck@de.ibm.com>
2013-03-20s390-virtio, virtio-ccw: Add config_wce for virtio-blk.Cornelia Huck2-0/+2
There's no reason why we wouldn't want to make the cache mode configurable. Acked-by: Alexander Graf <agraf@suse.de> Signed-off-by: Cornelia Huck <cornelia.huck@de.ibm.com>
2013-03-20virtio-ccw: Add missing blk chs properties.Cornelia Huck1-0/+1
Signed-off-by: Cornelia Huck <cornelia.huck@de.ibm.com>
2013-03-18virtio-blk-ccw switch to new API.KONRAD Frederic2-16/+31
Here the virtio-ccw-s390 is modified for the new API. The device virtio-ccw-s390 extends virtio-ccw-device as before. It creates and connects a virtio-ccw during the init. The properties are not modified. Signed-off-by: KONRAD Frederic <fred.konrad@greensocs.com> Reviewed-by: Peter Maydell <peter.maydell@linaro.org> Message-id: 1363624648-16906-9-git-send-email-fred.konrad@greensocs.com Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
2013-03-18virtio-blk-s390: switch to the new API.KONRAD Frederic2-12/+31
Here the virtio-blk-s390 is modified for the new API. The device virtio-blk-s390 extends virtio-s390-device as before. It creates and connects a virtio-blk during the init. The properties are not modified. Signed-off-by: KONRAD Frederic <fred.konrad@greensocs.com> Reviewed-by: Peter Maydell <peter.maydell@linaro.org> Message-id: 1363624648-16906-8-git-send-email-fred.konrad@greensocs.com Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
2013-03-18virtio-x-bus: fix allow_hotplug assertion.KONRAD Frederic2-2/+2
This set allow_hotplug for each existing virtio-x-bus, allowing the refactored devices to be hot pluggable. Signed-off-by: KONRAD Frederic <fred.konrad@greensocs.com> Message-id: 1363624648-16906-3-git-send-email-fred.konrad@greensocs.com Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
2013-03-15Merge remote-tracking branch 'cohuck/virtio-ccw-upstr' into stagingAnthony Liguori2-1/+62
# By Christian Borntraeger (1) and Cornelia Huck (1) # Via Cornelia Huck * cohuck/virtio-ccw-upstr: virtio-ccw: Wire up virtio-rng. virtio-ccw: remove qdev_unparent in unplug routing
2013-03-12virtio-ccw: Wire up virtio-rng.Cornelia Huck2-0/+62
Make virtio-rng devices available for s390-ccw-virtio machines. Signed-off-by: Cornelia Huck <cornelia.huck@de.ibm.com>
2013-03-12virtio-ccw: remove qdev_unparent in unplug routingChristian Borntraeger1-1/+0
This patch fixes unplugging a virtio-ccw device. We no longer need to do that in virtio-ccw since common code does now proper handling. Signed-off-by: Christian Borntraeger <borntraeger@de.ibm.com> Signed-off-by: Jens Freimann <jfrei@linux.vnet.ibm.com> Signed-off-by: Cornelia Huck <cornelia.huck@de.ibm.com>
2013-03-12cpu: Move halted and interrupt_request fields to CPUStateAndreas Färber1-5/+9
Both fields are used in VMState, thus need to be moved together. Explicitly zero them on reset since they were located before breakpoints. Pass PowerPCCPU to kvmppc_handle_halt(). Signed-off-by: Andreas Färber <afaerber@suse.de>
2013-03-10Merge remote-tracking branch 'origin/master' into stagingAnthony Liguori3-5/+8
* origin/master: (75 commits) tcg: Don't make exitreq flag a local temporary Makefile: Add subdir dependency on config-devices-all.mak make_device_config.sh: Emit dependency file to directory where included Revert "make_device_config.sh: Fix target path in generated dependency file" s390/virtio-ccw: remove redundant call to blockdev_mark_auto_del s390/css: Fix subchannel detection Allow virtio-net features for legacy s390 virtio bus s390: virtio-ccw maintainer s390: simplify kvm cpu init pseries: Add compatible property to root of device tree target-ppc: Move CPU aliases out of translate_init.c target-ppc: Report CPU aliases for QMP target-ppc: List alias names alongside CPU models target-ppc: Make host CPU a subclass of the host's CPU model PPC: xnu kernel expects FLUSH to be cleared on STOP PPC: Fix dma interrupt target-ppc: Fix PPC_DUMP_SPR_ACCESS build target-ppc: Synchronize FPU state with KVM target-ppc: Add mechanism for synchronizing SPRs with KVM Save memory allocation in the elf loader ...
2013-03-08s390/virtio-ccw: remove redundant call to blockdev_mark_auto_delChristian Borntraeger1-1/+0
blockdev_mark_auto_del is already called in virtio-blk-exit. Remove the redundant call. Signed-off-by: Christian Borntraeger <borntraeger@de.ibm.com> Signed-off-by: Jens Freimann <jfrei@linux.vnet.ibm.com> Signed-off-by: Alexander Graf <agraf@suse.de>
2013-03-08s390/css: Fix subchannel detectionChristian Borntraeger1-4/+7
We have to consider the m bit to find the real channel subsystem when determining the last subchannel. If we fail to take this into account, removal of a subchannel in the middle of a big list of devices will stop device detection after a reboot. Signed-off-by: Christian Borntraeger <borntraeger@de.ibm.com> Signed-off-by: Jens Freimann <jfrei@linux.vnet.ibm.com> Reviewed-by: Cornelia Huck <cornelia.huck@de.ibm.com> Signed-off-by: Alexander Graf <agraf@suse.de>
2013-03-08Allow virtio-net features for legacy s390 virtio busChristian Borntraeger1-0/+1
Enable all virtio-net features for the legacy s390 virtio bus. This also fixes kernel BUG at /usr/src/packages/BUILD/kernel-default-3.0.58/linux-3.0/drivers/s390/kvm/kvm_virtio.c:121! Signed-off-by: Christian Borntraeger <borntraeger@de.ibm.com> Cc: qemu-stable@nongnu.org Signed-off-by: Alexander Graf <agraf@suse.de>
2013-03-01hw: include hw header files with full pathsPaolo Bonzini5-8/+8
Done with this script: cd hw for i in `find . -name '*.h' | sed 's/^..//'`; do echo '\,^#.*include.*["<]'$i'[">], s,'$i',hw/&,' done | sed -i -f - `find . -type f` This is so that paths remain valid as files are moved. Instead, files in hw/dataplane are referenced with the relative path. We know they are not going to move to include/, and they are the only include files that are in subdirectories _and_ move. Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
2013-03-01hw: move qdev-monitor.o to toplevel directoryPaolo Bonzini1-0/+1
qdev-monitor.c is the only "core qdev" file that is not used in user-mode emulation, and it does not define anything that is used by hardware models. Remove it from the hw/ directory and remove hw/qdev-monitor.h from hw/qdev.h too; this requires some files to have some new explicitly includes. Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
2013-02-13s390: Fix handling of iscs.Cornelia Huck1-2/+2
There are two ways to express an interruption subclass: - As a bitmask, as used in cr6. - As a number, as used in the I/O interruption word. Unfortunately, we have treated to I/O interruption word as if it contained the bitmask as well, which went unnoticed so far as - (queued-for-next) kvm made the same mistake, and - Linux guest kernels don't check the isc value in the I/O interruption word for subchannel interrupts. Make sure that we treat the I/O interruption word correctly. Signed-off-by: Cornelia Huck <cornelia.huck@de.ibm.com> Signed-off-by: Alexander Graf <agraf@suse.de>
2013-02-13s390/sclpconsole: prevent char layer callback during initializationChristian Borntraeger1-4/+1
Starting a qemu with an sclp console and pressing a key very early can result in "qemu-system-s390x: hw/s390x/sclpconsole.c:60: receive_from_chr_layer: Assertion `scon->iov' failed." Lets make sure that the init process is finished, since the iov is allocated after CHR_EVENT_OPENED by also checking for scon->iov. Signed-off-by: Christian Borntraeger <borntraeger@de.ibm.com> Signed-off-by: Alexander Graf <agraf@suse.de>
2013-02-08virtio-net: pass host features to virtio_net_initAnthony Liguori2-2/+4
Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
2013-02-01target-s390x: Pass S390CPU to s390_{add, del}_running_cpu()Andreas Färber2-4/+10
This prepares for moving the halted field to CPUState. Most call sites can already supply S390CPU, for some env becomes unused. Signed-off-by: Andreas Färber <afaerber@suse.de> Acked-by: Cornelia Huck <cornelia.huck@de.ibm.com> Signed-off-by: Alexander Graf <agraf@suse.de>
2013-02-01target-s390x: Clean up cpu_inject_*() signaturesAndreas Färber1-3/+1
Despite cautioning that S390CPU is needed for upcoming CPUState refactorings, commit 5d69c547d947798cba92d836d06f6e017ba2b19d (s390: I/O interrupt and machine check injection.) added functions cpu_inject_io() and cpu_inject_crw_mchk() with CPUS390XState argument, claiming consistency with cpu_inject_ext(). This complicates making cpu_interrupt() take a CPUState even more and it required to pass &cpu->env from some S390CPU-aware call sites already, creating inconsistency elsewhere. Address that. This also eliminates the need for CPUS390XState in s390_virtio_irq(). Signed-off-by: Andreas Färber <afaerber@suse.de> Acked-by: Cornelia Huck <cornelia.huck@de.ibm.com> Signed-off-by: Alexander Graf <agraf@suse.de>
2013-01-29s390: Drop set_bit usage in virtio_ccw.Cornelia Huck1-2/+2
set_bit on indicators doesn't go well on 32 bit targets: note: expected 'long unsigned int *' but argument is of type 'uint64_t *' Switch to bit shifts instead. Signed-off-by: Cornelia Huck <cornelia.huck@de.ibm.com> [agraf: use 1ULL instead] Signed-off-by: Alexander Graf <agraf@suse.de>
2013-01-29s390: css error codes.Cornelia Huck2-5/+5
Changed error codes in the channel subsystem / virtio-ccw code (-EOPNOTSUPP -> -ENOSYS, -ERESTART -> -EINPROGRESS). This should hopefully fix building on mingw32. Signed-off-by: Cornelia Huck <cornelia.huck@de.ibm.com> Reviewed-by: Stefan Weil <sw@weilnetz.de> Signed-off-by: Alexander Graf <agraf@suse.de>
2013-01-29s390: Use s390_cpu_physical_memory_map for tpi.Cornelia Huck1-1/+1
Map the I/O interruption code before calling into css. Signed-off-by: Cornelia Huck <cornelia.huck@de.ibm.com> Signed-off-by: Alexander Graf <agraf@suse.de>
2013-01-29s390: Add s390-ccw-virtio machine.Cornelia Huck3-0/+136
Add a new machine type, s390-ccw-virtio, making use of the virtio-ccw transport to present virtio devices as channel devices. Signed-off-by: Cornelia Huck <cornelia.huck@de.ibm.com> Signed-off-by: Alexander Graf <agraf@suse.de>
2013-01-29s390-virtio: Check for NULL device in reset hypercallAndreas Färber1-0/+3
s390_virtio_bus_find_mem() may return a NULL VirtIOS390Device. If called with, e.g., args[0] == 0, this leads to a segfault. Fix this by adding error handling as done for other hypercalls. Present since baf0b55a9e57b909b1f8b0f732c0b10242867418 (Implement virtio reset). Signed-off-by: Andreas Färber <afaerber@suse.de> Signed-off-by: Alexander Graf <agraf@suse.de>
2013-01-29s390: Move hw files to hw/s390xAlexander Graf6-3/+1065
This moves all files only used by s390 system emulation to hw/s390x. Signed-off-by: Alexander Graf <agraf@suse.de> Acked-by: Christian Borntraeger <borntraeger@de.ibm.com>
2013-01-29s390: Make typeinfo constAlexander Graf1-1/+1
All TypeInfo definitions should be const. Signed-off-by: Alexander Graf <agraf@suse.de>
2013-01-29s390: Add new channel I/O based virtio transport.Cornelia Huck3-0/+1059
Add a new virtio transport that uses channel commands to perform virtio operations. Signed-off-by: Cornelia Huck <cornelia.huck@de.ibm.com> Signed-off-by: Alexander Graf <agraf@suse.de>
2013-01-29s390: Virtual channel subsystem support.Cornelia Huck3-0/+1377
Provide a mechanism for qemu to provide fully virtual subchannels to the guest. Signed-off-by: Cornelia Huck <cornelia.huck@de.ibm.com> Signed-off-by: Alexander Graf <agraf@suse.de>
2013-01-18s390: Add a hypercall registration interface.Cornelia Huck2-0/+37
Allow virtio machines to register for different diag500 function codes and convert s390-virtio to use it. Signed-off-by: Cornelia Huck <cornelia.huck@de.ibm.com> Signed-off-by: Alexander Graf <agraf@suse.de>
2013-01-18s390: Move IPL code into a separate deviceChristian Borntraeger2-0/+175
Lets move the code to setup IPL for external kernel or via the zipl rom into a separate file. This allows to - define a reboot handler, setting up the PSW appropriately - enhance the boot code to IPL disks that contain a bootmap that was created with zipl under LPAR or z/VM (future patch) - reuse that code for several machines (e.g. virtio-ccw and virtio-s390) - allow different machines to provide different defaults Signed-off-by: Christian Borntraeger <borntraeger@de.ibm.com> Signed-off-by: Jens Freimann <jfrei@linux.vnet.ibm.com> [agraf: symbolify initial psw, adjust header file location, fix for QOM] Signed-off-by: Alexander Graf <agraf@suse.de>