diff options
Diffstat (limited to 'include')
-rw-r--r-- | include/linux/perf_event.h | 9 | ||||
-rw-r--r-- | include/trace/ftrace.h | 2 |
2 files changed, 8 insertions, 3 deletions
diff --git a/include/linux/perf_event.h b/include/linux/perf_event.h index fb6c91eac7e3..5d0266d94985 100644 --- a/include/linux/perf_event.h +++ b/include/linux/perf_event.h | |||
@@ -585,6 +585,7 @@ enum perf_event_active_state { | |||
585 | struct file; | 585 | struct file; |
586 | 586 | ||
587 | struct perf_mmap_data { | 587 | struct perf_mmap_data { |
588 | atomic_t refcount; | ||
588 | struct rcu_head rcu_head; | 589 | struct rcu_head rcu_head; |
589 | #ifdef CONFIG_PERF_USE_VMALLOC | 590 | #ifdef CONFIG_PERF_USE_VMALLOC |
590 | struct work_struct work; | 591 | struct work_struct work; |
@@ -592,7 +593,6 @@ struct perf_mmap_data { | |||
592 | #endif | 593 | #endif |
593 | int nr_pages; /* nr of data pages */ | 594 | int nr_pages; /* nr of data pages */ |
594 | int writable; /* are we writable */ | 595 | int writable; /* are we writable */ |
595 | int nr_locked; /* nr pages mlocked */ | ||
596 | 596 | ||
597 | atomic_t poll; /* POLL_ for wakeups */ | 597 | atomic_t poll; /* POLL_ for wakeups */ |
598 | 598 | ||
@@ -631,6 +631,9 @@ struct swevent_hlist { | |||
631 | struct rcu_head rcu_head; | 631 | struct rcu_head rcu_head; |
632 | }; | 632 | }; |
633 | 633 | ||
634 | #define PERF_ATTACH_CONTEXT 0x01 | ||
635 | #define PERF_ATTACH_GROUP 0x02 | ||
636 | |||
634 | /** | 637 | /** |
635 | * struct perf_event - performance event kernel representation: | 638 | * struct perf_event - performance event kernel representation: |
636 | */ | 639 | */ |
@@ -643,10 +646,10 @@ struct perf_event { | |||
643 | int nr_siblings; | 646 | int nr_siblings; |
644 | int group_flags; | 647 | int group_flags; |
645 | struct perf_event *group_leader; | 648 | struct perf_event *group_leader; |
646 | struct perf_event *output; | ||
647 | const struct pmu *pmu; | 649 | const struct pmu *pmu; |
648 | 650 | ||
649 | enum perf_event_active_state state; | 651 | enum perf_event_active_state state; |
652 | unsigned int attach_state; | ||
650 | atomic64_t count; | 653 | atomic64_t count; |
651 | 654 | ||
652 | /* | 655 | /* |
@@ -704,6 +707,8 @@ struct perf_event { | |||
704 | /* mmap bits */ | 707 | /* mmap bits */ |
705 | struct mutex mmap_mutex; | 708 | struct mutex mmap_mutex; |
706 | atomic_t mmap_count; | 709 | atomic_t mmap_count; |
710 | int mmap_locked; | ||
711 | struct user_struct *mmap_user; | ||
707 | struct perf_mmap_data *data; | 712 | struct perf_mmap_data *data; |
708 | 713 | ||
709 | /* poll related */ | 714 | /* poll related */ |
diff --git a/include/trace/ftrace.h b/include/trace/ftrace.h index 3d685d1f2a03..5a64905d7278 100644 --- a/include/trace/ftrace.h +++ b/include/trace/ftrace.h | |||
@@ -725,7 +725,7 @@ perf_trace_##call(void *__data, proto) \ | |||
725 | \ | 725 | \ |
726 | { assign; } \ | 726 | { assign; } \ |
727 | \ | 727 | \ |
728 | head = per_cpu_ptr(event_call->perf_events, smp_processor_id());\ | 728 | head = this_cpu_ptr(event_call->perf_events); \ |
729 | perf_trace_buf_submit(entry, __entry_size, rctx, __addr, \ | 729 | perf_trace_buf_submit(entry, __entry_size, rctx, __addr, \ |
730 | __count, &__regs, head); \ | 730 | __count, &__regs, head); \ |
731 | } | 731 | } |