mirror of
https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git
synced 2024-09-29 13:53:33 +00:00
virtio_ring: allow to store zero as the ctx
Allow zero to be store as a ctx, with this we could store e.g zero value which could be meaningful for the case of storing headroom through ctx. Signed-off-by: Jason Wang <jasowang@redhat.com> Signed-off-by: David S. Miller <davem@davemloft.net>
This commit is contained in:
parent
7a68ada6ec
commit
87646a348e
1 changed files with 1 additions and 1 deletions
|
@ -391,7 +391,7 @@ static inline int virtqueue_add(struct virtqueue *_vq,
|
|||
vq->desc_state[head].data = data;
|
||||
if (indirect)
|
||||
vq->desc_state[head].indir_desc = desc;
|
||||
if (ctx)
|
||||
else
|
||||
vq->desc_state[head].indir_desc = ctx;
|
||||
|
||||
/* Put entry in available array (but don't update avail->idx until they
|
||||
|
|
Loading…
Reference in a new issue