Home
last modified time | relevance | path

Searched refs:umem_odp (Results 1 – 3 of 3) sorted by relevance

/drivers/infiniband/core/
Dumem_odp.c52 static inline int ib_init_umem_odp(struct ib_umem_odp *umem_odp, in ib_init_umem_odp() argument
57 umem_odp->umem.is_odp = 1; in ib_init_umem_odp()
58 mutex_init(&umem_odp->umem_mutex); in ib_init_umem_odp()
60 if (!umem_odp->is_implicit_odp) { in ib_init_umem_odp()
61 size_t page_size = 1UL << umem_odp->page_shift; in ib_init_umem_odp()
66 start = ALIGN_DOWN(umem_odp->umem.address, page_size); in ib_init_umem_odp()
67 if (check_add_overflow(umem_odp->umem.address, in ib_init_umem_odp()
68 (unsigned long)umem_odp->umem.length, in ib_init_umem_odp()
75 ndmas = (end - start) >> umem_odp->page_shift; in ib_init_umem_odp()
80 umem_odp->pfn_list = kvcalloc( in ib_init_umem_odp()
[all …]
DMakefile44 ib_uverbs-$(CONFIG_INFINIBAND_ON_DEMAND_PAGING) += umem_odp.o
/drivers/infiniband/hw/mlx5/
Dodp.c230 struct ib_umem_odp *umem_odp = in mlx5_ib_invalidate_range() local
245 mutex_lock(&umem_odp->umem_mutex); in mlx5_ib_invalidate_range()
251 if (!umem_odp->npages) in mlx5_ib_invalidate_range()
253 mr = umem_odp->private; in mlx5_ib_invalidate_range()
255 start = max_t(u64, ib_umem_start(umem_odp), range->start); in mlx5_ib_invalidate_range()
256 end = min_t(u64, ib_umem_end(umem_odp), range->end); in mlx5_ib_invalidate_range()
264 for (addr = start; addr < end; addr += BIT(umem_odp->page_shift)) { in mlx5_ib_invalidate_range()
265 idx = (addr - ib_umem_start(umem_odp)) >> umem_odp->page_shift; in mlx5_ib_invalidate_range()
272 if (umem_odp->dma_list[idx] & in mlx5_ib_invalidate_range()
307 ib_umem_odp_unmap_dma_pages(umem_odp, start, end); in mlx5_ib_invalidate_range()
[all …]