On Sat, Jul 16, 2022 at 1:44 PM Eugenio Pérez <epere...@redhat.com> wrote: > > It allows to run commands at start of the device, before it have enabled > any queue. > > Signed-off-by: Eugenio Pérez <epere...@redhat.com> > --- > hw/virtio/vhost-shadow-virtqueue.h | 3 +++ > include/hw/virtio/vhost-vdpa.h | 5 +++++ > hw/virtio/vhost-vdpa.c | 8 ++++++++ > 3 files changed, 16 insertions(+) > > diff --git a/hw/virtio/vhost-shadow-virtqueue.h > b/hw/virtio/vhost-shadow-virtqueue.h > index 03eb7ff670..210fe393cd 100644 > --- a/hw/virtio/vhost-shadow-virtqueue.h > +++ b/hw/virtio/vhost-shadow-virtqueue.h > @@ -26,6 +26,8 @@ typedef struct SVQDescState { > } SVQDescState; > > typedef struct VhostShadowVirtqueue VhostShadowVirtqueue; > +typedef int (*ShadowVirtQueueStart)(VhostShadowVirtqueue *svq, > + void *opaque); > > /** > * Callback to handle an avail buffer. > @@ -43,6 +45,7 @@ typedef int (*VirtQueueAvailCallback)(VhostShadowVirtqueue > *svq, > void *vq_callback_opaque); > > typedef struct VhostShadowVirtqueueOps { > + ShadowVirtQueueStart start; > VirtQueueAvailCallback avail_handler; > } VhostShadowVirtqueueOps; >
Changes above are leftovers, I'll remove them for the next version.