History | View | Annotate | Download (14.4 kB)
Rename DriveInfo.onerror to on_write_error
Either rename variables and functions to refer to write errors (which is whatthey actually do) or introduce a parameter to distinguish reads and writes.
Signed-off-by: Kevin Wolf <kwolf@redhat.com>Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
virtio-blk: Implement rerror option
virtio-blk: Pass read errors to the guest
We need to signal not only write errors, but also read errors to the guestdriver. This fixes a regression introduced by 869a5c6d.
Pass the drive's readonly attribute to the guest OS
Implemented for virtio-blk and for scsi
Signed-off-by: Naphtali Sprei <nsprei@redhat.com>Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
drive cleanup fixes.
Changes: * drive_uninit() wants a DriveInfo now. * drive_uninit() also calls bdrv_delete(), so callers don't need to do that. * drive_uninit() calls are moved over to the ->exit() callbacks, destroy_bdrvs() is zapped. * setting bdrv->private is not needed any more as the...
qemu: make virtio-blk PCI compliant by default
commit bf011293faaa7f87e4de83185931e7411b794128 made virtio-blk-pci notPCI-compliant, since it makes region 0 (which is an i/o region)size > 256, and, since PCI 2.1, i/o regions are limited to 256 bytes size....
virtio-blk: add volatile writecache feature
Add a new VIRTIO_BLK_F_WCACHE feature to virtio-blk to indicate that we havea volatile write cache that needs controlled flushing. Implement aVIRTIO_BLK_T_FLUSH operation to flush it.
Signed-off-by: Christoph Hellwig <hch@lst.de>...
virtio-blk: Use bdrv_aio_multiwrite
It is quite common for virtio-blk to submit more than one write request in arow to the qemu block layer. Use bdrv_aio_multiwrite to allow block drivers tooptimize its handling of the requests.
Signed-off-by: Kevin Wolf <kwolf@redhat.com>...
virtio-blk: handle NULL returns from bdrv_aio_{read, write}
The bdrv_aio_{read,write} routines can return a NULL pointer when theI/O submission fails. Currently we ignore this and will wait foreverfor an I/O completion and leading to a hang of the guest....
qdev-ify virtio-blk.
First user of the new drive property. With this patch applied hostand guest config can be specified separately, like this:
-drive if=none,id=disk1,file=/path/to/disk.img -device virtio-blk-pci,drive=disk1
You can set any property for virtio-blk-pci now. You can set the pci...
Fix VM state change handlers running out of order
When a VM state change handler changes VM state, other VM state changehandlers can see the state transitions out of order.
bmdma_map(), scsi_disk_init() and virtio_blk_init() install VM statechange handlers to restart DMA. These handlers can vm_stop() by...
Add serial number support for virtio_blk
[brought forward to current qemu-kvm.git]
This patch implements the missing qemu logic tointerpret a '-drive .. serial=XYZ ..' flag fora virtio_blk device.
The serial number string is contained in askeletal IDENTIFY DEVICE data structure and...
virtio blk: fix warning.
Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
Avoid gcc 4.4 warning about uninitialized field
Signed-off-by: Blue Swirl <blauwirbel@gmail.com>
Separate virtio PCI code
Split the PCI host bindings from the VRing transport implementation.
Signed-off-by: Paul Brook <paul@codesourcery.com>
Virtio-blk qdev conversion
Virtio-net qdev conversion
virtio-blk: add SGI_IO passthru support
[had the qemu list address wrong the first time, reply to this message, not the previous if you were on Cc]
Add support for SG_IO passthru (packet commands) to the virtio-blkbackend. Conceptually based on an older patch from Hannes Reinecke...
virtio-blk: use generic vectored I/O APIs (Christoph Hellwig)
Use the generic bdrv_aio_readv/bdrv_aio_writev APIs instead of linearizingbuffers directly. This enables using the future native preadv/pwritevsupport.
qemu: record devfn on block driver instance (Marcelo Tosatti)
Record PCIDev on the BlockDriverState structure to locate for releaseon hot-removal.
Signed-off-by: Marcelo Tosatti <mtosatti@redhat.com>Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>...
hw: remove error handling from qemu_malloc() callers (Avi Kivity)
Signed-off-by: Avi Kivity <avi@redhat.com>Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@6529 c046a42c-6fe2-441c-8c8c-71466251a162
Add and use #defines for PCI device classes
This patch adds and uses #defines for PCI device classes and subclases,using a new pci_config_set_class() function, similar to the recentlyadded pci_config_set_vendor_id() and pci_config_set_device_id().
Change since v1: fixed compilation of hw/sun4u.c...
Use the default subsystem vendor ID for virtio devices (Mark McLoughlin)
A subsystem vendor ID of zero isn't allowed, so we use ourdefault ID.
Gerd points out that although the PCI subsystem vendor ID istreated by the guest as the virtio vendor ID:
/* we use the subsystem vendor/device id as the virtio vendor/device...
Stop VM on error in virtio-blk. (Gleb Natapov)
Signed-off-by: Gleb Natapov <gleb@redhat.com>Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@6410 c046a42c-6fe2-441c-8c8c-71466251a162
pci: virtio: use pci id defines (Gerd Hoffman)
Use the defines added by the previous patch in the virtio drivers.Also remove the pointless vendor and device args from thevirtio_blk_init() function.
Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>...
Add virtio-blk support
Virtio-blk is a paravirtual block device based on VirtIO. It can be used byspecifying the if=virtio parameter to the -drive parameter.
When using -enable-kvm, it can achieve very good performance compared to IDE orSCSI.
Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>...