Lines Matching defs:batch
293 static void qi_batch_flush_descs(struct intel_iommu *iommu, struct qi_batch *batch)
295 if (!iommu || !batch->index)
298 qi_submit_sync(iommu, batch->descs, batch->index, 0);
300 /* Reset the index value and clean the whole batch buffer. */
301 memset(batch, 0, sizeof(*batch));
304 static void qi_batch_increment_index(struct intel_iommu *iommu, struct qi_batch *batch)
306 if (++batch->index == QI_MAX_BATCHED_DESC_COUNT)
307 qi_batch_flush_descs(iommu, batch);
312 struct qi_batch *batch)
314 qi_desc_iotlb(iommu, did, addr, size_order, type, &batch->descs[batch->index]);
315 qi_batch_increment_index(iommu, batch);
320 struct qi_batch *batch)
329 qi_desc_dev_iotlb(sid, pfsid, qdep, addr, mask, &batch->descs[batch->index]);
330 qi_batch_increment_index(iommu, batch);
335 struct qi_batch *batch)
345 qi_desc_piotlb(did, pasid, addr, npages, ih, &batch->descs[batch->index]);
346 qi_batch_increment_index(iommu, batch);
351 unsigned int size_order, struct qi_batch *batch)
362 &batch->descs[batch->index]);
363 qi_batch_increment_index(iommu, batch);