Home
last modified time | relevance | path

Searched full:vring (Results 1 – 25 of 72) sorted by relevance

123

/Linux-v6.1/drivers/platform/mellanox/
Dmlxbf-tmfifo.c26 /* Vring size. */
63 * @num: vring size (number of descriptors)
64 * @align: vring alignment size
65 * @index: vring index
66 * @vdev_id: vring virtio id (VIRTIO_ID_xxx)
151 * @vring: Tx/Rx ring
166 struct mlxbf_tmfifo_vring *vring[2]; member
211 struct mlxbf_tmfifo_vring *vring; in mlxbf_tmfifo_free_vrings() local
215 vring = &tm_vdev->vrings[i]; in mlxbf_tmfifo_free_vrings()
216 if (vring->va) { in mlxbf_tmfifo_free_vrings()
[all …]
/Linux-v6.1/drivers/net/wireless/ath/wil6210/
Dtxrx.c71 struct wil_ring *vring = &wil->ring_tx[i]; in wil_is_tx_idle() local
72 int vring_index = vring - wil->ring_tx; in wil_is_tx_idle()
78 if (!vring->va || !txdata->enabled) { in wil_is_tx_idle()
86 while (!wil_ring_is_empty(vring)) { in wil_is_tx_idle()
94 "tx vring is not empty -> NAPI\n"); in wil_is_tx_idle()
99 if (!vring->va || !txdata->enabled) in wil_is_tx_idle()
110 static int wil_vring_alloc(struct wil6210_priv *wil, struct wil_ring *vring) in wil_vring_alloc() argument
113 size_t sz = vring->size * sizeof(vring->va[0]); in wil_vring_alloc()
118 BUILD_BUG_ON(sizeof(vring->va[0]) != 32); in wil_vring_alloc()
120 vring->swhead = 0; in wil_vring_alloc()
[all …]
Dtrace.h212 TP_PROTO(u8 vring, u16 index, unsigned int len, u8 frags),
213 TP_ARGS(vring, index, len, frags),
215 __field(u8, vring)
221 __entry->vring = vring;
226 TP_printk("vring %d index %d len %d frags %d",
227 __entry->vring, __entry->index, __entry->len, __entry->frags)
231 TP_PROTO(u8 vring, u16 index, unsigned int len, u8 err),
232 TP_ARGS(vring, index, len, err),
234 __field(u8, vring)
240 __entry->vring = vring;
[all …]
/Linux-v6.1/drivers/vhost/
Dvringh.c37 /* Returns vring->num if empty, -ve on error. */
46 err = getu16(vrh, &avail_idx, &vrh->vring.avail->idx); in __vringh_get_head()
49 &vrh->vring.avail->idx); in __vringh_get_head()
54 return vrh->vring.num; in __vringh_get_head()
59 i = *last_avail_idx & (vrh->vring.num - 1); in __vringh_get_head()
61 err = getu16(vrh, &head, &vrh->vring.avail->ring[i]); in __vringh_get_head()
64 *last_avail_idx, &vrh->vring.avail->ring[i]); in __vringh_get_head()
68 if (head >= vrh->vring.num) { in __vringh_get_head()
70 head, vrh->vring.num); in __vringh_get_head()
241 *descs = vrh->vring.desc; in return_from_indirect()
[all …]
/Linux-v6.1/drivers/vdpa/ifcvf/
Difcvf_main.c32 struct vring_info *vring = arg; in ifcvf_vq_intr_handler() local
34 if (vring->cb.callback) in ifcvf_vq_intr_handler()
35 return vring->cb.callback(vring->cb.private); in ifcvf_vq_intr_handler()
43 struct vring_info *vring; in ifcvf_vqs_reused_intr_handler() local
47 vring = &vf->vring[i]; in ifcvf_vqs_reused_intr_handler()
48 if (vring->cb.callback) in ifcvf_vqs_reused_intr_handler()
49 vring->cb.callback(vring->cb.private); in ifcvf_vqs_reused_intr_handler()
79 if (vf->vring[i].irq != -EINVAL) { in ifcvf_free_per_vq_irq()
80 devm_free_irq(&pdev->dev, vf->vring[i].irq, &vf->vring[i]); in ifcvf_free_per_vq_irq()
81 vf->vring[i].irq = -EINVAL; in ifcvf_free_per_vq_irq()
[all …]
Difcvf_base.c150 hw->vring[i].notify_addr = hw->notify_base + in ifcvf_init_hw()
152 hw->vring[i].notify_pa = hw->notify_base_pa + in ifcvf_init_hw()
154 hw->vring[i].irq = -EINVAL; in ifcvf_init_hw()
342 hw->vring[qid].last_avail_idx = num; in ifcvf_set_vq_state()
355 if (!hw->vring[i].ready) in ifcvf_hw_enable()
359 vp_iowrite64_twopart(hw->vring[i].desc, &cfg->queue_desc_lo, in ifcvf_hw_enable()
361 vp_iowrite64_twopart(hw->vring[i].avail, &cfg->queue_avail_lo, in ifcvf_hw_enable()
363 vp_iowrite64_twopart(hw->vring[i].used, &cfg->queue_used_lo, in ifcvf_hw_enable()
365 vp_iowrite16(hw->vring[i].size, &cfg->queue_size); in ifcvf_hw_enable()
366 ifcvf_set_vq_state(hw, i, hw->vring[i].last_avail_idx); in ifcvf_hw_enable()
[all …]
/Linux-v6.1/drivers/virtio/
Dvirtio_ring.c91 struct vring vring; member
112 * vring.
125 } vring; member
343 * making all of the arch DMA ops work on the vring device itself
496 struct vring_virtqueue *vring = to_vvq(vq); in virtqueue_add_desc_split() local
497 struct vring_desc_extra *extra = vring->split.desc_extra; in virtqueue_add_desc_split()
553 WARN_ON_ONCE(total_sg > vq->split.vring.num && !vq->indirect); in virtqueue_add_split()
564 desc = vq->split.vring.desc; in virtqueue_add_split()
618 vq->split.desc_extra[prev & (vq->split.vring.num - 1)].flags &= in virtqueue_add_split()
629 virtqueue_add_desc_split(_vq, vq->split.vring.desc, in virtqueue_add_split()
[all …]
/Linux-v6.1/drivers/vdpa/virtio_pci/
Dvp_vdpa.c37 struct vp_vring *vring; member
102 int irq = vp_vdpa->vring[idx].irq; in vp_vdpa_get_vq_irq()
117 if (vp_vdpa->vring[i].irq != VIRTIO_MSI_NO_VECTOR) { in vp_vdpa_free_irq()
119 devm_free_irq(&pdev->dev, vp_vdpa->vring[i].irq, in vp_vdpa_free_irq()
120 &vp_vdpa->vring[i]); in vp_vdpa_free_irq()
121 vp_vdpa->vring[i].irq = VIRTIO_MSI_NO_VECTOR; in vp_vdpa_free_irq()
139 struct vp_vring *vring = arg; in vp_vdpa_vq_handler() local
141 if (vring->cb.callback) in vp_vdpa_vq_handler()
142 return vring->cb.callback(vring->cb.private); in vp_vdpa_vq_handler()
176 snprintf(vp_vdpa->vring[i].msix_name, VP_VDPA_NAME_SIZE, in vp_vdpa_request_irq()
[all …]
/Linux-v6.1/drivers/vdpa/alibaba/
Deni_vdpa.c41 struct eni_vring *vring; member
104 int irq = eni_vdpa->vring[idx].irq; in eni_vdpa_get_vq_irq()
119 if (eni_vdpa->vring[i].irq != VIRTIO_MSI_NO_VECTOR) { in eni_vdpa_free_irq()
121 devm_free_irq(&pdev->dev, eni_vdpa->vring[i].irq, in eni_vdpa_free_irq()
122 &eni_vdpa->vring[i]); in eni_vdpa_free_irq()
123 eni_vdpa->vring[i].irq = VIRTIO_MSI_NO_VECTOR; in eni_vdpa_free_irq()
141 struct eni_vring *vring = arg; in eni_vdpa_vq_handler() local
143 if (vring->cb.callback) in eni_vdpa_vq_handler()
144 return vring->cb.callback(vring->cb.private); in eni_vdpa_vq_handler()
178 snprintf(eni_vdpa->vring[i].msix_name, ENI_MSIX_NAME_SIZE, in eni_vdpa_request_irq()
[all …]
/Linux-v6.1/drivers/vdpa/vdpa_sim/
Dvdpa_sim_net.c44 vringh_complete_iotlb(&vq->vring, vq->head, len); in vdpasim_net_complete()
50 if (vringh_need_notify_iotlb(&vq->vring) > 0) in vdpasim_net_complete()
51 vringh_notify(&vq->vring); in vdpasim_net_complete()
81 read = vringh_iov_pull_iotlb(&cvq->vring, &cvq->in_iov, in vdpasim_handle_ctrl_mac()
108 err = vringh_getdesc_iotlb(&cvq->vring, &cvq->in_iov, in vdpasim_handle_cvq()
114 read = vringh_iov_pull_iotlb(&cvq->vring, &cvq->in_iov, &ctrl, in vdpasim_handle_cvq()
130 write = vringh_iov_push_iotlb(&cvq->vring, &cvq->out_iov, in vdpasim_handle_cvq()
132 vringh_complete_iotlb(&cvq->vring, cvq->head, write); in vdpasim_handle_cvq()
169 err = vringh_getdesc_iotlb(&txq->vring, &txq->out_iov, NULL, in vdpasim_net_work()
174 read = vringh_iov_pull_iotlb(&txq->vring, &txq->out_iov, in vdpasim_net_work()
[all …]
Dvdpa_sim_blk.c92 ret = vringh_getdesc_iotlb(&vq->vring, &vq->out_iov, &vq->in_iov, in vdpasim_blk_handle_req()
115 bytes = vringh_iov_pull_iotlb(&vq->vring, &vq->out_iov, &hdr, in vdpasim_blk_handle_req()
147 bytes = vringh_iov_push_iotlb(&vq->vring, &vq->in_iov, in vdpasim_blk_handle_req()
169 bytes = vringh_iov_pull_iotlb(&vq->vring, &vq->out_iov, in vdpasim_blk_handle_req()
182 bytes = vringh_iov_push_iotlb(&vq->vring, &vq->in_iov, in vdpasim_blk_handle_req()
212 bytes = vringh_iov_pull_iotlb(&vq->vring, &vq->out_iov, &range, in vdpasim_blk_handle_req()
272 bytes = vringh_iov_push_iotlb(&vq->vring, &vq->in_iov, &status, 1); in vdpasim_blk_handle_req()
284 vringh_complete_iotlb(&vq->vring, vq->head, pushed); in vdpasim_blk_handle_req()
315 if (vringh_need_notify_iotlb(&vq->vring) > 0) in vdpasim_blk_work()
316 vringh_notify(&vq->vring); in vdpasim_blk_work()
Dvdpa_sim.c55 static void vdpasim_vq_notify(struct vringh *vring) in vdpasim_vq_notify() argument
58 container_of(vring, struct vdpasim_virtqueue, vring); in vdpasim_vq_notify()
70 vringh_init_iotlb(&vq->vring, vdpasim->dev_attr.supported_features, in vdpasim_queue_ready()
78 vq->vring.notify = vdpasim_vq_notify; in vdpasim_queue_ready()
90 vringh_init_iotlb(&vq->vring, vdpasim->dev_attr.supported_features, in vdpasim_vq_reset()
93 vq->vring.notify = NULL; in vdpasim_vq_reset()
104 vringh_set_iotlb(&vdpasim->vqs[i].vring, &vdpasim->iommu[0], in vdpasim_do_reset()
312 vringh_set_iotlb(&vdpasim->vqs[i].vring, &vdpasim->iommu[0], in vdpasim_create()
402 struct vringh *vrh = &vq->vring; in vdpasim_set_vq_state()
416 struct vringh *vrh = &vq->vring; in vdpasim_get_vq_state()
[all …]
/Linux-v6.1/tools/virtio/
Dvringh_test.c116 err = get_user(avail_idx, &vrh->vring.avail->idx); in vringh_get_head()
126 i = vrh->last_avail_idx & (vrh->vring.num - 1); in vringh_get_head()
128 err = get_user(*head, &vrh->vring.avail->ring[i]); in vringh_get_head()
188 vring_init(&vrh.vring, RINGSIZE, host_map, ALIGN); in parallel_test()
190 vrh.vring.desc, vrh.vring.avail, vrh.vring.used); in parallel_test()
492 vring_init(&vrh.vring, RINGSIZE, __user_addr_min, ALIGN); in main()
494 vrh.vring.desc, vrh.vring.avail, vrh.vring.used); in main()
650 assert(vrh.vring.used->idx % RINGSIZE != 0); in main()
665 struct vring vring; in main() local
685 vring_init(&vring, RINGSIZE, __user_addr_min, ALIGN); in main()
[all …]
Dvirtio_test.c34 struct vring vring; member
75 .desc_user_addr = (uint64_t)(unsigned long)info->vring.desc, in vhost_vq_setup()
76 .avail_user_addr = (uint64_t)(unsigned long)info->vring.avail, in vhost_vq_setup()
77 .used_user_addr = (uint64_t)(unsigned long)info->vring.used, in vhost_vq_setup()
82 state.num = info->vring.num; in vhost_vq_setup()
104 vring_init(&info->vring, num, info->ring, 4096); in vq_reset()
193 batch = (random() % vq->vring.num) + 1; in run_test()
236 vq_reset(vq, vq->vring.num, &dev->vdev); in run_test()
/Linux-v6.1/include/linux/
Dvringh.h3 * Linux host-side vring helpers; for when the kernel needs to access
4 * someone else's vring.
44 /* The vring (note: it may contain user pointers!) */
45 struct vring vring; member
47 /* IOTLB for this vring */
58 * struct vringh_config_ops - ops for creating a host vring from a virtio driver
63 * callbacks: array of driver callbacks, for each host vring
76 /* The memory the vring can access, and what offset to apply. */
Dremoteproc.h242 * struct fw_rsc_vdev_vring - vring descriptor entry
244 * @align: the alignment between the consumer and producer parts of the vring
245 * @num: num of buffers supported by this vring (must be power of two)
246 * @notifyid: a unique rproc-wide notify index for this vring. This notify
248 * vring is triggered.
255 * the remote processor is expecting the vring, or indicate that
256 * dynamically allocation of the vring's device address is supported.
280 * @vring: an array of @num_of_vrings entries of 'struct fw_rsc_vdev_vring'.
311 struct fw_rsc_vdev_vring vring[]; member
614 * struct rproc_vring - remoteproc vring state
[all …]
/Linux-v6.1/drivers/remoteproc/
Dremoteproc_virtio.c119 if (id >= ARRAY_SIZE(rvdev->vring)) in rp_find_vq()
131 rvring = &rvdev->vring[id]; in rp_find_vq()
135 /* zero vring */ in rp_find_vq()
139 dev_dbg(dev, "vring%d: va %pK qsz %d notifyid %d\n", in rp_find_vq()
159 /* Update vring in resource table */ in rp_find_vq()
161 rsc->vring[id].da = mem->da; in rp_find_vq()
299 cfg = &rsc->vring[rsc->num_of_vrings]; in rproc_virtio_get()
317 cfg = &rsc->vring[rsc->num_of_vrings]; in rproc_virtio_set()
440 /* Reference the vdev and vring allocations */ in rproc_add_virtio_dev()
539 /* allocate the vring resources */ in rproc_virtio_probe()
[all …]
Dremoteproc_core.c329 struct rproc_vring *rvring = &rvdev->vring[i]; in rproc_alloc_vring()
335 /* actual size of vring (in bytes) */ in rproc_alloc_vring()
344 if (rproc_check_carveout_da(rproc, mem, rsc->vring[i].da, size)) in rproc_alloc_vring()
349 size, rsc->vring[i].da, in rproc_alloc_vring()
363 * Assign an rproc-wide unique index for this vring in rproc_alloc_vring()
380 /* Let the rproc know the notifyid of this vring.*/ in rproc_alloc_vring()
381 rsc->vring[i].notifyid = notifyid; in rproc_alloc_vring()
390 struct fw_rsc_vdev_vring *vring = &rsc->vring[i]; in rproc_parse_vring() local
391 struct rproc_vring *rvring = &rvdev->vring[i]; in rproc_parse_vring()
393 dev_dbg(dev, "vdev rsc: vring%d: da 0x%x, qsz %d, align %d\n", in rproc_parse_vring()
[all …]
Dremoteproc_debugfs.c340 seq_printf(seq, " Vring %d\n", j); in rproc_rsc_table_show()
341 seq_printf(seq, " Device Address 0x%x\n", v->vring[j].da); in rproc_rsc_table_show()
342 seq_printf(seq, " Alignment %d\n", v->vring[j].align); in rproc_rsc_table_show()
343 seq_printf(seq, " Number of buffers %d\n", v->vring[j].num); in rproc_rsc_table_show()
344 seq_printf(seq, " Notify ID %d\n", v->vring[j].notifyid); in rproc_rsc_table_show()
346 v->vring[j].pa); in rproc_rsc_table_show()
Dingenic_rproc.c156 u32 vring; in vpu_interrupt() local
158 vring = readl(vpu->aux_base + REG_AUX_MSG); in vpu_interrupt()
163 return rproc_vq_interrupt(rproc, vring); in vpu_interrupt()
/Linux-v6.1/arch/arm/boot/dts/
Dkeystone-k2hk.dtsi167 interrupt-names = "vring", "exception";
183 interrupt-names = "vring", "exception";
199 interrupt-names = "vring", "exception";
215 interrupt-names = "vring", "exception";
231 interrupt-names = "vring", "exception";
247 interrupt-names = "vring", "exception";
263 interrupt-names = "vring", "exception";
279 interrupt-names = "vring", "exception";
/Linux-v6.1/include/uapi/linux/
Dvirtio_ring.h89 /* Alignment requirements for vring elements.
158 struct vring { struct
173 * struct vring argument
199 static inline void vring_init(struct vring *vr, unsigned int num, void *p, in vring_init()
/Linux-v6.1/tools/perf/pmu-events/arch/x86/ivytown/
Duncore-other.json434 "BriefDescription": "R2 AD Ring in Use; Counterclockwise and Even on VRing 0",
444 "BriefDescription": "R2 AD Ring in Use; Counterclockwise and Odd on VRing 0",
454 "BriefDescription": "R2 AD Ring in Use; Counterclockwise and Even on VRing 1",
464 "BriefDescription": "R2 AD Ring in Use; Counterclockwise and Odd on VRing 1",
484 "BriefDescription": "R2 AD Ring in Use; Clockwise and Even on VRing 0",
494 "BriefDescription": "R2 AD Ring in Use; Clockwise and Odd on VRing 0",
504 "BriefDescription": "R2 AD Ring in Use; Clockwise and Even on VRing 1",
514 "BriefDescription": "R2 AD Ring in Use; Clockwise and Odd on VRing 1",
534 "BriefDescription": "R2 AK Ring in Use; Counterclockwise and Even on VRing 0",
544 "BriefDescription": "R2 AK Ring in Use; Counterclockwise and Odd on VRing 0",
[all …]
Duncore-cache.json249 "BriefDescription": "AD Ring In Use; Down and Even on Vring 0",
259 "BriefDescription": "AD Ring In Use; Down and Odd on Vring 0",
269 "BriefDescription": "AD Ring In Use; Down and Even on VRing 1",
279 "BriefDescription": "AD Ring In Use; Down and Odd on VRing 1",
299 "BriefDescription": "AD Ring In Use; Up and Even on Vring 0",
309 "BriefDescription": "AD Ring In Use; Up and Odd on Vring 0",
319 "BriefDescription": "AD Ring In Use; Up and Even on VRing 1",
329 "BriefDescription": "AD Ring In Use; Up and Odd on VRing 1",
369 "BriefDescription": "AK Ring In Use; Down and Even on Vring 0",
379 "BriefDescription": "AK Ring In Use; Down and Odd on Vring 0",
[all …]
/Linux-v6.1/Documentation/devicetree/bindings/remoteproc/
Dti,keystone-rproc.txt63 "vring" - interrupt for virtio based IPC
139 interrupt-names = "vring", "exception";
178 interrupt-names = "vring", "exception";

123