aboutsummaryrefslogtreecommitdiffstats
path: root/include/linux/perf_event.h
diff options
context:
space:
mode:
authorAvi Kivity <avi@redhat.com>2011-12-25 08:44:43 -0500
committerAvi Kivity <avi@redhat.com>2011-12-27 04:22:24 -0500
commit9e31905f293ae84e4f120ed9e414031eaefa0bdf (patch)
tree153204ff0dca820e760007bc24075ec7fb46a276 /include/linux/perf_event.h
parentff5c2c0316ff0e3e2dba3ca14167d994453df093 (diff)
parentb3d9468a8bd218a695e3a0ff112cd4efd27b670a (diff)
Merge remote-tracking branch 'tip/perf/core' into kvm-updates/3.3
* tip/perf/core: (66 commits) perf, x86: Expose perf capability to other modules perf, x86: Implement arch event mask as quirk x86, perf: Disable non available architectural events jump_label: Provide jump_label_key initializers jump_label, x86: Fix section mismatch perf, core: Rate limit perf_sched_events jump_label patching perf: Fix enable_on_exec for sibling events perf: Remove superfluous arguments perf, x86: Prefer fixed-purpose counters when scheduling perf, x86: Fix event scheduler for constraints with overlapping counters perf, x86: Implement event scheduler helper functions perf: Avoid a useless pmu_disable() in the perf-tick x86/tools: Add decoded instruction dump mode x86: Update instruction decoder to support new AVX formats x86/tools: Fix insn_sanity message outputs x86/tools: Fix instruction decoder message output x86: Fix instruction decoder to handle grouped AVX instructions x86/tools: Fix Makefile to build all test tools perf test: Soft errors shouldn't stop the "Validate PERF_RECORD_" test perf test: Validate PERF_RECORD_ events and perf_sample fields ... Signed-off-by: Avi Kivity <avi@redhat.com> * commit 'b3d9468a8bd218a695e3a0ff112cd4efd27b670a': (66 commits) perf, x86: Expose perf capability to other modules perf, x86: Implement arch event mask as quirk x86, perf: Disable non available architectural events jump_label: Provide jump_label_key initializers jump_label, x86: Fix section mismatch perf, core: Rate limit perf_sched_events jump_label patching perf: Fix enable_on_exec for sibling events perf: Remove superfluous arguments perf, x86: Prefer fixed-purpose counters when scheduling perf, x86: Fix event scheduler for constraints with overlapping counters perf, x86: Implement event scheduler helper functions perf: Avoid a useless pmu_disable() in the perf-tick x86/tools: Add decoded instruction dump mode x86: Update instruction decoder to support new AVX formats x86/tools: Fix insn_sanity message outputs x86/tools: Fix instruction decoder message output x86: Fix instruction decoder to handle grouped AVX instructions x86/tools: Fix Makefile to build all test tools perf test: Soft errors shouldn't stop the "Validate PERF_RECORD_" test perf test: Validate PERF_RECORD_ events and perf_sample fields ...
Diffstat (limited to 'include/linux/perf_event.h')
-rw-r--r--include/linux/perf_event.h7
1 files changed, 4 insertions, 3 deletions
diff --git a/include/linux/perf_event.h b/include/linux/perf_event.h
index b1f89122bf6a..564769cdb473 100644
--- a/include/linux/perf_event.h
+++ b/include/linux/perf_event.h
@@ -890,6 +890,7 @@ struct perf_event_context {
890 int nr_active; 890 int nr_active;
891 int is_active; 891 int is_active;
892 int nr_stat; 892 int nr_stat;
893 int nr_freq;
893 int rotate_disable; 894 int rotate_disable;
894 atomic_t refcount; 895 atomic_t refcount;
895 struct task_struct *task; 896 struct task_struct *task;
@@ -1063,12 +1064,12 @@ perf_sw_event(u32 event_id, u64 nr, struct pt_regs *regs, u64 addr)
1063 } 1064 }
1064} 1065}
1065 1066
1066extern struct jump_label_key perf_sched_events; 1067extern struct jump_label_key_deferred perf_sched_events;
1067 1068
1068static inline void perf_event_task_sched_in(struct task_struct *prev, 1069static inline void perf_event_task_sched_in(struct task_struct *prev,
1069 struct task_struct *task) 1070 struct task_struct *task)
1070{ 1071{
1071 if (static_branch(&perf_sched_events)) 1072 if (static_branch(&perf_sched_events.key))
1072 __perf_event_task_sched_in(prev, task); 1073 __perf_event_task_sched_in(prev, task);
1073} 1074}
1074 1075
@@ -1077,7 +1078,7 @@ static inline void perf_event_task_sched_out(struct task_struct *prev,
1077{ 1078{
1078 perf_sw_event(PERF_COUNT_SW_CONTEXT_SWITCHES, 1, NULL, 0); 1079 perf_sw_event(PERF_COUNT_SW_CONTEXT_SWITCHES, 1, NULL, 0);
1079 1080
1080 if (static_branch(&perf_sched_events)) 1081 if (static_branch(&perf_sched_events.key))
1081 __perf_event_task_sched_out(prev, next); 1082 __perf_event_task_sched_out(prev, next);
1082} 1083}
1083 1084