Lines Matching refs:dma_ofs
256 long npages, dma_ofs, i; in pci_map_single_1() local
304 dma_ofs = iommu_arena_alloc(dev, arena, npages, align); in pci_map_single_1()
305 if (dma_ofs < 0) { in pci_map_single_1()
313 arena->ptes[i + dma_ofs] = mk_iommu_pte(paddr); in pci_map_single_1()
315 ret = arena->dma_base + dma_ofs * PAGE_SIZE; in pci_map_single_1()
378 long dma_ofs, npages; in alpha_pci_unmap_page() local
403 dma_ofs = (dma_addr - arena->dma_base) >> PAGE_SHIFT; in alpha_pci_unmap_page()
404 if (dma_ofs * PAGE_SIZE >= arena->size) { in alpha_pci_unmap_page()
416 iommu_arena_free(arena, dma_ofs, npages); in alpha_pci_unmap_page()
421 if (dma_ofs >= arena->next_entry) in alpha_pci_unmap_page()
561 long npages, dma_ofs, i; in sg_fill() local
595 dma_ofs = iommu_arena_alloc(dev, arena, npages, 0); in sg_fill()
596 if (dma_ofs < 0) { in sg_fill()
607 out->dma_address = arena->dma_base + dma_ofs*PAGE_SIZE + paddr; in sg_fill()
615 ptes = &arena->ptes[dma_ofs]; in sg_fill()