Lines Matching refs:p
71 struct task_struct *p, *g; in SYSCALL_DEFINE3() local
86 p = current; in SYSCALL_DEFINE3()
88 p = find_task_by_vpid(who); in SYSCALL_DEFINE3()
89 if (p) in SYSCALL_DEFINE3()
90 ret = set_task_ioprio(p, ioprio); in SYSCALL_DEFINE3()
99 do_each_pid_thread(pgrp, PIDTYPE_PGID, p) { in SYSCALL_DEFINE3()
100 ret = set_task_ioprio(p, ioprio); in SYSCALL_DEFINE3()
105 } while_each_pid_thread(pgrp, PIDTYPE_PGID, p); in SYSCALL_DEFINE3()
121 for_each_process_thread(g, p) { in SYSCALL_DEFINE3()
122 if (!uid_eq(task_uid(p), uid) || in SYSCALL_DEFINE3()
123 !task_pid_vnr(p)) in SYSCALL_DEFINE3()
125 ret = set_task_ioprio(p, ioprio); in SYSCALL_DEFINE3()
149 int __get_task_ioprio(struct task_struct *p) in __get_task_ioprio() argument
151 struct io_context *ioc = p->io_context; in __get_task_ioprio()
154 if (p != current) in __get_task_ioprio()
155 lockdep_assert_held(&p->alloc_lock); in __get_task_ioprio()
162 prio = IOPRIO_PRIO_VALUE(task_nice_ioclass(p), in __get_task_ioprio()
163 task_nice_ioprio(p)); in __get_task_ioprio()
168 static int get_task_ioprio(struct task_struct *p) in get_task_ioprio() argument
172 ret = security_task_getioprio(p); in get_task_ioprio()
175 task_lock(p); in get_task_ioprio()
176 ret = __get_task_ioprio(p); in get_task_ioprio()
177 task_unlock(p); in get_task_ioprio()
188 static int get_task_raw_ioprio(struct task_struct *p) in get_task_raw_ioprio() argument
192 ret = security_task_getioprio(p); in get_task_raw_ioprio()
195 task_lock(p); in get_task_raw_ioprio()
196 if (p->io_context) in get_task_raw_ioprio()
197 ret = p->io_context->ioprio; in get_task_raw_ioprio()
200 task_unlock(p); in get_task_raw_ioprio()
212 struct task_struct *g, *p; in SYSCALL_DEFINE2() local
223 p = current; in SYSCALL_DEFINE2()
225 p = find_task_by_vpid(who); in SYSCALL_DEFINE2()
226 if (p) in SYSCALL_DEFINE2()
227 ret = get_task_raw_ioprio(p); in SYSCALL_DEFINE2()
235 do_each_pid_thread(pgrp, PIDTYPE_PGID, p) { in SYSCALL_DEFINE2()
236 tmpio = get_task_ioprio(p); in SYSCALL_DEFINE2()
243 } while_each_pid_thread(pgrp, PIDTYPE_PGID, p); in SYSCALL_DEFINE2()
257 for_each_process_thread(g, p) { in SYSCALL_DEFINE2()
258 if (!uid_eq(task_uid(p), user->uid) || in SYSCALL_DEFINE2()
259 !task_pid_vnr(p)) in SYSCALL_DEFINE2()
261 tmpio = get_task_ioprio(p); in SYSCALL_DEFINE2()