accounting.h 908 B

1234567891011121314151617181920212223242526272829303132
  1. /* SPDX-License-Identifier: GPL-2.0-or-later */
  2. /*
  3. * Common time accounting prototypes and such for all ppc machines.
  4. */
  5. #ifndef __POWERPC_ACCOUNTING_H
  6. #define __POWERPC_ACCOUNTING_H
  7. /* Stuff for accurate time accounting */
  8. struct cpu_accounting_data {
  9. /* Accumulated cputime values to flush on ticks*/
  10. unsigned long utime;
  11. unsigned long stime;
  12. #ifdef CONFIG_ARCH_HAS_SCALED_CPUTIME
  13. unsigned long utime_scaled;
  14. unsigned long stime_scaled;
  15. #endif
  16. unsigned long gtime;
  17. unsigned long hardirq_time;
  18. unsigned long softirq_time;
  19. unsigned long steal_time;
  20. unsigned long idle_time;
  21. /* Internal counters */
  22. unsigned long starttime; /* TB value snapshot */
  23. unsigned long starttime_user; /* TB value on exit to usermode */
  24. #ifdef CONFIG_ARCH_HAS_SCALED_CPUTIME
  25. unsigned long startspurr; /* SPURR value snapshot */
  26. unsigned long utime_sspurr; /* ->user_time when ->startspurr set */
  27. #endif
  28. };
  29. #endif