oprof.h 1.1 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950
  1. /**
  2. * @file oprof.h
  3. *
  4. * @remark Copyright 2002 OProfile authors
  5. * @remark Read the file COPYING
  6. *
  7. * @author John Levon <levon@movementarian.org>
  8. */
  9. #ifndef OPROF_H
  10. #define OPROF_H
  11. int oprofile_setup(void);
  12. void oprofile_shutdown(void);
  13. int oprofilefs_register(void);
  14. void oprofilefs_unregister(void);
  15. int oprofile_start(void);
  16. void oprofile_stop(void);
  17. struct oprofile_operations;
  18. extern unsigned long oprofile_buffer_size;
  19. extern unsigned long oprofile_cpu_buffer_size;
  20. extern unsigned long oprofile_buffer_watershed;
  21. extern unsigned long oprofile_time_slice;
  22. extern struct oprofile_operations oprofile_ops;
  23. extern unsigned long oprofile_started;
  24. extern unsigned long oprofile_backtrace_depth;
  25. struct dentry;
  26. void oprofile_create_files(struct dentry *root);
  27. int oprofile_timer_init(struct oprofile_operations *ops);
  28. #ifdef CONFIG_OPROFILE_NMI_TIMER
  29. int op_nmi_timer_init(struct oprofile_operations *ops);
  30. #else
  31. static inline int op_nmi_timer_init(struct oprofile_operations *ops)
  32. {
  33. return -ENODEV;
  34. }
  35. #endif
  36. int oprofile_set_ulong(unsigned long *addr, unsigned long val);
  37. int oprofile_set_timeout(unsigned long time);
  38. #endif /* OPROF_H */