Lines Matching refs:desc
19 struct vring_desc *desc; in virtqueue_add() local
28 desc = vq->vring.desc; in virtqueue_add()
48 desc[i].flags = cpu_to_virtio16(vq->vdev, VRING_DESC_F_NEXT); in virtqueue_add()
49 desc[i].addr = cpu_to_virtio64(vq->vdev, (u64)(size_t)sg->addr); in virtqueue_add()
50 desc[i].len = cpu_to_virtio32(vq->vdev, sg->length); in virtqueue_add()
53 i = virtio16_to_cpu(vq->vdev, desc[i].next); in virtqueue_add()
58 desc[i].flags = cpu_to_virtio16(vq->vdev, VRING_DESC_F_NEXT | in virtqueue_add()
60 desc[i].addr = cpu_to_virtio64(vq->vdev, in virtqueue_add()
62 desc[i].len = cpu_to_virtio32(vq->vdev, sg->length); in virtqueue_add()
65 i = virtio16_to_cpu(vq->vdev, desc[i].next); in virtqueue_add()
68 desc[prev].flags &= cpu_to_virtio16(vq->vdev, ~VRING_DESC_F_NEXT); in virtqueue_add()
142 while (vq->vring.desc[i].flags & nextflag) { in detach_buf()
143 i = virtio16_to_cpu(vq->vdev, vq->vring.desc[i].next); in detach_buf()
147 vq->vring.desc[i].next = cpu_to_virtio16(vq->vdev, vq->free_head); in detach_buf()
201 vq->vring.desc[i].addr); in virtqueue_get_buf()
238 vq->vring.desc[i].next = cpu_to_virtio16(vdev, i + 1); in __vring_new_virtqueue()
290 free(vq->vring.desc); in vring_del_virtqueue()
302 return (ulong)vq->vring.desc; in virtqueue_get_desc_addr()
307 return (ulong)vq->vring.desc + in virtqueue_get_avail_addr()
308 ((char *)vq->vring.avail - (char *)vq->vring.desc); in virtqueue_get_avail_addr()
313 return (ulong)vq->vring.desc + in virtqueue_get_used_addr()
314 ((char *)vq->vring.used - (char *)vq->vring.desc); in virtqueue_get_used_addr()
330 vq->index, vq->vring.desc, vq->vring.num); in virtqueue_dump()
339 i, vq->vring.desc[i].addr, vq->vring.desc[i].len, in virtqueue_dump()
340 vq->vring.desc[i].flags, vq->vring.desc[i].next); in virtqueue_dump()