Lines Matching refs:strbuf
270 struct strbuf *strbuf; in dma_4u_map_page() local
278 strbuf = dev->archdata.stc; in dma_4u_map_page()
301 if (strbuf->strbuf_enabled) in dma_4u_map_page()
321 static void strbuf_flush(struct strbuf *strbuf, struct iommu *iommu, in strbuf_flush() argument
327 if (strbuf->strbuf_ctxflush && in strbuf_flush()
332 flushreg = strbuf->strbuf_ctxflush; in strbuf_flush()
333 matchreg = STC_CTXMATCH_ADDR(strbuf, ctx); in strbuf_flush()
358 iommu_write(strbuf->strbuf_pflush, vaddr); in strbuf_flush()
369 STC_FLUSHFLAG_INIT(strbuf); in strbuf_flush()
370 iommu_write(strbuf->strbuf_fsync, strbuf->strbuf_flushflag_pa); in strbuf_flush()
374 while (!STC_FLUSHFLAG_SET(strbuf)) { in strbuf_flush()
392 struct strbuf *strbuf; in dma_4u_unmap_page() local
403 strbuf = dev->archdata.stc; in dma_4u_unmap_page()
419 if (strbuf->strbuf_enabled && !(attrs & DMA_ATTR_SKIP_CPU_SYNC)) in dma_4u_unmap_page()
420 strbuf_flush(strbuf, iommu, bus_addr, ctx, in dma_4u_unmap_page()
443 struct strbuf *strbuf; in dma_4u_map_sg() local
450 strbuf = dev->archdata.stc; in dma_4u_map_sg()
460 if (strbuf->strbuf_enabled) in dma_4u_map_sg()
615 struct strbuf *strbuf; in dma_4u_unmap_sg() local
621 strbuf = dev->archdata.stc; in dma_4u_unmap_sg()
644 if (strbuf->strbuf_enabled && !(attrs & DMA_ATTR_SKIP_CPU_SYNC)) in dma_4u_unmap_sg()
645 strbuf_flush(strbuf, iommu, dma_handle, ctx, in dma_4u_unmap_sg()
666 struct strbuf *strbuf; in dma_4u_sync_single_for_cpu() local
670 strbuf = dev->archdata.stc; in dma_4u_sync_single_for_cpu()
672 if (!strbuf->strbuf_enabled) in dma_4u_sync_single_for_cpu()
684 strbuf->strbuf_ctxflush) { in dma_4u_sync_single_for_cpu()
694 strbuf_flush(strbuf, iommu, bus_addr, ctx, npages, direction); in dma_4u_sync_single_for_cpu()
704 struct strbuf *strbuf; in dma_4u_sync_sg_for_cpu() local
710 strbuf = dev->archdata.stc; in dma_4u_sync_sg_for_cpu()
712 if (!strbuf->strbuf_enabled) in dma_4u_sync_sg_for_cpu()
720 strbuf->strbuf_ctxflush) { in dma_4u_sync_sg_for_cpu()
740 strbuf_flush(strbuf, iommu, bus_addr, ctx, npages, direction); in dma_4u_sync_sg_for_cpu()