Lines Matching refs:last_used
830 u16 last_used; in virtqueue_get_buf_ctx_split() local
848 last_used = (vq->last_used_idx & (vq->split.vring.num - 1)); in virtqueue_get_buf_ctx_split()
850 vq->split.vring.used->ring[last_used].id); in virtqueue_get_buf_ctx_split()
852 vq->split.vring.used->ring[last_used].len); in virtqueue_get_buf_ctx_split()
1663 u16 last_used; in more_used_packed() local
1668 last_used = packed_last_used(last_used_idx); in more_used_packed()
1670 return is_used_desc_packed(vq, last_used, used_wrap_counter); in more_used_packed()
1678 u16 last_used, id, last_used_idx; in virtqueue_get_buf_ctx_packed() local
1700 last_used = packed_last_used(last_used_idx); in virtqueue_get_buf_ctx_packed()
1701 id = le16_to_cpu(vq->packed.vring.desc[last_used].id); in virtqueue_get_buf_ctx_packed()
1702 *len = le32_to_cpu(vq->packed.vring.desc[last_used].len); in virtqueue_get_buf_ctx_packed()
1717 last_used += vq->packed.desc_state[id].num; in virtqueue_get_buf_ctx_packed()
1718 if (unlikely(last_used >= vq->packed.vring.num)) { in virtqueue_get_buf_ctx_packed()
1719 last_used -= vq->packed.vring.num; in virtqueue_get_buf_ctx_packed()
1723 last_used = (last_used | (used_wrap_counter << VRING_PACKED_EVENT_F_WRAP_CTR)); in virtqueue_get_buf_ctx_packed()
1724 WRITE_ONCE(vq->last_used_idx, last_used); in virtqueue_get_buf_ctx_packed()