Lines Matching +full:scatter +full:- +full:gather
1 /* SPDX-License-Identifier: GPL-2.0 */
5 * iommu_fill_pdir - Insert coalesced scatter/gather chunks into the I/O Pdir.
7 * @startsg: The scatter/gather list of coalesced chunks.
8 * @nents: The number of entries in the scatter/gather list.
11 * This function inserts the coalesced scatter/gather list chunks into the
28 dma_sg--; in iommu_fill_pdir()
30 while (nents-- > 0) { in iommu_fill_pdir()
36 sg_virt(startsg), startsg->length in iommu_fill_pdir()
57 sg_dma_address(dma_sg) = pide | ioc->ibase; in iommu_fill_pdir()
64 pdirp = &(ioc->pdir_base[pide >> IOVP_SHIFT]); in iommu_fill_pdir()
71 sg_dma_len(dma_sg) += startsg->length; in iommu_fill_pdir()
72 size = startsg->length + dma_offset; in iommu_fill_pdir()
75 ioc->msg_pages += startsg->length >> IOVP_SHIFT; in iommu_fill_pdir()
81 size -= IOVP_SIZE; in iommu_fill_pdir()
120 dma_len = startsg->length; in iommu_coalesce_chunks()
121 dma_offset = startsg->offset; in iommu_coalesce_chunks()
131 while(--nents > 0) { in iommu_coalesce_chunks()
135 startsg->length; in iommu_coalesce_chunks()
149 if (unlikely(ALIGN(dma_len + dma_offset + startsg->length, IOVP_SIZE) > in iommu_coalesce_chunks()
163 dma_len += startsg->length; in iommu_coalesce_chunks()