/Linux-v5.4/arch/xtensa/mm/ |
D | mmu.c | 22 static void * __init init_pmd(unsigned long vaddr, unsigned long n_pages) in init_pmd() argument 29 n_pages = ALIGN(n_pages, PTRS_PER_PTE); in init_pmd() 32 __func__, vaddr, n_pages); in init_pmd() 34 pte = memblock_alloc_low(n_pages * sizeof(pte_t), PAGE_SIZE); in init_pmd() 37 __func__, n_pages * sizeof(pte_t), PAGE_SIZE); in init_pmd() 39 for (i = 0; i < n_pages; ++i) in init_pmd() 42 for (i = 0; i < n_pages; i += PTRS_PER_PTE, ++pmd) { in init_pmd()
|
D | kasan_init.c | 40 unsigned long n_pages = (end - start) / PAGE_SIZE; in populate() local 41 unsigned long n_pmds = n_pages / PTRS_PER_PTE; in populate() 46 pte_t *pte = memblock_alloc(n_pages * sizeof(pte_t), PAGE_SIZE); in populate() 50 __func__, n_pages * sizeof(pte_t), PAGE_SIZE); in populate()
|
/Linux-v5.4/mm/ |
D | balloon_compaction.c | 45 size_t n_pages = 0; in balloon_page_list_enqueue() local 51 n_pages++; in balloon_page_list_enqueue() 54 return n_pages; in balloon_page_list_enqueue() 81 size_t n_pages = 0; in balloon_page_list_dequeue() local 85 if (n_pages == n_req_pages) in balloon_page_list_dequeue() 106 n_pages++; in balloon_page_list_dequeue() 110 return n_pages; in balloon_page_list_dequeue() 181 int n_pages; in balloon_page_dequeue() local 183 n_pages = balloon_page_list_dequeue(b_dev_info, &pages, 1); in balloon_page_dequeue() 185 if (n_pages != 1) { in balloon_page_dequeue()
|
/Linux-v5.4/drivers/staging/comedi/ |
D | comedi_buf.c | 37 PAGE_SIZE * bm->n_pages, in comedi_buf_map_kref_release() 40 for (i = 0; i < bm->n_pages; i++) { in comedi_buf_map_kref_release() 76 unsigned int n_pages) in comedi_buf_map_alloc() argument 93 bm->page_list = vzalloc(sizeof(*buf) * n_pages); in comedi_buf_map_alloc() 106 PAGE_SIZE * n_pages, &dma_addr, in comedi_buf_map_alloc() 111 for (i = 0; i < n_pages; i++) { in comedi_buf_map_alloc() 117 bm->n_pages = i; in comedi_buf_map_alloc() 119 for (i = 0; i < n_pages; i++) { in comedi_buf_map_alloc() 128 bm->n_pages = i; in comedi_buf_map_alloc() 129 if (i < n_pages) in comedi_buf_map_alloc() [all …]
|
D | comedi_fops.c | 2307 int n_pages; in comedi_mmap() local 2357 n_pages = vma_pages(vma); in comedi_mmap() 2361 if (!bm || n_pages > bm->n_pages) { in comedi_mmap() 2372 buf->dma_addr, n_pages * PAGE_SIZE); in comedi_mmap() 2374 for (i = 0; i < n_pages; ++i) { in comedi_mmap()
|
/Linux-v5.4/drivers/misc/ |
D | vmw_balloon.c | 245 unsigned int n_pages; member 705 ctl->n_pages = i; in vmballoon_alloc_page_list() 707 return req_n_pages == ctl->n_pages ? 0 : -ENOMEM; in vmballoon_alloc_page_list() 865 num_pages = ctl->n_pages; in vmballoon_lock() 876 batch_status = vmballoon_lock_op(b, ctl->n_pages, ctl->page_size, in vmballoon_lock() 906 ctl->n_pages--; in vmballoon_lock() 925 int *n_pages, in vmballoon_release_page_list() argument 935 if (n_pages) in vmballoon_release_page_list() 936 *n_pages = 0; in vmballoon_release_page_list() 1002 unsigned int *n_pages, in vmballoon_enqueue_page_list() argument [all …]
|
/Linux-v5.4/drivers/xen/ |
D | privcmd-buf.c | 33 unsigned int n_pages; member 59 for (i = 0; i < vma_priv->n_pages; i++) in privcmd_buf_vmapriv_free() 151 vma_priv->n_pages++; in privcmd_buf_mmap() 165 if (vma_priv->n_pages != count) in privcmd_buf_mmap() 169 vma_priv->n_pages); in privcmd_buf_mmap()
|
D | balloon.c | 534 long n_pages; in balloon_process() local 536 n_pages = min(-credit, si_mem_available()); in balloon_process() 537 state = decrease_reservation(n_pages, GFP_BALLOON); in balloon_process() 538 if (state == BP_DONE && n_pages != -credit && in balloon_process() 539 n_pages < totalreserve_pages) in balloon_process()
|
/Linux-v5.4/drivers/media/common/videobuf2/ |
D | videobuf2-vmalloc.c | 80 int n_pages, offset, i; in vb2_vmalloc_get_userptr() local 96 n_pages = frame_vector_count(vec); in vb2_vmalloc_get_userptr() 104 for (i = 1; i < n_pages; i++) in vb2_vmalloc_get_userptr() 110 buf->vaddr = vm_map_ram(frame_vector_pages(vec), n_pages, -1, in vb2_vmalloc_get_userptr() 133 unsigned int n_pages; in vb2_vmalloc_put_userptr() local 136 n_pages = frame_vector_count(buf->vec); in vb2_vmalloc_put_userptr() 139 vm_unmap_ram((void *)vaddr, n_pages); in vb2_vmalloc_put_userptr() 142 for (i = 0; i < n_pages; i++) in vb2_vmalloc_put_userptr()
|
D | videobuf2-dma-contig.c | 459 int n_pages, i; in vb2_dc_get_userptr() local 493 n_pages = frame_vector_count(vec); in vb2_dc_get_userptr() 502 for (i = 1; i < n_pages; i++) in vb2_dc_get_userptr() 521 ret = sg_alloc_table_from_pages(sgt, frame_vector_pages(vec), n_pages, in vb2_dc_get_userptr()
|
/Linux-v5.4/arch/ia64/include/asm/ |
D | uncached.h | 8 extern unsigned long uncached_alloc_page(int starting_nid, int n_pages); 9 extern void uncached_free_page(unsigned long uc_addr, int n_pages);
|
/Linux-v5.4/arch/ia64/kernel/ |
D | uncached.c | 179 unsigned long uncached_alloc_page(int starting_nid, int n_pages) in uncached_alloc_page() argument 200 n_pages * PAGE_SIZE); in uncached_alloc_page() 220 void uncached_free_page(unsigned long uc_addr, int n_pages) in uncached_free_page() argument 231 gen_pool_free(pool, uc_addr, n_pages * PAGE_SIZE); in uncached_free_page()
|
/Linux-v5.4/arch/arc/include/asm/ |
D | arcregs.h | 126 #define PAGES_TO_KB(n_pages) ((n_pages) << (PAGE_SHIFT - 10)) argument 127 #define PAGES_TO_MB(n_pages) (PAGES_TO_KB(n_pages) >> 10) argument
|
/Linux-v5.4/arch/sh/mm/ |
D | cache-sh5.c | 149 int n_pages; in sh64_icache_inv_user_page_range() local 154 n_pages = ((end - start) >> PAGE_SHIFT); in sh64_icache_inv_user_page_range() 155 if (n_pages >= 64) { in sh64_icache_inv_user_page_range() 470 int n_pages = ((end - start) >> PAGE_SHIFT); in sh64_dcache_purge_user_range() local 472 if (n_pages >= 64 || ((start ^ (end - 1)) & PMD_MASK)) { in sh64_dcache_purge_user_range()
|
/Linux-v5.4/drivers/gpu/drm/i915/gem/ |
D | i915_gem_pages.c | 230 unsigned long n_pages = obj->base.size >> PAGE_SHIFT; in i915_gem_object_map() local 241 if (n_pages == 1 && type == I915_MAP_WB) in i915_gem_object_map() 244 if (n_pages > ARRAY_SIZE(stack_pages)) { in i915_gem_object_map() 246 pages = kvmalloc_array(n_pages, sizeof(*pages), GFP_KERNEL); in i915_gem_object_map() 255 GEM_BUG_ON(i != n_pages); in i915_gem_object_map() 268 addr = vmap(pages, n_pages, 0, pgprot); in i915_gem_object_map()
|
/Linux-v5.4/include/linux/ |
D | fscache-cache.h | 151 atomic_t n_pages; /* number of pages to be retrieved */ member 193 int n_pages) in fscache_retrieval_complete() argument 195 if (atomic_sub_return_relaxed(n_pages, &op->n_pages) <= 0) in fscache_retrieval_complete()
|
D | scatterlist.h | 276 unsigned int n_pages, unsigned int offset, 280 unsigned int n_pages, unsigned int offset,
|
/Linux-v5.4/kernel/trace/ |
D | tracing_map.c | 293 for (i = 0; i < a->n_pages; i++) in tracing_map_array_clear() 307 for (i = 0; i < a->n_pages; i++) { in tracing_map_array_free() 331 a->n_pages = n_elts / a->entries_per_page; in tracing_map_array_alloc() 332 if (!a->n_pages) in tracing_map_array_alloc() 333 a->n_pages = 1; in tracing_map_array_alloc() 337 a->pages = kcalloc(a->n_pages, sizeof(void *), GFP_KERNEL); in tracing_map_array_alloc() 341 for (i = 0; i < a->n_pages; i++) { in tracing_map_array_alloc()
|
D | tracing_map.h | 169 unsigned int n_pages; member
|
/Linux-v5.4/drivers/gpu/drm/vgem/ |
D | vgem_drv.c | 320 long n_pages = obj->size >> PAGE_SHIFT; in vgem_prime_pin() local 330 drm_clflush_pages(pages, n_pages); in vgem_prime_pin() 385 long n_pages = obj->size >> PAGE_SHIFT; in vgem_prime_vmap() local 392 return vmap(pages, n_pages, 0, pgprot_writecombine(PAGE_KERNEL)); in vgem_prime_vmap()
|
/Linux-v5.4/lib/ |
D | scatterlist.c | 390 unsigned int n_pages, unsigned int offset, in __sg_alloc_table_from_pages() argument 404 for (i = 1; i < n_pages; i++) { in __sg_alloc_table_from_pages() 424 for (j = cur_page + 1; j < n_pages; j++) { in __sg_alloc_table_from_pages() 465 unsigned int n_pages, unsigned int offset, in sg_alloc_table_from_pages() argument 468 return __sg_alloc_table_from_pages(sgt, pages, n_pages, offset, size, in sg_alloc_table_from_pages()
|
/Linux-v5.4/kernel/ |
D | relay.c | 71 static struct page **relay_alloc_page_array(unsigned int n_pages) in relay_alloc_page_array() argument 73 const size_t pa_size = n_pages * sizeof(struct page *); in relay_alloc_page_array() 126 unsigned int i, j, n_pages; in relay_alloc_buf() local 129 n_pages = *size >> PAGE_SHIFT; in relay_alloc_buf() 131 buf->page_array = relay_alloc_page_array(n_pages); in relay_alloc_buf() 135 for (i = 0; i < n_pages; i++) { in relay_alloc_buf() 141 mem = vmap(buf->page_array, n_pages, VM_MAP, PAGE_KERNEL); in relay_alloc_buf() 146 buf->page_count = n_pages; in relay_alloc_buf()
|
/Linux-v5.4/drivers/gpu/drm/vkms/ |
D | vkms_gem.c | 197 unsigned int n_pages = obj->size >> PAGE_SHIFT; in vkms_gem_vmap() local 205 vkms_obj->vaddr = vmap(pages, n_pages, VM_MAP, PAGE_KERNEL); in vkms_gem_vmap()
|
/Linux-v5.4/drivers/net/ethernet/sfc/ |
D | mcdi_mon.c | 309 unsigned int n_pages, n_sensors, n_attrs, page; in efx_mcdi_mon_probe() local 332 n_pages = page; in efx_mcdi_mon_probe() 378 if (page == n_pages) in efx_mcdi_mon_probe()
|
/Linux-v5.4/fs/fscache/ |
D | page.c | 276 atomic_set(&op->n_pages, 0); in fscache_do_cancel_retrieval() 290 atomic_read(&op->n_pages), ==, 0); in fscache_release_retrieval_op() 464 atomic_set(&op->n_pages, 1); in __fscache_read_or_alloc_page() 593 atomic_set(&op->n_pages, *nr_pages); in __fscache_read_or_alloc_pages() 705 atomic_set(&op->n_pages, 1); in __fscache_alloc_page()
|