Home
last modified time | relevance | path

Searched refs:locked_vm (Results 1 – 19 of 19) sorted by relevance

/Linux-v5.10/mm/
Dutil.c438 unsigned long locked_vm, limit; in __account_locked_vm() local
443 locked_vm = mm->locked_vm; in __account_locked_vm()
447 if (locked_vm + pages > limit) in __account_locked_vm()
451 mm->locked_vm = locked_vm + pages; in __account_locked_vm()
453 WARN_ON_ONCE(pages > locked_vm); in __account_locked_vm()
454 mm->locked_vm = locked_vm - pages; in __account_locked_vm()
459 locked_vm << PAGE_SHIFT, task_rlimit(task, RLIMIT_MEMLOCK), in __account_locked_vm()
Dmremap.c458 mm->locked_vm += new_len >> PAGE_SHIFT; in move_vma()
523 locked = mm->locked_vm << PAGE_SHIFT; in vma_to_resize()
768 mm->locked_vm += pages; in SYSCALL_DEFINE5()
Dmmap.c1360 locked += mm->locked_vm; in mlock_future_check()
1880 mm->locked_vm += (len >> PAGE_SHIFT); in mmap_region()
2376 locked = mm->locked_vm + grow; in acct_stack_growth()
2469 mm->locked_vm += grow; in expand_upwards()
2549 mm->locked_vm += grow; in expand_downwards()
2889 if (mm->locked_vm) { in __do_munmap()
2893 mm->locked_vm -= vma_pages(tmp); in __do_munmap()
3128 mm->locked_vm += (len >> PAGE_SHIFT); in do_brk_flags()
3200 if (mm->locked_vm) { in exit_mmap()
Ddebug.c254 mm->hiwater_rss, mm->hiwater_vm, mm->total_vm, mm->locked_vm, in dump_mm()
Dmlock.c570 mm->locked_vm += nr_pages; in mlock_fixup()
697 locked += current->mm->locked_vm; in do_mlock()
/Linux-v5.10/net/xdp/
Dxdp_umem.c37 atomic_long_sub(umem->npgs, &umem->user->locked_vm); in xdp_umem_unaccount_pages()
142 old_npgs = atomic_long_read(&umem->user->locked_vm); in xdp_umem_account_pages()
149 } while (atomic_long_cmpxchg(&umem->user->locked_vm, old_npgs, in xdp_umem_account_pages()
/Linux-v5.10/tools/testing/selftests/bpf/progs/
Dbpf_iter_bpf_map.c26 map->memory.user->locked_vm.counter); in dump_bpf_map()
/Linux-v5.10/include/linux/sched/
Duser.h37 atomic_long_t locked_vm; member
/Linux-v5.10/include/linux/
Dmm_types.h470 unsigned long locked_vm; /* Pages that have PG_mlocked set */ member
/Linux-v5.10/kernel/bpf/
Dsyscall.c348 if (atomic_long_add_return(pages, &user->locked_vm) > memlock_limit) { in bpf_charge_memlock()
349 atomic_long_sub(pages, &user->locked_vm); in bpf_charge_memlock()
358 atomic_long_sub(pages, &user->locked_vm); in bpf_uncharge_memlock()
1637 user_bufs = atomic_long_add_return(pages, &user->locked_vm); in __bpf_prog_charge()
1639 atomic_long_sub(pages, &user->locked_vm); in __bpf_prog_charge()
1650 atomic_long_sub(pages, &user->locked_vm); in __bpf_prog_uncharge()
/Linux-v5.10/Documentation/vm/
Dunevictable-lru.rst362 VMAs against the task's "locked_vm".
491 to be mlocked to the task's "locked_vm". To account for filtered VMAs,
493 callers then subtract a non-negative return value from the task's locked_vm. A
496 memory range accounted as locked_vm, as the protections could be changed later
/Linux-v5.10/drivers/infiniband/sw/siw/
Dsiw_verbs.c1302 if (num_pages > mem_limit - current->mm->locked_vm) { in siw_reg_user_mr()
1305 current->mm->locked_vm); in siw_reg_user_mr()
/Linux-v5.10/drivers/vfio/
Dvfio_iommu_type1.c512 if (!dma->lock_cap && current->mm->locked_vm + 1 > limit) { in vfio_pin_pages_remote()
539 current->mm->locked_vm + lock_acct + 1 > limit) { in vfio_pin_pages_remote()
/Linux-v5.10/net/core/
Dskbuff.c1062 old_pg = atomic_long_read(&user->locked_vm); in mm_account_pinned_pages()
1066 } while (atomic_long_cmpxchg(&user->locked_vm, old_pg, new_pg) != in mm_account_pinned_pages()
1083 atomic_long_sub(mmp->num_pg, &mmp->user->locked_vm); in mm_unaccount_pinned_pages()
/Linux-v5.10/Documentation/driver-api/
Dvfio.rst457 mm::locked_vm counter to make sure we do not exceed the rlimit.
/Linux-v5.10/fs/proc/
Dtask_mmu.c61 SEQ_PUT_DEC(" kB\nVmLck:\t", mm->locked_vm); in task_mem()
/Linux-v5.10/fs/
Dio_uring.c7860 atomic_long_sub(nr_pages, &user->locked_vm); in __io_unaccount_mem()
7872 cur_pages = atomic_long_read(&user->locked_vm); in __io_account_mem()
7876 } while (atomic_long_cmpxchg(&user->locked_vm, cur_pages, in __io_account_mem()
7890 ctx->mm_account->locked_vm -= nr_pages; in io_unaccount_mem()
7909 ctx->mm_account->locked_vm += nr_pages; in io_account_mem()
/Linux-v5.10/kernel/
Dfork.c1015 mm->locked_vm = 0; in mm_init()
/Linux-v5.10/kernel/events/
Dcore.c5917 atomic_long_sub(rb->aux_nr_pages - rb->aux_mmap_locked, &mmap_user->locked_vm); in perf_mmap_close()
5992 &mmap_user->locked_vm); in perf_mmap_close()
6138 user_locked = atomic_long_read(&user->locked_vm); in perf_mmap()
6199 atomic_long_add(user_extra, &user->locked_vm); in perf_mmap()