diff options
Diffstat (limited to 'include/linux')
-rw-r--r-- | include/linux/perf_event.h | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/include/linux/perf_event.h b/include/linux/perf_event.h index fa151d49a2ee..8d54e6d25eeb 100644 --- a/include/linux/perf_event.h +++ b/include/linux/perf_event.h | |||
@@ -544,6 +544,8 @@ struct perf_pending_entry { | |||
544 | void (*func)(struct perf_pending_entry *); | 544 | void (*func)(struct perf_pending_entry *); |
545 | }; | 545 | }; |
546 | 546 | ||
547 | typedef void (*perf_callback_t)(struct perf_event *, void *); | ||
548 | |||
547 | /** | 549 | /** |
548 | * struct perf_event - performance event kernel representation: | 550 | * struct perf_event - performance event kernel representation: |
549 | */ | 551 | */ |
@@ -639,6 +641,8 @@ struct perf_event { | |||
639 | struct event_filter *filter; | 641 | struct event_filter *filter; |
640 | #endif | 642 | #endif |
641 | 643 | ||
644 | perf_callback_t callback; | ||
645 | |||
642 | #endif /* CONFIG_PERF_EVENTS */ | 646 | #endif /* CONFIG_PERF_EVENTS */ |
643 | }; | 647 | }; |
644 | 648 | ||
@@ -748,7 +752,8 @@ extern int perf_event_release_kernel(struct perf_event *event); | |||
748 | extern struct perf_event * | 752 | extern struct perf_event * |
749 | perf_event_create_kernel_counter(struct perf_event_attr *attr, | 753 | perf_event_create_kernel_counter(struct perf_event_attr *attr, |
750 | int cpu, | 754 | int cpu, |
751 | pid_t pid); | 755 | pid_t pid, |
756 | perf_callback_t callback); | ||
752 | extern u64 perf_event_read_value(struct perf_event *event); | 757 | extern u64 perf_event_read_value(struct perf_event *event); |
753 | 758 | ||
754 | struct perf_sample_data { | 759 | struct perf_sample_data { |