Displaying 3 results from an estimated 3 matches for "vring_fill_notification_data".
2023 Mar 21
0
[PATCH v2] virtio: add VIRTIO_F_NOTIFICATION_DATA feature support
.../drivers/virtio/virtio_mmio.c
> @@ -285,6 +285,19 @@ static bool vm_notify(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_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 interru...
2023 Mar 21
0
[PATCH v2] virtio: add VIRTIO_F_NOTIFICATION_DATA feature support
.../drivers/virtio/virtio_mmio.c
> @@ -285,6 +285,19 @@ static bool vm_notify(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_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 interru...
2023 Mar 21
1
[PATCH v2] virtio: add VIRTIO_F_NOTIFICATION_DATA feature support
...irtqueue *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);
> >
> > Can we move this to the initialization?
>
> This data is new for each notification, because it helps to identify
> the next available index.
>
> >
> > Thanks
> >
>
> Thanks,
> Viktor Prutyanov