search for: virtio_mmio_queue_pfn

Displaying 20 results from an estimated 45 matches for "virtio_mmio_queue_pfn".

2015 Jan 20
4
[PATCH v2] virtio-mmio: Update the device to OASIS spec version
...); + writel((u32)vdev->features, + vm_dev->base + VIRTIO_MMIO_DRIVER_FEATURES); return 0; } @@ -275,7 +259,12 @@ static void vm_del_vq(struct virtqueue *vq) /* Select and deactivate the queue */ writel(index, vm_dev->base + VIRTIO_MMIO_QUEUE_SEL); - writel(0, vm_dev->base + VIRTIO_MMIO_QUEUE_PFN); + if (vm_dev->version == 1) { + writel(0, vm_dev->base + VIRTIO_MMIO_QUEUE_PFN); + } else { + writel(0, vm_dev->base + VIRTIO_MMIO_QUEUE_READY); + WARN_ON(readl(vm_dev->base + VIRTIO_MMIO_QUEUE_READY)); + } size = PAGE_ALIGN(vring_size(info->num, VIRTIO_MMIO_VRING_ALIGN));...
2015 Jan 20
4
[PATCH v2] virtio-mmio: Update the device to OASIS spec version
...); + writel((u32)vdev->features, + vm_dev->base + VIRTIO_MMIO_DRIVER_FEATURES); return 0; } @@ -275,7 +259,12 @@ static void vm_del_vq(struct virtqueue *vq) /* Select and deactivate the queue */ writel(index, vm_dev->base + VIRTIO_MMIO_QUEUE_SEL); - writel(0, vm_dev->base + VIRTIO_MMIO_QUEUE_PFN); + if (vm_dev->version == 1) { + writel(0, vm_dev->base + VIRTIO_MMIO_QUEUE_PFN); + } else { + writel(0, vm_dev->base + VIRTIO_MMIO_QUEUE_READY); + WARN_ON(readl(vm_dev->base + VIRTIO_MMIO_QUEUE_READY)); + } size = PAGE_ALIGN(vring_size(info->num, VIRTIO_MMIO_VRING_ALIGN));...
2015 Apr 28
0
[PATCH v2] virtio-mmio: Update the device to OASIS spec version
...gt; } > > - /* Activate the queue */ > - writel(info->num, vm_dev->base + VIRTIO_MMIO_QUEUE_NUM); > - writel(VIRTIO_MMIO_VRING_ALIGN, > - vm_dev->base + VIRTIO_MMIO_QUEUE_ALIGN); > - writel(virt_to_phys(info->queue) >> PAGE_SHIFT, > - vm_dev->base + VIRTIO_MMIO_QUEUE_PFN); > - > /* Create the vring */ > vq = vring_new_virtqueue(index, info->num, VIRTIO_MMIO_VRING_ALIGN, vdev, > true, info->queue, vm_notify, callback, name); > @@ -371,6 +354,33 @@ static struct virtqueue *vm_setup_vq(struct virtio_device *vdev, unsigned index, >...
2015 Jan 20
1
[PATCH] virtio-mmio: Update the device to OASIS spec version
...); + writel((u32)vdev->features, + vm_dev->base + VIRTIO_MMIO_DRIVER_FEATURES); return 0; } @@ -275,7 +252,12 @@ static void vm_del_vq(struct virtqueue *vq) /* Select and deactivate the queue */ writel(index, vm_dev->base + VIRTIO_MMIO_QUEUE_SEL); - writel(0, vm_dev->base + VIRTIO_MMIO_QUEUE_PFN); + if (vm_dev->version == 1) { + writel(0, vm_dev->base + VIRTIO_MMIO_QUEUE_PFN); + } else { + writel(0, vm_dev->base + VIRTIO_MMIO_QUEUE_READY); + WARN_ON(readl(vm_dev->base + VIRTIO_MMIO_QUEUE_READY)); + } size = PAGE_ALIGN(vring_size(info->num, VIRTIO_MMIO_VRING_ALIGN));...
2015 Jan 20
1
[PATCH] virtio-mmio: Update the device to OASIS spec version
...); + writel((u32)vdev->features, + vm_dev->base + VIRTIO_MMIO_DRIVER_FEATURES); return 0; } @@ -275,7 +252,12 @@ static void vm_del_vq(struct virtqueue *vq) /* Select and deactivate the queue */ writel(index, vm_dev->base + VIRTIO_MMIO_QUEUE_SEL); - writel(0, vm_dev->base + VIRTIO_MMIO_QUEUE_PFN); + if (vm_dev->version == 1) { + writel(0, vm_dev->base + VIRTIO_MMIO_QUEUE_PFN); + } else { + writel(0, vm_dev->base + VIRTIO_MMIO_QUEUE_READY); + WARN_ON(readl(vm_dev->base + VIRTIO_MMIO_QUEUE_READY)); + } size = PAGE_ALIGN(vring_size(info->num, VIRTIO_MMIO_VRING_ALIGN));...
2015 Jan 20
0
[PATCH v2] virtio-mmio: Update the device to OASIS spec version
...vm_dev->base + VIRTIO_MMIO_DRIVER_FEATURES); > > return 0; > } > @@ -275,7 +259,12 @@ static void vm_del_vq(struct virtqueue *vq) > > /* Select and deactivate the queue */ > writel(index, vm_dev->base + VIRTIO_MMIO_QUEUE_SEL); > - writel(0, vm_dev->base + VIRTIO_MMIO_QUEUE_PFN); > + if (vm_dev->version == 1) { > + writel(0, vm_dev->base + VIRTIO_MMIO_QUEUE_PFN); > + } else { > + writel(0, vm_dev->base + VIRTIO_MMIO_QUEUE_READY); > + WARN_ON(readl(vm_dev->base + VIRTIO_MMIO_QUEUE_READY)); > + } > > size = PAGE_ALIGN(vring_size(in...
2015 Jan 20
0
[PATCH v2] virtio-mmio: Update the device to OASIS spec version
...vm_dev->base + VIRTIO_MMIO_DRIVER_FEATURES); > > return 0; > } > @@ -275,7 +259,12 @@ static void vm_del_vq(struct virtqueue *vq) > > /* Select and deactivate the queue */ > writel(index, vm_dev->base + VIRTIO_MMIO_QUEUE_SEL); > - writel(0, vm_dev->base + VIRTIO_MMIO_QUEUE_PFN); > + if (vm_dev->version == 1) { > + writel(0, vm_dev->base + VIRTIO_MMIO_QUEUE_PFN); > + } else { > + writel(0, vm_dev->base + VIRTIO_MMIO_QUEUE_READY); > + WARN_ON(readl(vm_dev->base + VIRTIO_MMIO_QUEUE_READY)); > + } > > size = PAGE_ALIGN(vring_size(in...
2014 Dec 19
5
[RFC] virtio-mmio: Update the device to OASIS spec version
...vdev->features & 0xffffffff, + vm_dev->base + VIRTIO_MMIO_DRIVER_FEATURES); return 0; } @@ -275,7 +252,12 @@ static void vm_del_vq(struct virtqueue *vq) /* Select and deactivate the queue */ writel(index, vm_dev->base + VIRTIO_MMIO_QUEUE_SEL); - writel(0, vm_dev->base + VIRTIO_MMIO_QUEUE_PFN); + if (vm_dev->version == 1) { + writel(0, vm_dev->base + VIRTIO_MMIO_QUEUE_PFN); + } else { + writel(0, vm_dev->base + VIRTIO_MMIO_QUEUE_READY); + WARN_ON(readl(vm_dev->base + VIRTIO_MMIO_QUEUE_READY)); + } size = PAGE_ALIGN(vring_size(info->num, VIRTIO_MMIO_VRING_ALIGN));...
2014 Dec 19
5
[RFC] virtio-mmio: Update the device to OASIS spec version
...vdev->features & 0xffffffff, + vm_dev->base + VIRTIO_MMIO_DRIVER_FEATURES); return 0; } @@ -275,7 +252,12 @@ static void vm_del_vq(struct virtqueue *vq) /* Select and deactivate the queue */ writel(index, vm_dev->base + VIRTIO_MMIO_QUEUE_SEL); - writel(0, vm_dev->base + VIRTIO_MMIO_QUEUE_PFN); + if (vm_dev->version == 1) { + writel(0, vm_dev->base + VIRTIO_MMIO_QUEUE_PFN); + } else { + writel(0, vm_dev->base + VIRTIO_MMIO_QUEUE_READY); + WARN_ON(readl(vm_dev->base + VIRTIO_MMIO_QUEUE_READY)); + } size = PAGE_ALIGN(vring_size(info->num, VIRTIO_MMIO_VRING_ALIGN));...
2015 Jan 15
0
[RFC] virtio-mmio: Update the device to OASIS spec version
...vm_dev->base + VIRTIO_MMIO_DRIVER_FEATURES); > > return 0; > } > @@ -275,7 +252,12 @@ static void vm_del_vq(struct virtqueue *vq) > > /* Select and deactivate the queue */ > writel(index, vm_dev->base + VIRTIO_MMIO_QUEUE_SEL); > - writel(0, vm_dev->base + VIRTIO_MMIO_QUEUE_PFN); > + if (vm_dev->version == 1) { > + writel(0, vm_dev->base + VIRTIO_MMIO_QUEUE_PFN); > + } else { > + writel(0, vm_dev->base + VIRTIO_MMIO_QUEUE_READY); > + WARN_ON(readl(vm_dev->base + VIRTIO_MMIO_QUEUE_READY)); > + } > > size = PAGE_ALIGN(vring_size(in...
2015 Jan 15
0
[RFC] virtio-mmio: Update the device to OASIS spec version
...vm_dev->base + VIRTIO_MMIO_DRIVER_FEATURES); > > return 0; > } > @@ -275,7 +252,12 @@ static void vm_del_vq(struct virtqueue *vq) > > /* Select and deactivate the queue */ > writel(index, vm_dev->base + VIRTIO_MMIO_QUEUE_SEL); > - writel(0, vm_dev->base + VIRTIO_MMIO_QUEUE_PFN); > + if (vm_dev->version == 1) { > + writel(0, vm_dev->base + VIRTIO_MMIO_QUEUE_PFN); > + } else { > + writel(0, vm_dev->base + VIRTIO_MMIO_QUEUE_READY); > + WARN_ON(readl(vm_dev->base + VIRTIO_MMIO_QUEUE_READY)); > + } > > size = PAGE_ALIGN(vring_size(in...
2017 Jan 12
1
[PATCH 1/2] virtio_mmio: add standard header file
...y */ +#define VIRTIO_MMIO_QUEUE_NUM 0x038 + + +#ifndef VIRTIO_MMIO_NO_LEGACY /* LEGACY DEVICES ONLY! */ + +/* Used Ring alignment for the currently selected queue - Write Only */ +#define VIRTIO_MMIO_QUEUE_ALIGN 0x03c + +/* Guest's PFN for the currently selected queue - Read Write */ +#define VIRTIO_MMIO_QUEUE_PFN 0x040 + +#endif + + +/* Ready bit for the currently selected queue - Read Write */ +#define VIRTIO_MMIO_QUEUE_READY 0x044 + +/* Queue notifier - Write Only */ +#define VIRTIO_MMIO_QUEUE_NOTIFY 0x050 + +/* Interrupt status - Read Only */ +#define VIRTIO_MMIO_INTERRUPT_STATUS 0x060 + +/* Interrupt...
2017 Jan 12
1
[PATCH 1/2] virtio_mmio: add standard header file
...y */ +#define VIRTIO_MMIO_QUEUE_NUM 0x038 + + +#ifndef VIRTIO_MMIO_NO_LEGACY /* LEGACY DEVICES ONLY! */ + +/* Used Ring alignment for the currently selected queue - Write Only */ +#define VIRTIO_MMIO_QUEUE_ALIGN 0x03c + +/* Guest's PFN for the currently selected queue - Read Write */ +#define VIRTIO_MMIO_QUEUE_PFN 0x040 + +#endif + + +/* Ready bit for the currently selected queue - Read Write */ +#define VIRTIO_MMIO_QUEUE_READY 0x044 + +/* Queue notifier - Write Only */ +#define VIRTIO_MMIO_QUEUE_NOTIFY 0x050 + +/* Interrupt status - Read Only */ +#define VIRTIO_MMIO_INTERRUPT_STATUS 0x060 + +/* Interrupt...
2011 Oct 27
1
[PATCH v3] virtio: Add platform bus driver for memory mapped virtio device
On Mon, 2011-10-24 at 03:33 +0100, Rusty Russell wrote: > No, that's it I think. Please send a diff for the documentation, since > I'm updating the LyX master and I've already applied your previous > version. Here it goes (below). Also do you think you would be able to merge the driver (corresponding v4 patch follows) in the 3.2 merge window that seems to have just opened?
2011 Oct 27
1
[PATCH v3] virtio: Add platform bus driver for memory mapped virtio device
On Mon, 2011-10-24 at 03:33 +0100, Rusty Russell wrote: > No, that's it I think. Please send a diff for the documentation, since > I'm updating the LyX master and I've already applied your previous > version. Here it goes (below). Also do you think you would be able to merge the driver (corresponding v4 patch follows) in the 3.2 merge window that seems to have just opened?
2012 Apr 07
0
[PATCH 05/14] kvm tools: Add virtio-mmio support
...S: + ioport__write32(data, *(u32 *)(((void *)&vmmio->hdr) + addr)); + break; + case VIRTIO_MMIO_HOST_FEATURES: + if (vmmio->hdr.host_features_sel == 0) + val = vdev->ops->get_host_features(vmmio->kvm, + vmmio->dev); + ioport__write32(data, val); + break; + case VIRTIO_MMIO_QUEUE_PFN: + val = vdev->ops->get_pfn_vq(vmmio->kvm, vmmio->dev, + vmmio->hdr.queue_sel); + ioport__write32(data, val); + break; + case VIRTIO_MMIO_QUEUE_NUM_MAX: + val = vdev->ops->get_size_vq(vmmio->kvm, vmmio->dev, + vmmio->hdr.queue_sel); + ioport__writ...
2012 Apr 07
0
[PATCH 05/14] kvm tools: Add virtio-mmio support
...S: + ioport__write32(data, *(u32 *)(((void *)&vmmio->hdr) + addr)); + break; + case VIRTIO_MMIO_HOST_FEATURES: + if (vmmio->hdr.host_features_sel == 0) + val = vdev->ops->get_host_features(vmmio->kvm, + vmmio->dev); + ioport__write32(data, val); + break; + case VIRTIO_MMIO_QUEUE_PFN: + val = vdev->ops->get_pfn_vq(vmmio->kvm, vmmio->dev, + vmmio->hdr.queue_sel); + ioport__write32(data, val); + break; + case VIRTIO_MMIO_QUEUE_NUM_MAX: + val = vdev->ops->get_size_vq(vmmio->kvm, vmmio->dev, + vmmio->hdr.queue_sel); + ioport__writ...
2011 Nov 15
2
[RFC] kvm tools: Add support for virtio-mmio
...u32 *)(((void *)&vmmio->hdr) + addr) = ioport__read32(data); + break; + case VIRTIO_MMIO_GUEST_FEATURES: + if (vmmio->hdr.guest_features_sel == 0) { + val = ioport__read32(data); + vtrans->virtio_ops->set_guest_features(vmmio->kvm, vmmio->dev, val); + } + break; + case VIRTIO_MMIO_QUEUE_PFN: + val = ioport__read32(data); + vtrans->virtio_ops->init_vq(vmmio->kvm, vmmio->dev, vmmio->hdr.queue_sel, val); + break; + case VIRTIO_MMIO_QUEUE_NOTIFY: + val = ioport__read32(data); + vtrans->virtio_ops->notify_vq(vmmio->kvm, vmmio->dev, val); + break; + case VIR...
2011 Nov 15
2
[RFC] kvm tools: Add support for virtio-mmio
...u32 *)(((void *)&vmmio->hdr) + addr) = ioport__read32(data); + break; + case VIRTIO_MMIO_GUEST_FEATURES: + if (vmmio->hdr.guest_features_sel == 0) { + val = ioport__read32(data); + vtrans->virtio_ops->set_guest_features(vmmio->kvm, vmmio->dev, val); + } + break; + case VIRTIO_MMIO_QUEUE_PFN: + val = ioport__read32(data); + vtrans->virtio_ops->init_vq(vmmio->kvm, vmmio->dev, vmmio->hdr.queue_sel, val); + break; + case VIRTIO_MMIO_QUEUE_NOTIFY: + val = ioport__read32(data); + vtrans->virtio_ops->notify_vq(vmmio->kvm, vmmio->dev, val); + break; + case VIR...
2011 Dec 21
0
[PATCH] virtio: harsher barriers for virtio-mmio.
...rr = -ENOMEM; diff --git a/drivers/virtio/virtio_mmio.c b/drivers/virtio/virtio_mmio.c --- a/drivers/virtio/virtio_mmio.c +++ b/drivers/virtio/virtio_mmio.c @@ -309,9 +309,10 @@ static struct virtqueue *vm_setup_vq(str writel(virt_to_phys(info->queue) >> PAGE_SHIFT, vm_dev->base + VIRTIO_MMIO_QUEUE_PFN); - /* Create the vring */ - vq = vring_new_virtqueue(info->num, VIRTIO_MMIO_VRING_ALIGN, - vdev, info->queue, vm_notify, callback, name); + /* Create the vring: no weak barriers, the other side is could + * be an independent "device". */ + vq = vring_new_virtqueue(info->n...