Skip to content

Commit

Permalink
perf/core: Remove perf CPU notifier code
Browse files Browse the repository at this point in the history
All users converted to state machine callbacks.

Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
Signed-off-by: Anna-Maria Gleixner <anna-maria@linutronix.de>
Reviewed-by: Sebastian Andrzej Siewior <bigeasy@linutronix.de>
Cc: Alexander Shishkin <alexander.shishkin@linux.intel.com>
Cc: Arnaldo Carvalho de Melo <acme@kernel.org>
Cc: Linus Torvalds <torvalds@linux-foundation.org>
Cc: Nicolas Iooss <nicolas.iooss_linux@m4x.org>
Cc: Paul E. McKenney <paulmck@linux.vnet.ibm.com>
Cc: Peter Zijlstra <peterz@infradead.org>
Cc: rt@linutronix.de
Link: http://lkml.kernel.org/r/20160713153335.115333381@linutronix.de
Signed-off-by: Ingo Molnar <mingo@kernel.org>
  • Loading branch information
Thomas Gleixner authored and Ingo Molnar committed Jul 14, 2016
1 parent 8381f6a commit 89ab9cb
Show file tree
Hide file tree
Showing 2 changed files with 0 additions and 37 deletions.
2 changes: 0 additions & 2 deletions include/linux/cpu.h
Original file line number Diff line number Diff line change
Expand Up @@ -59,8 +59,6 @@ struct notifier_block;
* CPU notifier priorities.
*/
enum {
CPU_PRI_PERF = 20,

/* bring up workqueues before normal notifiers and down after */
CPU_PRI_WORKQUEUE_UP = 5,
CPU_PRI_WORKQUEUE_DOWN = -5,
Expand Down
35 changes: 0 additions & 35 deletions include/linux/perf_event.h
Original file line number Diff line number Diff line change
Expand Up @@ -1285,41 +1285,6 @@ static inline void perf_restore_debug_store(void) { }

#define perf_output_put(handle, x) perf_output_copy((handle), &(x), sizeof(x))

/*
* This has to have a higher priority than migration_notifier in sched/core.c.
*/
#define perf_cpu_notifier(fn) \
do { \
static struct notifier_block fn##_nb = \
{ .notifier_call = fn, .priority = CPU_PRI_PERF }; \
unsigned long cpu = smp_processor_id(); \
unsigned long flags; \
\
cpu_notifier_register_begin(); \
fn(&fn##_nb, (unsigned long)CPU_UP_PREPARE, \
(void *)(unsigned long)cpu); \
local_irq_save(flags); \
fn(&fn##_nb, (unsigned long)CPU_STARTING, \
(void *)(unsigned long)cpu); \
local_irq_restore(flags); \
fn(&fn##_nb, (unsigned long)CPU_ONLINE, \
(void *)(unsigned long)cpu); \
__register_cpu_notifier(&fn##_nb); \
cpu_notifier_register_done(); \
} while (0)

/*
* Bare-bones version of perf_cpu_notifier(), which doesn't invoke the
* callback for already online CPUs.
*/
#define __perf_cpu_notifier(fn) \
do { \
static struct notifier_block fn##_nb = \
{ .notifier_call = fn, .priority = CPU_PRI_PERF }; \
\
__register_cpu_notifier(&fn##_nb); \
} while (0)

struct perf_pmu_events_attr {
struct device_attribute attr;
u64 id;
Expand Down

0 comments on commit 89ab9cb

Please sign in to comment.