| /linux/fs/notify/inotify/ |
| H A D | inotify.h | 55 static inline void dec_inotify_instances(struct ucounts *ucounts) in dec_inotify_instances() argument 57 dec_ucount(ucounts, UCOUNT_INOTIFY_INSTANCES); in dec_inotify_instances() 60 static inline struct ucounts *inc_inotify_watches(struct ucounts *ucounts) in inc_inotify_watches() argument 62 return inc_ucount(ucounts->ns, ucounts->uid, UCOUNT_INOTIFY_WATCHES); in inc_inotify_watches() 65 static inline void dec_inotify_watches(struct ucounts *ucounts) in dec_inotify_watches() argument 67 dec_ucount(ucounts, UCOUNT_INOTIFY_WATCHES); in dec_inotify_watches()
|
| H A D | inotify_fsnotify.c | 183 if (group->inotify_data.ucounts) in inotify_free_group_priv() 184 dec_inotify_instances(group->inotify_data.ucounts); in inotify_free_group_priv()
|
| H A D | inotify_user.c | 533 dec_inotify_watches(group->inotify_data.ucounts); in inotify_ignored_and_remove_idr() 600 if (!inc_inotify_watches(group->inotify_data.ucounts)) { in inotify_new_watch() 611 dec_inotify_watches(group->inotify_data.ucounts); in inotify_new_watch() 668 group->inotify_data.ucounts = inc_ucount(current_user_ns(), in inotify_new_group() 672 if (!group->inotify_data.ucounts) { in inotify_new_group()
|
| /linux/kernel/cgroup/ |
| H A D | namespace.c | 12 static struct ucounts *inc_cgroup_namespaces(struct user_namespace *ns) in inc_cgroup_namespaces() 17 static void dec_cgroup_namespaces(struct ucounts *ucounts) in dec_cgroup_namespaces() argument 19 dec_ucount(ucounts, UCOUNT_CGROUP_NAMESPACES); in dec_cgroup_namespaces() 40 dec_cgroup_namespaces(ns->ucounts); in free_cgroup_ns() 53 struct ucounts *ucounts; in copy_cgroup_ns() local 67 ucounts = inc_cgroup_namespaces(user_ns); in copy_cgroup_ns() 68 if (!ucounts) in copy_cgroup_ns() 80 dec_cgroup_namespaces(ucounts); in copy_cgroup_ns() 85 new_ns->ucounts = ucounts; in copy_cgroup_ns()
|
| /linux/kernel/ |
| H A D | utsname.c | 21 static struct ucounts *inc_uts_namespaces(struct user_namespace *ns) in inc_uts_namespaces() 26 static void dec_uts_namespaces(struct ucounts *ucounts) in dec_uts_namespaces() argument 28 dec_ucount(ucounts, UCOUNT_UTS_NAMESPACES); in dec_uts_namespaces() 40 struct ucounts *ucounts; in clone_uts_ns() local 44 ucounts = inc_uts_namespaces(user_ns); in clone_uts_ns() 45 if (!ucounts) in clone_uts_ns() 57 ns->ucounts = ucounts; in clone_uts_ns() 68 dec_uts_namespaces(ucounts); in clone_uts_ns() 99 dec_uts_namespaces(ns->ucounts); in free_uts_ns()
|
| H A D | user_namespace.c | 34 static struct ucounts *inc_user_namespaces(struct user_namespace *ns, kuid_t uid) in inc_user_namespaces() 39 static void dec_user_namespaces(struct ucounts *ucounts) in dec_user_namespaces() argument 41 return dec_ucount(ucounts, UCOUNT_USER_NAMESPACES); in dec_user_namespaces() 88 struct ucounts *ucounts; in create_user_ns() local 95 ucounts = inc_user_namespaces(parent_ns, owner); in create_user_ns() 96 if (!ucounts) in create_user_ns() 146 ns->ucounts = ucounts; in create_user_ns() 172 dec_user_namespaces(ucounts); in create_user_ns() 203 struct ucounts *ucounts = ns->ucounts; in free_user_ns() local 226 dec_user_namespaces(ucounts); in free_user_ns()
|
| H A D | signal.c | 384 static struct ucounts *sig_get_ucounts(struct task_struct *t, int sig, in sig_get_ucounts() 387 struct ucounts *ucounts; in sig_get_ucounts() local 399 ucounts = task_ucounts(t); in sig_get_ucounts() 400 sigpending = inc_rlimit_get_ucounts(ucounts, UCOUNT_RLIMIT_SIGPENDING, in sig_get_ucounts() 407 dec_rlimit_put_ucounts(ucounts, UCOUNT_RLIMIT_SIGPENDING); in sig_get_ucounts() 412 return ucounts; in sig_get_ucounts() 415 static void __sigqueue_init(struct sigqueue *q, struct ucounts *ucounts, in __sigqueue_init() argument 420 q->ucounts = ucounts; in __sigqueue_init() 431 struct ucounts *ucounts = sig_get_ucounts(t, sig, override_rlimit); in sigqueue_alloc() local 434 if (!ucounts) in sigqueue_alloc() [all …]
|
| /linux/ipc/ |
| H A D | namespace.c | 29 static struct ucounts *inc_ipc_namespaces(struct user_namespace *ns) in inc_ipc_namespaces() 34 static void dec_ipc_namespaces(struct ucounts *ucounts) in dec_ipc_namespaces() argument 36 dec_ucount(ucounts, UCOUNT_IPC_NAMESPACES); in dec_ipc_namespaces() 43 struct ucounts *ucounts; in create_ipc_ns() local 48 ucounts = inc_ipc_namespaces(user_ns); in create_ipc_ns() 49 if (!ucounts) { in create_ipc_ns() 71 ns->ucounts = ucounts; in create_ipc_ns() 106 dec_ipc_namespaces(ucounts); in create_ipc_ns() 164 dec_ipc_namespaces(ns->ucounts); in free_ipc_ns()
|
| /linux/include/linux/ |
| H A D | signal_types.h | 16 struct ucounts; 26 struct ucounts *ucounts; member
|
| H A D | cgroup_namespace.h | 10 struct ucounts *ucounts; member
|
| H A D | uts_namespace.h | 14 struct ucounts *ucounts; member
|
| H A D | ipc_namespace.h | 76 struct ucounts *ucounts; member
|
| H A D | shmem_fs.h | 112 extern int shmem_lock(struct file *file, int lock, struct ucounts *ucounts);
|
| /linux/mm/ |
| H A D | mlock.c | 804 int user_shm_lock(size_t size, struct ucounts *ucounts) in user_shm_lock() argument 815 memlock = inc_rlimit_ucounts(ucounts, UCOUNT_RLIMIT_MEMLOCK, locked); in user_shm_lock() 818 dec_rlimit_ucounts(ucounts, UCOUNT_RLIMIT_MEMLOCK, locked); in user_shm_lock() 821 if (!get_ucounts(ucounts)) { in user_shm_lock() 822 dec_rlimit_ucounts(ucounts, UCOUNT_RLIMIT_MEMLOCK, locked); in user_shm_lock() 832 void user_shm_unlock(size_t size, struct ucounts *ucounts) in user_shm_unlock() argument 835 dec_rlimit_ucounts(ucounts, UCOUNT_RLIMIT_MEMLOCK, (size + PAGE_SIZE - 1) >> PAGE_SHIFT); in user_shm_unlock() 837 put_ucounts(ucounts); in user_shm_unlock()
|
| H A D | shmem.c | 2895 int shmem_lock(struct file *file, int lock, struct ucounts *ucounts) in shmem_lock() 2907 if (!user_shm_lock(inode->i_size, ucounts)) in shmem_lock() 2912 if (!lock && (info->flags & SHMEM_F_LOCKED) && ucounts) { in shmem_lock() 2913 user_shm_unlock(inode->i_size, ucounts); in shmem_lock() 5761 int shmem_lock(struct file *file, int lock, struct ucounts *ucounts) in shmem_lock() 2892 shmem_lock(struct file * file,int lock,struct ucounts * ucounts) shmem_lock() argument 5758 shmem_lock(struct file * file,int lock,struct ucounts * ucounts) shmem_lock() argument
|
| /linux/fs/xfs/scrub/ |
| H A D | quotacheck.c | 235 if (!xqc->ucounts) in xqcheck_mod_live_ino_dqtrx() 332 counts = xqc->ucounts; in xqcheck_apply_live_dqtrx() 442 if (xqc->ucounts) { in xqcheck_collect_inode() 444 error = xqcheck_update_incore_counts(xqc, xqc->ucounts, id, 1, in xqcheck_collect_inode() 726 if (xqc->ucounts) { in xqcheck_teardown_scan() 727 xfarray_destroy(xqc->ucounts); in xqcheck_teardown_scan() 728 xqc->ucounts = NULL; in xqcheck_teardown_scan() 761 sizeof(struct xqcheck_dquot), &xqc->ucounts); in xqcheck_setup_scan() 841 if (xqc->ucounts) { in xchk_quotacheck()
|
| H A D | quotacheck.h | 41 struct xfarray *ucounts; member 65 return xqc->ucounts; in xqcheck_counters_for()
|
| /linux/net/core/ |
| H A D | net_namespace.c | 465 static struct ucounts *inc_net_namespaces(struct user_namespace *ns) in inc_net_namespaces() 470 static void dec_net_namespaces(struct ucounts *ucounts) in dec_net_namespaces() argument 472 dec_ucount(ucounts, UCOUNT_NET_NAMESPACES); in dec_net_namespaces() 553 struct ucounts *ucounts; in copy_net_ns() local 560 ucounts = inc_net_namespaces(user_ns); in copy_net_ns() 561 if (!ucounts) in copy_net_ns() 571 net->ucounts = ucounts; in copy_net_ns() 596 dec_net_namespaces(ucounts); in copy_net_ns() 721 dec_net_namespaces(net->ucounts); in cleanup_net()
|
| /linux/fs/ |
| H A D | binfmt_misc.c | 292 dec_ucount(interp->ucounts, UCOUNT_BINFMT_MISC_INTERPRETERS); in entry_put_interpreters() 320 struct ucounts *ucounts; in entry_attach_interpreter() local 328 ucounts = inc_ucount(current_user_ns(), current_euid(), in entry_attach_interpreter() 330 if (!ucounts) in entry_attach_interpreter() 337 dec_ucount(ucounts, UCOUNT_BINFMT_MISC_INTERPRETERS); in entry_attach_interpreter() 345 interp->ucounts = ucounts; in entry_attach_interpreter()
|
| H A D | namespace.c | 4328 static struct ucounts *inc_mnt_namespaces(struct user_namespace *ns) in copy_mnt_ns() 4333 static void dec_mnt_namespaces(struct ucounts *ucounts) in copy_mnt_ns() 4335 dec_ucount(ucounts, UCOUNT_MNT_NAMESPACES); in copy_mnt_ns() 4342 dec_mnt_namespaces(ns->ucounts); in mount_subtree() 4351 struct ucounts *ucounts; in mount_subtree() 4354 ucounts = inc_mnt_namespaces(user_ns); in mount_subtree() 4355 if (!ucounts) in mount_subtree() 4360 dec_mnt_namespaces(ucounts); in mount_subtree() 4189 dec_mnt_namespaces(struct ucounts * ucounts) dec_mnt_namespaces() argument 4205 struct ucounts *ucounts; alloc_mnt_ns() local [all...] |
| /linux/fs/notify/fanotify/ |
| H A D | fanotify_user.c | 1406 struct ucounts *ucounts = group->fanotify_data.ucounts; in fanotify_add_new_mark() local 1418 !inc_ucount(ucounts->ns, ucounts->uid, UCOUNT_FANOTIFY_MARKS)) in fanotify_add_new_mark() 1451 dec_ucount(ucounts, UCOUNT_FANOTIFY_MARKS); in fanotify_add_new_mark() 1679 group->fanotify_data.ucounts = inc_ucount(user_ns, current_euid(), in SYSCALL_DEFINE2() 1681 if (!group->fanotify_data.ucounts) in SYSCALL_DEFINE2()
|
| H A D | fanotify.c | 1022 if (group->fanotify_data.ucounts) in fanotify_free_group_priv() 1023 dec_ucount(group->fanotify_data.ucounts, in fanotify_free_group_priv() 1107 dec_ucount(group->fanotify_data.ucounts, UCOUNT_FANOTIFY_MARKS); in fanotify_freeing_mark()
|
| /linux/include/net/ |
| H A D | net_namespace.h | 94 struct ucounts *ucounts; member
|
| /linux/security/keys/ |
| H A D | process_keys.c | 922 if (unlikely(!get_ucounts(old->ucounts))) { in key_change_session_keyring() 937 new->ucounts = old->ucounts; in key_change_session_keyring()
|
| /linux/init/ |
| H A D | init_task.c | 98 .ucounts = &init_ucounts,
|