• Home
  • Raw
  • Download

Lines Matching refs:p

194 static u64 cpu_clock_sample(const clockid_t clkid, struct task_struct *p)  in cpu_clock_sample()  argument
199 return task_sched_runtime(p); in cpu_clock_sample()
201 task_cputime(p, &utime, &stime); in cpu_clock_sample()
221 static void task_sample_cputime(struct task_struct *p, u64 *samples) in task_sample_cputime() argument
225 task_cputime(p, &utime, &stime); in task_sample_cputime()
226 store_samples(samples, stime, utime, p->se.sum_exec_runtime); in task_sample_cputime()
340 static u64 cpu_clock_sample_group(const clockid_t clkid, struct task_struct *p, in cpu_clock_sample_group() argument
343 struct thread_group_cputimer *cputimer = &p->signal->cputimer; in cpu_clock_sample_group()
344 struct posix_cputimers *pct = &p->signal->posix_cputimers; in cpu_clock_sample_group()
349 thread_group_start_cputime(p, samples); in cpu_clock_sample_group()
351 __thread_group_cputime(p, samples); in cpu_clock_sample_group()
452 static void disarm_timer(struct k_itimer *timer, struct task_struct *p) in disarm_timer() argument
460 base = timer_base(timer, p); in disarm_timer()
462 trigger_base_recalc_expires(timer, p); in disarm_timer()
476 struct task_struct *p; in posix_cpu_timer_del() local
481 p = cpu_timer_task_rcu(timer); in posix_cpu_timer_del()
482 if (!p) in posix_cpu_timer_del()
489 sighand = lock_task_sighand(p, &flags); in posix_cpu_timer_del()
500 disarm_timer(timer, p); in posix_cpu_timer_del()
502 unlock_task_sighand(p, &flags); in posix_cpu_timer_del()
557 static void arm_timer(struct k_itimer *timer, struct task_struct *p) in arm_timer() argument
559 struct posix_cputimer_base *base = timer_base(timer, p); in arm_timer()
576 tick_dep_set_task(p, TICK_DEP_BIT_POSIX_TIMER); in arm_timer()
578 tick_dep_set_signal(p, TICK_DEP_BIT_POSIX_TIMER); in arm_timer()
631 struct task_struct *p; in posix_cpu_timer_set() local
636 p = cpu_timer_task_rcu(timer); in posix_cpu_timer_set()
637 if (!p) { in posix_cpu_timer_set()
656 sighand = lock_task_sighand(p, &flags); in posix_cpu_timer_set()
688 val = cpu_clock_sample(clkid, p); in posix_cpu_timer_set()
690 val = cpu_clock_sample_group(clkid, p, true); in posix_cpu_timer_set()
723 unlock_task_sighand(p, &flags); in posix_cpu_timer_set()
738 arm_timer(timer, p); in posix_cpu_timer_set()
741 unlock_task_sighand(p, &flags); in posix_cpu_timer_set()
772 sighand = lock_task_sighand(p, &flags); in posix_cpu_timer_set()
777 trigger_base_recalc_expires(timer, p); in posix_cpu_timer_set()
779 unlock_task_sighand(p, &flags); in posix_cpu_timer_set()
794 struct task_struct *p; in posix_cpu_timer_get() local
797 p = cpu_timer_task_rcu(timer); in posix_cpu_timer_get()
798 if (!p) in posix_cpu_timer_get()
813 now = cpu_clock_sample(clkid, p); in posix_cpu_timer_get()
815 now = cpu_clock_sample_group(clkid, p, false); in posix_cpu_timer_get()
1051 struct task_struct *p; in posix_cpu_timer_rearm() local
1057 p = cpu_timer_task_rcu(timer); in posix_cpu_timer_rearm()
1058 if (!p) in posix_cpu_timer_rearm()
1062 sighand = lock_task_sighand(p, &flags); in posix_cpu_timer_rearm()
1070 now = cpu_clock_sample(clkid, p); in posix_cpu_timer_rearm()
1072 now = cpu_clock_sample_group(clkid, p, true); in posix_cpu_timer_rearm()
1079 arm_timer(timer, p); in posix_cpu_timer_rearm()
1080 unlock_task_sighand(p, &flags); in posix_cpu_timer_rearm()
1215 void clear_posix_cputimers_work(struct task_struct *p) in clear_posix_cputimers_work() argument
1221 memset(&p->posix_cputimers_work.work, 0, in clear_posix_cputimers_work()
1222 sizeof(p->posix_cputimers_work.work)); in clear_posix_cputimers_work()
1223 init_task_work(&p->posix_cputimers_work.work, in clear_posix_cputimers_work()
1225 mutex_init(&p->posix_cputimers_work.mutex); in clear_posix_cputimers_work()
1226 p->posix_cputimers_work.scheduled = false; in clear_posix_cputimers_work()