search for: virtioblock

Displaying 20 results from an estimated 41 matches for "virtioblock".

Did you mean: virtio_block
2007 Dec 21
0
[Virtio-for-kvm] [PATCH 3/7] userspace virtio
.../* Where to put reply. */ + uint64_t id; +}; + +#define VIRTIO_BLK_S_OK 0 +#define VIRTIO_BLK_S_IOERR 1 +#define VIRTIO_BLK_S_UNSUPP 2 + +/* This is the first element of the write scatter-gather list */ +struct virtio_blk_inhdr +{ + unsigned char status; +}; + +typedef struct VirtIOBlock +{ + VirtIODevice vdev; + BlockDriverState *bs; +} VirtIOBlock; + +static VirtIOBlock *to_virtio_blk(VirtIODevice *vdev) +{ + return (VirtIOBlock *)vdev; +} + +static void virtio_blk_handle_output(VirtIODevice *vdev, VirtQueue *vq) +{ + VirtIOBlock *s = to_virtio_blk(vdev); + VirtQue...
2007 Dec 21
0
[Virtio-for-kvm] [PATCH 3/7] userspace virtio
.../* Where to put reply. */ + uint64_t id; +}; + +#define VIRTIO_BLK_S_OK 0 +#define VIRTIO_BLK_S_IOERR 1 +#define VIRTIO_BLK_S_UNSUPP 2 + +/* This is the first element of the write scatter-gather list */ +struct virtio_blk_inhdr +{ + unsigned char status; +}; + +typedef struct VirtIOBlock +{ + VirtIODevice vdev; + BlockDriverState *bs; +} VirtIOBlock; + +static VirtIOBlock *to_virtio_blk(VirtIODevice *vdev) +{ + return (VirtIOBlock *)vdev; +} + +static void virtio_blk_handle_output(VirtIODevice *vdev, VirtQueue *vq) +{ + VirtIOBlock *s = to_virtio_blk(vdev); + VirtQue...
2014 Nov 26
1
[PATCH RFC v3 11/12] virtio-net/virtio-blk: enable virtio 1.0
...4 ++++ 2 files changed, 8 insertions(+) diff --git a/hw/block/virtio-blk.c b/hw/block/virtio-blk.c index 6d86f60..3781f98 100644 --- a/hw/block/virtio-blk.c +++ b/hw/block/virtio-blk.c @@ -569,6 +569,10 @@ static uint32_t virtio_blk_get_features(VirtIODevice *vdev, unsigned int index, { VirtIOBlock *s = VIRTIO_BLK(vdev); + if (index == 1) { + features |= (1 << (VIRTIO_F_VERSION_1 - 32)); + } + if (index > 0) { return features; } diff --git a/hw/net/virtio-net.c b/hw/net/virtio-net.c index 1e214b5..fcfc95f 100644 --- a/hw/net/virtio-net.c +++ b/hw/net...
2014 Nov 26
0
[PATCH RFC v3 11/12] virtio-net/virtio-blk: enable virtio 1.0
...s(+) > > diff --git a/hw/block/virtio-blk.c b/hw/block/virtio-blk.c > index 6d86f60..3781f98 100644 > --- a/hw/block/virtio-blk.c > +++ b/hw/block/virtio-blk.c > @@ -569,6 +569,10 @@ static uint32_t virtio_blk_get_features(VirtIODevice *vdev, unsigned int index, > { > VirtIOBlock *s = VIRTIO_BLK(vdev); > > + if (index == 1) { > + features |= (1 << (VIRTIO_F_VERSION_1 - 32)); > + } > + > if (index > 0) { > return features; > } > diff --git a/hw/net/virtio-net.c b/hw/net/virtio-net.c > index 1e214b5..fcf...
2014 Dec 11
0
[PATCH RFC v6 19/20] virtio-blk: revision specific feature bits
...IO_BLK_F_CONFIG_WCE); + virtio_clear_feature(&features, VIRTIO_BLK_F_WCE); + /* we're still missing ANY_LAYOUT */ + /* virtio_add_feature(&features, VIRTIO_F_VERSION_1); */ + return features; +} + static void virtio_blk_set_status(VirtIODevice *vdev, uint8_t status) { VirtIOBlock *s = VIRTIO_BLK(vdev); @@ -821,6 +839,7 @@ static void virtio_blk_class_init(ObjectClass *klass, void *data) vdc->get_config = virtio_blk_update_config; vdc->set_config = virtio_blk_set_config; vdc->get_features = virtio_blk_get_features; + vdc->get_features_rev = virt...
2014 Nov 26
1
[PATCH RFC v3 11/12] virtio-net/virtio-blk: enable virtio 1.0
...4 ++++ 2 files changed, 8 insertions(+) diff --git a/hw/block/virtio-blk.c b/hw/block/virtio-blk.c index 6d86f60..3781f98 100644 --- a/hw/block/virtio-blk.c +++ b/hw/block/virtio-blk.c @@ -569,6 +569,10 @@ static uint32_t virtio_blk_get_features(VirtIODevice *vdev, unsigned int index, { VirtIOBlock *s = VIRTIO_BLK(vdev); + if (index == 1) { + features |= (1 << (VIRTIO_F_VERSION_1 - 32)); + } + if (index > 0) { return features; } diff --git a/hw/net/virtio-net.c b/hw/net/virtio-net.c index 1e214b5..fcfc95f 100644 --- a/hw/net/virtio-net.c +++ b/hw/net...
2014 Dec 11
0
[PATCH RFC v6 19/20] virtio-blk: revision specific feature bits
...IO_BLK_F_CONFIG_WCE); + virtio_clear_feature(&features, VIRTIO_BLK_F_WCE); + /* we're still missing ANY_LAYOUT */ + /* virtio_add_feature(&features, VIRTIO_F_VERSION_1); */ + return features; +} + static void virtio_blk_set_status(VirtIODevice *vdev, uint8_t status) { VirtIOBlock *s = VIRTIO_BLK(vdev); @@ -821,6 +839,7 @@ static void virtio_blk_class_init(ObjectClass *klass, void *data) vdc->get_config = virtio_blk_update_config; vdc->set_config = virtio_blk_set_config; vdc->get_features = virtio_blk_get_features; + vdc->get_features_rev = virt...
2014 Dec 28
2
[PATCH RFC v6 19/20] virtio-blk: revision specific feature bits
...feature(&features, VIRTIO_BLK_F_WCE); > + /* we're still missing ANY_LAYOUT */ > + /* virtio_add_feature(&features, VIRTIO_F_VERSION_1); */ > + return features; > +} > + > static void virtio_blk_set_status(VirtIODevice *vdev, uint8_t status) > { > VirtIOBlock *s = VIRTIO_BLK(vdev); > @@ -821,6 +839,7 @@ static void virtio_blk_class_init(ObjectClass *klass, void *data) > vdc->get_config = virtio_blk_update_config; > vdc->set_config = virtio_blk_set_config; > vdc->get_features = virtio_blk_get_features; > + vdc-&g...
2014 Dec 28
2
[PATCH RFC v6 19/20] virtio-blk: revision specific feature bits
...feature(&features, VIRTIO_BLK_F_WCE); > + /* we're still missing ANY_LAYOUT */ > + /* virtio_add_feature(&features, VIRTIO_F_VERSION_1); */ > + return features; > +} > + > static void virtio_blk_set_status(VirtIODevice *vdev, uint8_t status) > { > VirtIOBlock *s = VIRTIO_BLK(vdev); > @@ -821,6 +839,7 @@ static void virtio_blk_class_init(ObjectClass *klass, void *data) > vdc->get_config = virtio_blk_update_config; > vdc->set_config = virtio_blk_set_config; > vdc->get_features = virtio_blk_get_features; > + vdc-&g...
2014 Dec 11
0
[PATCH RFC v6 03/20] virtio: feature bit manipulation helpers
...TIO_9P_MOUNT_TAG); return features; } diff --git a/hw/block/virtio-blk.c b/hw/block/virtio-blk.c index b19b102..3f76e2a 100644 --- a/hw/block/virtio-blk.c +++ b/hw/block/virtio-blk.c @@ -568,20 +568,20 @@ static uint32_t virtio_blk_get_features(VirtIODevice *vdev, uint32_t features) { VirtIOBlock *s = VIRTIO_BLK(vdev); - features |= (1 << VIRTIO_BLK_F_SEG_MAX); - features |= (1 << VIRTIO_BLK_F_GEOMETRY); - features |= (1 << VIRTIO_BLK_F_TOPOLOGY); - features |= (1 << VIRTIO_BLK_F_BLK_SIZE); - features |= (1 << VIRTIO_BLK_F_SCSI); + virtio_ad...
2014 Dec 11
0
[PATCH RFC v6 03/20] virtio: feature bit manipulation helpers
...TIO_9P_MOUNT_TAG); return features; } diff --git a/hw/block/virtio-blk.c b/hw/block/virtio-blk.c index b19b102..3f76e2a 100644 --- a/hw/block/virtio-blk.c +++ b/hw/block/virtio-blk.c @@ -568,20 +568,20 @@ static uint32_t virtio_blk_get_features(VirtIODevice *vdev, uint32_t features) { VirtIOBlock *s = VIRTIO_BLK(vdev); - features |= (1 << VIRTIO_BLK_F_SEG_MAX); - features |= (1 << VIRTIO_BLK_F_GEOMETRY); - features |= (1 << VIRTIO_BLK_F_TOPOLOGY); - features |= (1 << VIRTIO_BLK_F_BLK_SIZE); - features |= (1 << VIRTIO_BLK_F_SCSI); + virtio_ad...
2014 Dec 11
0
[PATCH RFC v6 04/20] virtio: add feature checking helpers
...irtio-blk.c b/hw/block/virtio-blk.c index 3f76e2a..27f263a 100644 --- a/hw/block/virtio-blk.c +++ b/hw/block/virtio-blk.c @@ -590,7 +590,6 @@ static uint32_t virtio_blk_get_features(VirtIODevice *vdev, uint32_t features) static void virtio_blk_set_status(VirtIODevice *vdev, uint8_t status) { VirtIOBlock *s = VIRTIO_BLK(vdev); - uint32_t features; if (s->dataplane && !(status & (VIRTIO_CONFIG_S_DRIVER | VIRTIO_CONFIG_S_DRIVER_OK))) { @@ -601,8 +600,6 @@ static void virtio_blk_set_status(VirtIODevice *vdev, uint8_t status) return...
2014 Dec 11
0
[PATCH RFC v6 04/20] virtio: add feature checking helpers
...irtio-blk.c b/hw/block/virtio-blk.c index 3f76e2a..27f263a 100644 --- a/hw/block/virtio-blk.c +++ b/hw/block/virtio-blk.c @@ -590,7 +590,6 @@ static uint32_t virtio_blk_get_features(VirtIODevice *vdev, uint32_t features) static void virtio_blk_set_status(VirtIODevice *vdev, uint8_t status) { VirtIOBlock *s = VIRTIO_BLK(vdev); - uint32_t features; if (s->dataplane && !(status & (VIRTIO_CONFIG_S_DRIVER | VIRTIO_CONFIG_S_DRIVER_OK))) { @@ -601,8 +600,6 @@ static void virtio_blk_set_status(VirtIODevice *vdev, uint8_t status) return...
2009 May 11
0
[PATCH 1/2] qemu-kvm: add MSI-X support
...ockDriverState *bs) PCI_VENDOR_ID_REDHAT_QUMRANET, VIRTIO_ID_BLOCK, PCI_CLASS_STORAGE_OTHER, 0x00, - sizeof(struct virtio_blk_config), sizeof(VirtIOBlock)); + sizeof(struct virtio_blk_config), sizeof(VirtIOBlock), + 0); if (!s) return NULL; diff --git a/hw/virtio-console.c b/hw/virtio-console.c index 89e8be0..759f249 100644 --- a/hw/virtio-console.c +++ b/hw/...
2009 May 11
0
[PATCH 1/2] qemu-kvm: add MSI-X support
...ockDriverState *bs) PCI_VENDOR_ID_REDHAT_QUMRANET, VIRTIO_ID_BLOCK, PCI_CLASS_STORAGE_OTHER, 0x00, - sizeof(struct virtio_blk_config), sizeof(VirtIOBlock)); + sizeof(struct virtio_blk_config), sizeof(VirtIOBlock), + 0); if (!s) return NULL; diff --git a/hw/virtio-console.c b/hw/virtio-console.c index 89e8be0..759f249 100644 --- a/hw/virtio-console.c +++ b/hw/...
2009 May 20
0
[PATCHv2-RFC 1/2] qemu-kvm: add MSI-X support
...ockDriverState *bs) PCI_VENDOR_ID_REDHAT_QUMRANET, VIRTIO_ID_BLOCK, PCI_CLASS_STORAGE_OTHER, 0x00, - sizeof(struct virtio_blk_config), sizeof(VirtIOBlock)); + sizeof(struct virtio_blk_config), sizeof(VirtIOBlock), + 0); if (!s) return NULL; diff --git a/hw/virtio-console.c b/hw/virtio-console.c index 89e8be0..759f249 100644 --- a/hw/virtio-console.c +++ b/hw/...
2009 May 20
0
[PATCHv2-RFC 1/2] qemu-kvm: add MSI-X support
...ockDriverState *bs) PCI_VENDOR_ID_REDHAT_QUMRANET, VIRTIO_ID_BLOCK, PCI_CLASS_STORAGE_OTHER, 0x00, - sizeof(struct virtio_blk_config), sizeof(VirtIOBlock)); + sizeof(struct virtio_blk_config), sizeof(VirtIOBlock), + 0); if (!s) return NULL; diff --git a/hw/virtio-console.c b/hw/virtio-console.c index 89e8be0..759f249 100644 --- a/hw/virtio-console.c +++ b/hw/...
2014 Dec 02
24
[PATCH RFC v5 00/19] qemu: towards virtio-1 host support
Another iteration of virtio-1 patches for qemu, as always available on git://github.com/cohuck/qemu virtio-1 This one seems to work together with the current vhost-next patches (well, I can ping :) Changes from v4: - add helpers for feature bit manipulation and checking - use 64 bit feature bits instead of 32 bit arrays - infrastructure to allow devices to offer different sets of feature bits
2014 Dec 02
24
[PATCH RFC v5 00/19] qemu: towards virtio-1 host support
Another iteration of virtio-1 patches for qemu, as always available on git://github.com/cohuck/qemu virtio-1 This one seems to work together with the current vhost-next patches (well, I can ping :) Changes from v4: - add helpers for feature bit manipulation and checking - use 64 bit feature bits instead of 32 bit arrays - infrastructure to allow devices to offer different sets of feature bits
2014 Nov 26
15
[PATCH RFC v3 00/12] qemu: towards virtio-1 host support
Next version of virtio-1 patches for qemu. Only change from v2 is splitting out the vring accessors into a separate header file - should hopefully fix the build issues. Cornelia Huck (9): virtio: cull virtio_bus_set_vdev_features virtio: support more feature bits s390x/virtio-ccw: fix check for WRITE_FEAT virtio: introduce legacy virtio devices virtio: allow virtio-1 queue layout