vtime.h 746 B

123456789101112131415161718192021222324
  1. #ifndef _LINUX_KERNEL_VTIME_H
  2. #define _LINUX_KERNEL_VTIME_H
  3. struct task_struct;
  4. #ifdef CONFIG_VIRT_CPU_ACCOUNTING
  5. extern void vtime_task_switch(struct task_struct *prev);
  6. extern void __vtime_account_system(struct task_struct *tsk);
  7. extern void vtime_account_system(struct task_struct *tsk);
  8. extern void __vtime_account_idle(struct task_struct *tsk);
  9. #else
  10. static inline void vtime_task_switch(struct task_struct *prev) { }
  11. static inline void vtime_account_system(struct task_struct *tsk) { }
  12. #endif
  13. #if !defined(CONFIG_VIRT_CPU_ACCOUNTING) && !defined(CONFIG_IRQ_TIME_ACCOUNTING)
  14. static inline void vtime_account(struct task_struct *tsk)
  15. {
  16. }
  17. #else
  18. extern void vtime_account(struct task_struct *tsk);
  19. #endif
  20. #endif /* _LINUX_KERNEL_VTIME_H */