search for: get_vq_ready

Displaying 20 results from an estimated 134 matches for "get_vq_ready".

Did you mean: set_vq_ready
2019 Sep 25
3
[PATCH V2 6/8] mdev: introduce virtio device and its device ops
...mediated device > + * @idx: virtqueue index > + * @cb: virtio-mdev interrupt callback > structure > + * @set_vq_ready: Set ready status for a virtqueue > + * @mdev: mediated device > + * @idx: virtqueue index > + * @ready: ready (true) not ready(false) > + * @get_vq_ready: Get ready status for a virtqueue > + * @mdev: mediated device > + * @idx: virtqueue index > + * Returns boolean: ready (true) or not (false) > + * @set_vq_state: Set the state for a virtqueue > + * @mdev: mediated device > + * @idx: virtqueue index > + * @s...
2019 Sep 25
3
[PATCH V2 6/8] mdev: introduce virtio device and its device ops
...mediated device > + * @idx: virtqueue index > + * @cb: virtio-mdev interrupt callback > structure > + * @set_vq_ready: Set ready status for a virtqueue > + * @mdev: mediated device > + * @idx: virtqueue index > + * @ready: ready (true) not ready(false) > + * @get_vq_ready: Get ready status for a virtqueue > + * @mdev: mediated device > + * @idx: virtqueue index > + * Returns boolean: ready (true) or not (false) > + * @set_vq_state: Set the state for a virtqueue > + * @mdev: mediated device > + * @idx: virtqueue index > + * @s...
2019 Sep 24
0
[PATCH 4/6] virtio: introduce a mdev based transport
...o_mdev_callback cb; >> + struct virtqueue *vq; >> + u32 align, num; >> + u64 desc_addr, driver_addr, device_addr; >> + int err; >> + >> + if (!name) >> + return NULL; >> + >> + /* Queue shouldn't already be set up. */ >> + if (ops->get_vq_ready(mdev, index)) { >> + err = -ENOENT; >> + goto error_available; >> + } >> + > No need for a goto, to single return done later. > Just do > if (ops->get_vq_ready(mdev, index)) > return -ENOENT; Ok, will fix. > >> + /* Allocate and fill out our...
2019 Sep 25
2
[PATCH V2 6/8] mdev: introduce virtio device and its device ops
...@cb: virtio-mdev interrupt callback > > > structure > > > + * @set_vq_ready: Set ready status for a virtqueue > > > + * @mdev: mediated device > > > + * @idx: virtqueue index > > > + * @ready: ready (true) not ready(false) > > > + * @get_vq_ready: Get ready status for a virtqueue > > > + * @mdev: mediated device > > > + * @idx: virtqueue index > > > + * Returns boolean: ready (true) or not (false) > > > + * @set_vq_state: Set the state for a virtqueue > > > + * @mdev: mediated devic...
2019 Sep 25
2
[PATCH V2 6/8] mdev: introduce virtio device and its device ops
...@cb: virtio-mdev interrupt callback > > > structure > > > + * @set_vq_ready: Set ready status for a virtqueue > > > + * @mdev: mediated device > > > + * @idx: virtqueue index > > > + * @ready: ready (true) not ready(false) > > > + * @get_vq_ready: Get ready status for a virtqueue > > > + * @mdev: mediated device > > > + * @idx: virtqueue index > > > + * Returns boolean: ready (true) or not (false) > > > + * @set_vq_state: Set the state for a virtqueue > > > + * @mdev: mediated devic...
2019 Sep 24
3
[PATCH V2 6/8] mdev: introduce virtio device and its device ops
...dev: mediated device > + * @idx: virtqueue index > + * @cb: virtio-mdev interrupt callback structure > + * @set_vq_ready: Set ready status for a virtqueue > + * @mdev: mediated device > + * @idx: virtqueue index > + * @ready: ready (true) not ready(false) > + * @get_vq_ready: Get ready status for a virtqueue > + * @mdev: mediated device > + * @idx: virtqueue index > + * Returns boolean: ready (true) or not (false) > + * @set_vq_state: Set the state for a virtqueue > + * @mdev: mediated device > + * @idx: virtqueue index > + * @s...
2023 Apr 02
2
[PATCH] virtio-vdpa: add VIRTIO_F_NOTIFICATION_DATA feature support
...device *vdev, unsigned int index, if (index >= vdpa->nvqs) return ERR_PTR(-ENOENT); + if (__virtio_test_bit(vdev, VIRTIO_F_NOTIFICATION_DATA)) + notify = virtio_vdpa_notify_with_data; + else + notify = virtio_vdpa_notify; + /* Queue shouldn't already be set up. */ if (ops->get_vq_ready(vdpa, index)) return ERR_PTR(-ENOENT); @@ -183,8 +200,7 @@ virtio_vdpa_setup_vq(struct virtio_device *vdev, unsigned int index, dma_dev = vdpa_get_dma_dev(vdpa); vq = vring_create_virtqueue_dma(index, max_num, align, vdev, true, may_reduce_num, ctx, - virtio_vdpa_notify, callback,...
2023 Jan 29
1
[PATCH v3 2/2] vdpasim: support doorbell mapping
...kfree(vdpasim->config); > + if (vdpasim->notify) > + free_page(vdpasim->notify); > } > > static const struct vdpa_config_ops vdpasim_config_ops = { > @@ -704,6 +765,8 @@ static const struct vdpa_config_ops vdpasim_config_ops = { > .get_vq_ready = vdpasim_get_vq_ready, > .set_vq_state = vdpasim_set_vq_state, > .get_vq_state = vdpasim_get_vq_state, > + .get_vq_notification = vdpasim_get_vq_notification, > + .get_vq_notification_pgprot = vdpasim_get_vq_notification_pgpr...
2019 Nov 05
0
[PATCH V8 5/6] virtio: introduce a mdev based transport
...irtio_ops(mdev); + struct virtio_mdev_vq_info *info; + struct virtio_mdev_callback cb; + struct virtqueue *vq; + u64 desc_addr, driver_addr, device_addr; + unsigned long flags; + u32 align, num; + int err; + + if (!name) + return NULL; + + /* Queue shouldn't already be set up. */ + if (ops->get_vq_ready(mdev, index)) + return ERR_PTR(-ENOENT); + + /* Allocate and fill out our active queue description */ + info = kmalloc(sizeof(*info), GFP_KERNEL); + if (!info) + return ERR_PTR(-ENOMEM); + + num = ops->get_vq_num_max(mdev); + if (num == 0) { + err = -ENOENT; + goto error_new_virtqueue; + } +...
2020 Feb 10
0
[PATCH V2 4/5] virtio: introduce a vDPA based transport
...*ops = vdpa->config; + struct virtio_vdpa_vq_info *info; + struct vdpa_callback cb; + struct virtqueue *vq; + u64 desc_addr, driver_addr, device_addr; + unsigned long flags; + u32 align, num; + int err; + + if (!name) + return NULL; + + /* Queue shouldn't already be set up. */ + if (ops->get_vq_ready(vdpa, index)) + return ERR_PTR(-ENOENT); + + /* Allocate and fill out our active queue description */ + info = kmalloc(sizeof(*info), GFP_KERNEL); + if (!info) + return ERR_PTR(-ENOMEM); + + num = ops->get_vq_num_max(vdpa); + if (num == 0) { + err = -ENOENT; + goto error_new_virtqueue; + } +...
2020 Feb 20
0
[PATCH V3 4/5] virtio: introduce a vDPA based transport
...*ops = vdpa->config; + struct virtio_vdpa_vq_info *info; + struct vdpa_callback cb; + struct virtqueue *vq; + u64 desc_addr, driver_addr, device_addr; + unsigned long flags; + u32 align, num; + int err; + + if (!name) + return NULL; + + /* Queue shouldn't already be set up. */ + if (ops->get_vq_ready(vdpa, index)) + return ERR_PTR(-ENOENT); + + /* Allocate and fill out our active queue description */ + info = kmalloc(sizeof(*info), GFP_KERNEL); + if (!info) + return ERR_PTR(-ENOMEM); + + num = ops->get_vq_num_max(vdpa); + if (num == 0) { + err = -ENOENT; + goto error_new_virtqueue; + } +...
2019 Oct 17
0
[PATCH V4 5/6] virtio: introduce a mdev based transport
...t_dev_ops(mdev); + struct virtio_mdev_vq_info *info; + struct virtio_mdev_callback cb; + struct virtqueue *vq; + u64 desc_addr, driver_addr, device_addr; + unsigned long flags; + u32 align, num; + int err; + + if (!name) + return NULL; + + /* Queue shouldn't already be set up. */ + if (ops->get_vq_ready(mdev, index)) + return ERR_PTR(-ENOENT); + + /* Allocate and fill out our active queue description */ + info = kmalloc(sizeof(*info), GFP_KERNEL); + if (!info) + return ERR_PTR(-ENOMEM); + + num = ops->get_vq_num_max(mdev); + if (num == 0) { + err = -ENOENT; + goto error_new_virtqueue; + } +...
2019 Oct 11
0
[PATCH V3 6/7] virtio: introduce a mdev based transport
...t_dev_ops(mdev); + struct virtio_mdev_vq_info *info; + struct virtio_mdev_callback cb; + struct virtqueue *vq; + u64 desc_addr, driver_addr, device_addr; + unsigned long flags; + u32 align, num; + int err; + + if (!name) + return NULL; + + /* Queue shouldn't already be set up. */ + if (ops->get_vq_ready(mdev, index)) + return ERR_PTR(-ENOENT); + + /* Allocate and fill out our active queue description */ + info = kmalloc(sizeof(*info), GFP_KERNEL); + if (!info) + return ERR_PTR(-ENOMEM); + + num = ops->get_vq_num_max(mdev); + if (num == 0) { + err = -ENOENT; + goto error_new_virtqueue; + } +...
2019 Nov 06
0
[PATCH V9 5/6] virtio: introduce a mdev based transport
...irtio_ops(mdev); + struct virtio_mdev_vq_info *info; + struct virtio_mdev_callback cb; + struct virtqueue *vq; + u64 desc_addr, driver_addr, device_addr; + unsigned long flags; + u32 align, num; + int err; + + if (!name) + return NULL; + + /* Queue shouldn't already be set up. */ + if (ops->get_vq_ready(mdev, index)) + return ERR_PTR(-ENOENT); + + /* Allocate and fill out our active queue description */ + info = kmalloc(sizeof(*info), GFP_KERNEL); + if (!info) + return ERR_PTR(-ENOMEM); + + num = ops->get_vq_num_max(mdev); + if (num == 0) { + err = -ENOENT; + goto error_new_virtqueue; + } +...
2019 Oct 18
2
[PATCH V4 4/6] mdev: introduce virtio device and its device ops
...dev: mediated device > + * @idx: virtqueue index > + * @cb: virtio-mdev interrupt callback structure > + * @set_vq_ready: Set ready status for a virtqueue > + * @mdev: mediated device > + * @idx: virtqueue index > + * @ready: ready (true) not ready(false) > + * @get_vq_ready: Get ready status for a virtqueue > + * @mdev: mediated device > + * @idx: virtqueue index > + * Returns boolean: ready (true) or not (false) > + * @set_vq_state: Set the state for a virtqueue > + * @mdev: mediated device > + * @idx: virtqueue index > + * @s...
2019 Oct 18
2
[PATCH V4 4/6] mdev: introduce virtio device and its device ops
...dev: mediated device > + * @idx: virtqueue index > + * @cb: virtio-mdev interrupt callback structure > + * @set_vq_ready: Set ready status for a virtqueue > + * @mdev: mediated device > + * @idx: virtqueue index > + * @ready: ready (true) not ready(false) > + * @get_vq_ready: Get ready status for a virtqueue > + * @mdev: mediated device > + * @idx: virtqueue index > + * Returns boolean: ready (true) or not (false) > + * @set_vq_state: Set the state for a virtqueue > + * @mdev: mediated device > + * @idx: virtqueue index > + * @s...
2019 Oct 23
2
[PATCH V5 4/6] mdev: introduce virtio device and its device ops
...dev: mediated device > + * @idx: virtqueue index > + * @cb: virtio-mdev interrupt callback structure > + * @set_vq_ready: Set ready status for a virtqueue > + * @mdev: mediated device > + * @idx: virtqueue index > + * @ready: ready (true) not ready(false) > + * @get_vq_ready: Get ready status for a virtqueue > + * @mdev: mediated device > + * @idx: virtqueue index > + * Returns boolean: ready (true) or not (false) > + * @set_vq_state: Set the state for a virtqueue > + * @mdev: mediated device > + * @idx: virtqueue index > + * @s...
2019 Oct 23
2
[PATCH V5 4/6] mdev: introduce virtio device and its device ops
...dev: mediated device > + * @idx: virtqueue index > + * @cb: virtio-mdev interrupt callback structure > + * @set_vq_ready: Set ready status for a virtqueue > + * @mdev: mediated device > + * @idx: virtqueue index > + * @ready: ready (true) not ready(false) > + * @get_vq_ready: Get ready status for a virtqueue > + * @mdev: mediated device > + * @idx: virtqueue index > + * Returns boolean: ready (true) or not (false) > + * @set_vq_state: Set the state for a virtqueue > + * @mdev: mediated device > + * @idx: virtqueue index > + * @s...
2019 Oct 18
1
[PATCH V4 4/6] mdev: introduce virtio device and its device ops
...(struct mdev_device *mdev, u16 idx, u32 num); > + void (*kick_vq)(struct mdev_device *mdev, u16 idx); > + void (*set_vq_cb)(struct mdev_device *mdev, u16 idx, > + struct virtio_mdev_callback *cb); > + void (*set_vq_ready)(struct mdev_device *mdev, u16 idx, bool ready); > + bool (*get_vq_ready)(struct mdev_device *mdev, u16 idx); > + int (*set_vq_state)(struct mdev_device *mdev, u16 idx, u64 state); > + u64 (*get_vq_state)(struct mdev_device *mdev, u16 idx); > + > + /* Device ops */ > + u16 (*get_vq_align)(struct mdev_device *mdev); > + u64 (*get_features)(struct mdev_d...
2019 Sep 24
0
[PATCH V2 6/8] mdev: introduce virtio device and its device ops
...on for + * a virtqueue + * @mdev: mediated device + * @idx: virtqueue index + * @cb: virtio-mdev interrupt callback structure + * @set_vq_ready: Set ready status for a virtqueue + * @mdev: mediated device + * @idx: virtqueue index + * @ready: ready (true) not ready(false) + * @get_vq_ready: Get ready status for a virtqueue + * @mdev: mediated device + * @idx: virtqueue index + * Returns boolean: ready (true) or not (false) + * @set_vq_state: Set the state for a virtqueue + * @mdev: mediated device + * @idx: virtqueue index + * @state: virtqueue state (last_avail_i...