search for: virtio_mmio_queue_notify

Displaying 20 results from an estimated 34 matches for "virtio_mmio_queue_notify".

2017 Jan 12
1
[PATCH 1/2] virtio_mmio: add standard header file
...TIO_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 acknowledge - Write Only */ +#define VIRTIO_MMIO_INTERRUPT_ACK 0x064 + +/* Device status register - Read Write */ +#define VIRTIO_MMIO_STATUS 0x070 + +/* Selected queue's Descriptor Table ad...
2017 Jan 12
1
[PATCH 1/2] virtio_mmio: add standard header file
...TIO_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 acknowledge - Write Only */ +#define VIRTIO_MMIO_INTERRUPT_ACK 0x064 + +/* Device status register - Read Write */ +#define VIRTIO_MMIO_STATUS 0x070 + +/* Selected queue's Descriptor Table ad...
2012 Apr 07
0
[PATCH 05/14] kvm tools: Add virtio-mmio support
...struct virtio_device *vdev, u32 vq) +{ + struct virtio_mmio *vmmio = vdev->virtio; + struct ioevent ioevent; + int err; + + vmmio->ioeventfds[vq] = (struct virtio_mmio_ioevent_param) { + .vdev = vdev, + .vq = vq, + }; + + ioevent = (struct ioevent) { + .io_addr = vmmio->addr + VIRTIO_MMIO_QUEUE_NOTIFY, + .io_len = sizeof(u32), + .fn = virtio_mmio_ioevent_callback, + .fn_ptr = &vmmio->ioeventfds[vq], + .datamatch = vq, + .fn_kvm = kvm, + .fd = eventfd(0, 0), + }; + + err = ioeventfd__add_event(&ioevent, false); + if (err) + return err; + + if (vdev->ops->notify_vq_eve...
2012 Apr 07
0
[PATCH 05/14] kvm tools: Add virtio-mmio support
...struct virtio_device *vdev, u32 vq) +{ + struct virtio_mmio *vmmio = vdev->virtio; + struct ioevent ioevent; + int err; + + vmmio->ioeventfds[vq] = (struct virtio_mmio_ioevent_param) { + .vdev = vdev, + .vq = vq, + }; + + ioevent = (struct ioevent) { + .io_addr = vmmio->addr + VIRTIO_MMIO_QUEUE_NOTIFY, + .io_len = sizeof(u32), + .fn = virtio_mmio_ioevent_callback, + .fn_ptr = &vmmio->ioeventfds[vq], + .datamatch = vq, + .fn_kvm = kvm, + .fd = eventfd(0, 0), + }; + + err = ioeventfd__add_event(&ioevent, false); + if (err) + return err; + + if (vdev->ops->notify_vq_eve...
2012 Oct 16
6
[PATCH 1/5] virtio: move queue_index and num_free fields into core struct virtqueue.
...644 --- a/drivers/virtio/virtio_mmio.c +++ b/drivers/virtio/virtio_mmio.c @@ -225,7 +225,7 @@ static void vm_notify(struct virtqueue *vq) /* We write the queue's selector into the notification register to * signal the other end */ - writel(virtqueue_get_queue_index(vq), vm_dev->base + VIRTIO_MMIO_QUEUE_NOTIFY); + writel(vq->index, vm_dev->base + VIRTIO_MMIO_QUEUE_NOTIFY); } /* Notify all virtqueues on an interrupt. */ @@ -266,7 +266,7 @@ static void vm_del_vq(struct virtqueue *vq) struct virtio_mmio_device *vm_dev = to_virtio_mmio_device(vq->vdev); struct virtio_mmio_vq_info *info = vq-...
2012 Oct 16
6
[PATCH 1/5] virtio: move queue_index and num_free fields into core struct virtqueue.
...644 --- a/drivers/virtio/virtio_mmio.c +++ b/drivers/virtio/virtio_mmio.c @@ -225,7 +225,7 @@ static void vm_notify(struct virtqueue *vq) /* We write the queue's selector into the notification register to * signal the other end */ - writel(virtqueue_get_queue_index(vq), vm_dev->base + VIRTIO_MMIO_QUEUE_NOTIFY); + writel(vq->index, vm_dev->base + VIRTIO_MMIO_QUEUE_NOTIFY); } /* Notify all virtqueues on an interrupt. */ @@ -266,7 +266,7 @@ static void vm_del_vq(struct virtqueue *vq) struct virtio_mmio_device *vm_dev = to_virtio_mmio_device(vq->vdev); struct virtio_mmio_vq_info *info = vq-...
2023 Mar 23
1
[PATCH v4] virtio: add VIRTIO_F_NOTIFICATION_DATA feature support
...otify(struct virtqueue *vq) > return true; > } > > +static bool vm_notify_with_data(struct virtqueue *vq) > +{ > + struct virtio_mmio_device *vm_dev = to_virtio_mmio_device(vq->vdev); > + u32 data = vring_notification_data(vq); > + > + writel(data, vm_dev->base + VIRTIO_MMIO_QUEUE_NOTIFY); > + > + return true; > +} > + > /* Notify all virtqueues on an interrupt. */ > static irqreturn_t vm_interrupt(int irq, void *opaque) > { > @@ -368,6 +378,8 @@ static struct virtqueue *vm_setup_vq(struct virtio_device *vdev, unsigned int in > unsigned long flags; &...
2023 Mar 23
1
[PATCH v4] virtio: add VIRTIO_F_NOTIFICATION_DATA feature support
...gt; +static bool vm_notify_with_data(struct virtqueue *vq) > > > +{ > > > + struct virtio_mmio_device *vm_dev = to_virtio_mmio_device(vq->vdev); > > > + u32 data = vring_notification_data(vq); > > > + > > > + writel(data, vm_dev->base + VIRTIO_MMIO_QUEUE_NOTIFY); > > > + > > > + return true; > > > +} > > > + > > > /* Notify all virtqueues on an interrupt. */ > > > static irqreturn_t vm_interrupt(int irq, void *opaque) > > > { > > > @@ -368,6 +378,8 @@ static struct virtqueue *v...
2023 Mar 21
0
[PATCH v2] virtio: add VIRTIO_F_NOTIFICATION_DATA feature support
...truct virtqueue *vq) > return true; > } > > +static bool vm_notify_with_data(struct virtqueue *vq) > +{ > + struct virtio_mmio_device *vm_dev = to_virtio_mmio_device(vq->vdev); > + u32 data = vring_fill_notification_data(vq); > + > + writel(data, vm_dev->base + VIRTIO_MMIO_QUEUE_NOTIFY); > + > + return true; > +} > + > +#define VM_NOTIFY(vdev) (__virtio_test_bit((vdev), VIRTIO_F_NOTIFICATION_DATA) \ > + ? vm_notify_with_data : vm_notify) > + > /* Notify all virtqueues on an interrupt. */ > static irqreturn_t vm_interrupt(int irq, void *opaque) > {...
2023 Mar 21
0
[PATCH v2] virtio: add VIRTIO_F_NOTIFICATION_DATA feature support
...truct virtqueue *vq) > return true; > } > > +static bool vm_notify_with_data(struct virtqueue *vq) > +{ > + struct virtio_mmio_device *vm_dev = to_virtio_mmio_device(vq->vdev); > + u32 data = vring_fill_notification_data(vq); > + > + writel(data, vm_dev->base + VIRTIO_MMIO_QUEUE_NOTIFY); > + > + return true; > +} > + > +#define VM_NOTIFY(vdev) (__virtio_test_bit((vdev), VIRTIO_F_NOTIFICATION_DATA) \ > + ? vm_notify_with_data : vm_notify) > + > /* Notify all virtqueues on an interrupt. */ > static irqreturn_t vm_interrupt(int irq, void *opaque) > {...
2023 Mar 21
0
[PATCH v3] virtio: add VIRTIO_F_NOTIFICATION_DATA feature support
...ify(struct virtqueue *vq) > return true; > } > > +static bool vm_notify_with_data(struct virtqueue *vq) > +{ > + struct virtio_mmio_device *vm_dev = to_virtio_mmio_device(vq->vdev); > + u32 data = vring_notification_data(vq); > + > + writel(data, vm_dev->base + VIRTIO_MMIO_QUEUE_NOTIFY); > + > + return true; > +} > + > /* Notify all virtqueues on an interrupt. */ > static irqreturn_t vm_interrupt(int irq, void *opaque) > { > @@ -368,6 +378,8 @@ static struct virtqueue *vm_setup_vq(struct virtio_device *vdev, unsigned int in > unsigned long flags; &...
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?
2023 Mar 23
0
[PATCH v5] virtio: add VIRTIO_F_NOTIFICATION_DATA feature support
...otify(struct virtqueue *vq) > return true; > } > > +static bool vm_notify_with_data(struct virtqueue *vq) > +{ > + struct virtio_mmio_device *vm_dev = to_virtio_mmio_device(vq->vdev); > + u32 data = vring_notification_data(vq); > + > + writel(data, vm_dev->base + VIRTIO_MMIO_QUEUE_NOTIFY); > + > + return true; > +} > + > /* Notify all virtqueues on an interrupt. */ > static irqreturn_t vm_interrupt(int irq, void *opaque) > { > @@ -368,6 +378,12 @@ static struct virtqueue *vm_setup_vq(struct virtio_device *vdev, unsigned int in > unsigned long flags;...
2013 Oct 24
0
[PATCH V2 RFC 1/9] virtio_ring: change host notification API
...d vm_notify(struct virtqueue *vq) +static int vm_notify(struct virtqueue *vq) { struct virtio_mmio_device *vm_dev = to_virtio_mmio_device(vq->vdev); /* We write the queue's selector into the notification register to * signal the other end */ writel(vq->index, vm_dev->base + VIRTIO_MMIO_QUEUE_NOTIFY); + return 0; } /* Notify all virtqueues on an interrupt. */ diff --git a/drivers/virtio/virtio_pci.c b/drivers/virtio/virtio_pci.c index a7ce730..7988137 100644 --- a/drivers/virtio/virtio_pci.c +++ b/drivers/virtio/virtio_pci.c @@ -197,13 +197,14 @@ static void vp_reset(struct virtio_device *...
2023 Mar 22
1
[PATCH v4] virtio: add VIRTIO_F_NOTIFICATION_DATA feature support
...ify(struct virtqueue *vq) > return true; > } > > +static bool vm_notify_with_data(struct virtqueue *vq) > +{ > + struct virtio_mmio_device *vm_dev = to_virtio_mmio_device(vq->vdev); > + u32 data = vring_notification_data(vq); > + > + writel(data, vm_dev->base + VIRTIO_MMIO_QUEUE_NOTIFY); > + > + return true; > +} > + > /* Notify all virtqueues on an interrupt. */ > static irqreturn_t vm_interrupt(int irq, void *opaque) > { > @@ -368,6 +378,8 @@ static struct virtqueue *vm_setup_vq(struct virtio_device *vdev, unsigned int in > unsigned long flags; &...
2015 Jan 20
4
[PATCH v2] virtio-mmio: Update the device to OASIS spec version
...TIO_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 @@ -95,6 +110,21 @@ /* Device status register - Read Write */ #define VIRTIO_MMIO_STATUS 0x070 +/* Selected queue's Descriptor Table address, 64 bits in two halves */ +#define VIRTIO_MMIO_QUEUE_DESC_LOW 0x080 +#define VIRTIO_MMIO_QUEUE_DESC_HIGH 0x084 + +/* Selected queue's Ava...
2015 Jan 20
4
[PATCH v2] virtio-mmio: Update the device to OASIS spec version
...TIO_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 @@ -95,6 +110,21 @@ /* Device status register - Read Write */ #define VIRTIO_MMIO_STATUS 0x070 +/* Selected queue's Descriptor Table address, 64 bits in two halves */ +#define VIRTIO_MMIO_QUEUE_DESC_LOW 0x080 +#define VIRTIO_MMIO_QUEUE_DESC_HIGH 0x084 + +/* Selected queue's Ava...
2013 Oct 28
2
[PATCH V2 RFC 1/9] virtio_ring: change host notification API
Rusty, here is just patch 1 (using bool as return value in notify API). Thanks. Heinz Graalfs (9): virtio_ring: change host notification API virtio_ring: let virtqueue_{kick()/notify()} return a bool virtio_net: verify if virtqueue_kick() succeeded virtio_test: verify if virtqueue_kick() succeeded virtio_ring: add new function virtqueue_is_broken() virtio_blk: verify if queue is
2013 Oct 28
2
[PATCH V2 RFC 1/9] virtio_ring: change host notification API
Rusty, here is just patch 1 (using bool as return value in notify API). Thanks. Heinz Graalfs (9): virtio_ring: change host notification API virtio_ring: let virtqueue_{kick()/notify()} return a bool virtio_net: verify if virtqueue_kick() succeeded virtio_test: verify if virtqueue_kick() succeeded virtio_ring: add new function virtqueue_is_broken() virtio_blk: verify if queue is