Lines Matching refs:tsk
323 void thread_group_cputime(struct task_struct *tsk, struct task_cputime *times) in thread_group_cputime() argument
325 struct signal_struct *sig = tsk->signal; in thread_group_cputime()
339 if (same_thread_group(current, tsk)) in thread_group_cputime()
352 for_each_thread(tsk, t) { in thread_group_cputime()
452 void vtime_account_irq(struct task_struct *tsk, unsigned int offset) in vtime_account_irq() argument
457 vtime_account_hardirq(tsk); in vtime_account_irq()
459 vtime_account_softirq(tsk); in vtime_account_irq()
461 is_idle_task(tsk)) { in vtime_account_irq()
462 vtime_account_idle(tsk); in vtime_account_irq()
464 vtime_account_kernel(tsk); in vtime_account_irq()
703 static void vtime_account_system(struct task_struct *tsk, in vtime_account_system() argument
708 account_system_time(tsk, irq_count(), vtime->stime); in vtime_account_system()
713 static void vtime_account_guest(struct task_struct *tsk, in vtime_account_guest() argument
718 account_guest_time(tsk, vtime->gtime); in vtime_account_guest()
723 static void __vtime_account_kernel(struct task_struct *tsk, in __vtime_account_kernel() argument
728 vtime_account_guest(tsk, vtime); in __vtime_account_kernel()
730 vtime_account_system(tsk, vtime); in __vtime_account_kernel()
733 void vtime_account_kernel(struct task_struct *tsk) in vtime_account_kernel() argument
735 struct vtime *vtime = &tsk->vtime; in vtime_account_kernel()
741 __vtime_account_kernel(tsk, vtime); in vtime_account_kernel()
745 void vtime_user_enter(struct task_struct *tsk) in vtime_user_enter() argument
747 struct vtime *vtime = &tsk->vtime; in vtime_user_enter()
750 vtime_account_system(tsk, vtime); in vtime_user_enter()
755 void vtime_user_exit(struct task_struct *tsk) in vtime_user_exit() argument
757 struct vtime *vtime = &tsk->vtime; in vtime_user_exit()
762 account_user_time(tsk, vtime->utime); in vtime_user_exit()
769 void vtime_guest_enter(struct task_struct *tsk) in vtime_guest_enter() argument
771 struct vtime *vtime = &tsk->vtime; in vtime_guest_enter()
780 vtime_account_system(tsk, vtime); in vtime_guest_enter()
781 tsk->flags |= PF_VCPU; in vtime_guest_enter()
787 void vtime_guest_exit(struct task_struct *tsk) in vtime_guest_exit() argument
789 struct vtime *vtime = &tsk->vtime; in vtime_guest_exit()
792 vtime_account_guest(tsk, vtime); in vtime_guest_exit()
793 tsk->flags &= ~PF_VCPU; in vtime_guest_exit()
799 void vtime_account_idle(struct task_struct *tsk) in vtime_account_idle() argument
801 account_idle_time(get_vtime_delta(&tsk->vtime)); in vtime_account_idle()
947 struct task_struct *tsk, in kcpustat_field_vtime() argument
951 struct vtime *vtime = &tsk->vtime; in kcpustat_field_vtime()
978 if (task_nice(tsk) <= 0) in kcpustat_field_vtime()
982 if (task_nice(tsk) > 0) in kcpustat_field_vtime()
986 if (state == VTIME_GUEST && task_nice(tsk) <= 0) in kcpustat_field_vtime()
990 if (state == VTIME_GUEST && task_nice(tsk) > 0) in kcpustat_field_vtime()
1037 struct task_struct *tsk, int cpu) in kcpustat_cpu_fetch_vtime() argument
1039 struct vtime *vtime = &tsk->vtime; in kcpustat_cpu_fetch_vtime()
1069 if (task_nice(tsk) > 0) in kcpustat_cpu_fetch_vtime()
1075 if (task_nice(tsk) > 0) { in kcpustat_cpu_fetch_vtime()