comm.h 600 B

1234567891011121314151617181920212223242526272829
  1. /* SPDX-License-Identifier: GPL-2.0 */
  2. #ifndef __PERF_COMM_H
  3. #define __PERF_COMM_H
  4. #include "../perf.h"
  5. #include <linux/rbtree.h>
  6. #include <linux/list.h>
  7. struct comm_str;
  8. struct comm {
  9. struct comm_str *comm_str;
  10. u64 start;
  11. struct list_head list;
  12. bool exec;
  13. union { /* Tool specific area */
  14. void *priv;
  15. u64 db_id;
  16. };
  17. };
  18. void comm__free(struct comm *comm);
  19. struct comm *comm__new(const char *str, u64 timestamp, bool exec);
  20. const char *comm__str(const struct comm *comm);
  21. int comm__override(struct comm *comm, const char *str, u64 timestamp,
  22. bool exec);
  23. #endif /* __PERF_COMM_H */