diff options
author | Xuan Zhuo <xuanzhuo@linux.alibaba.com> | 2022-08-01 14:38:48 +0800 |
---|---|---|
committer | Michael S. Tsirkin <mst@redhat.com> | 2022-08-11 04:06:40 -0400 |
commit | 4913e85441b40386c4bb093f188b955d8165f1b7 (patch) | |
tree | 153f5bc9e18efcb0e626c4cbe61864fe763efe87 /drivers/virtio | |
parent | d94587b5bb5c4bba32fbc2bd92c86cc6de25167f (diff) | |
download | linux-stable-4913e85441b40386c4bb093f188b955d8165f1b7.tar.gz linux-stable-4913e85441b40386c4bb093f188b955d8165f1b7.tar.bz2 linux-stable-4913e85441b40386c4bb093f188b955d8165f1b7.zip |
virtio_ring: struct virtqueue introduce reset
Introduce a new member reset to the structure virtqueue to determine
whether the current vq is in the reset state. Subsequent patches will
use it.
Signed-off-by: Xuan Zhuo <xuanzhuo@linux.alibaba.com>
Acked-by: Jason Wang <jasowang@redhat.com>
Message-Id: <20220801063902.129329-29-xuanzhuo@linux.alibaba.com>
Signed-off-by: Michael S. Tsirkin <mst@redhat.com>
Diffstat (limited to 'drivers/virtio')
-rw-r--r-- | drivers/virtio/virtio_ring.c | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/drivers/virtio/virtio_ring.c b/drivers/virtio/virtio_ring.c index accb3ae6cc95..d66c8e6d0ef3 100644 --- a/drivers/virtio/virtio_ring.c +++ b/drivers/virtio/virtio_ring.c @@ -1996,6 +1996,7 @@ static struct virtqueue *vring_create_virtqueue_packed( vq->vq.vdev = vdev; vq->vq.name = name; vq->vq.index = index; + vq->vq.reset = false; vq->we_own_ring = true; vq->notify = notify; vq->weak_barriers = weak_barriers; @@ -2481,6 +2482,7 @@ static struct virtqueue *__vring_new_virtqueue(unsigned int index, vq->vq.vdev = vdev; vq->vq.name = name; vq->vq.index = index; + vq->vq.reset = false; vq->we_own_ring = false; vq->notify = notify; vq->weak_barriers = weak_barriers; |