Lines Matching refs:npages
57 for_each_sg(umem->sg_head.sgl, sg, umem->npages, i) { in __ib_umem_release()
91 unsigned long npages; in ib_umem_get() local
166 npages = ib_umem_num_pages(umem); in ib_umem_get()
170 locked = npages + current->mm->pinned_vm; in ib_umem_get()
180 if (npages == 0 || npages > UINT_MAX) { in ib_umem_get()
185 ret = sg_alloc_table(&umem->sg_head, npages, GFP_KERNEL); in ib_umem_get()
195 while (npages) { in ib_umem_get()
197 min_t(unsigned long, npages, in ib_umem_get()
204 umem->npages += ret; in ib_umem_get()
206 npages -= ret; in ib_umem_get()
221 umem->npages, in ib_umem_get()
360 ret = sg_pcopy_to_buffer(umem->sg_head.sgl, umem->npages, dst, length, in ib_umem_copy_from()