From 4a7a16dc061e4c57bf288150f51bd4c2ace33723 Mon Sep 17 00:00:00 2001 From: Len Brown Date: Fri, 12 Jun 2009 20:42:08 -0400 Subject: ACPI: move declaration acpi_early_init() to acpi.h Signed-off-by: Len Brown --- init/main.c | 6 +----- 1 file changed, 1 insertion(+), 5 deletions(-) (limited to 'init') diff --git a/init/main.c b/init/main.c index d721dad05dd7..f1b9f0fdb1b4 100644 --- a/init/main.c +++ b/init/main.c @@ -24,6 +24,7 @@ #include #include #include +#include #include #include #include @@ -86,11 +87,6 @@ extern void sbus_init(void); extern void prio_tree_init(void); extern void radix_tree_init(void); extern void free_initmem(void); -#ifdef CONFIG_ACPI -extern void acpi_early_init(void); -#else -static inline void acpi_early_init(void) { } -#endif #ifndef CONFIG_DEBUG_RODATA static inline void mark_rodata_ro(void) { } #endif -- cgit v1.2.3-59-g8ed1b From d4d7d0b9545721d3cabb19d15163bbc66b797707 Mon Sep 17 00:00:00 2001 From: Chris Wilson Date: Mon, 6 Jul 2009 09:31:33 +0100 Subject: perf_counter: Fix the tracepoint channel to perfcounters Fix a missed rename in EVENT_PROFILE support so that it gets built and allows tracepoint tracing from the 'perf' tool. Fix a typo in the (never before built & enabled) portion in perf_counter.c as well, and update that code to the attr.config changes as well. Signed-off-by: Chris Wilson Cc: Ben Gamari Cc: Jason Baron Cc: Frederic Weisbecker Cc: Mike Galbraith Cc: Peter Zijlstra Cc: Paul Mackerras Cc: Steven Rostedt LKML-Reference: <1246869094-21237-1-git-send-email-chris@chris-wilson.co.uk> Signed-off-by: Ingo Molnar --- init/Kconfig | 2 +- kernel/perf_counter.c | 10 +++------- 2 files changed, 4 insertions(+), 8 deletions(-) (limited to 'init') diff --git a/init/Kconfig b/init/Kconfig index 1ce05a4cb5f6..cb2c09270226 100644 --- a/init/Kconfig +++ b/init/Kconfig @@ -962,7 +962,7 @@ config PERF_COUNTERS config EVENT_PROFILE bool "Tracepoint profile sources" - depends on PERF_COUNTERS && EVENT_TRACER + depends on PERF_COUNTERS && EVENT_TRACING default y endmenu diff --git a/kernel/perf_counter.c b/kernel/perf_counter.c index d55a50da2347..c6c38fb7766a 100644 --- a/kernel/perf_counter.c +++ b/kernel/perf_counter.c @@ -3671,7 +3671,7 @@ static const struct pmu perf_ops_task_clock = { void perf_tpcounter_event(int event_id) { struct perf_sample_data data = { - .regs = get_irq_regs(); + .regs = get_irq_regs(), .addr = 0, }; @@ -3687,16 +3687,12 @@ extern void ftrace_profile_disable(int); static void tp_perf_counter_destroy(struct perf_counter *counter) { - ftrace_profile_disable(perf_event_id(&counter->attr)); + ftrace_profile_disable(counter->attr.config); } static const struct pmu *tp_perf_counter_init(struct perf_counter *counter) { - int event_id = perf_event_id(&counter->attr); - int ret; - - ret = ftrace_profile_enable(event_id); - if (ret) + if (ftrace_profile_enable(counter->attr.config)) return NULL; counter->destroy = tp_perf_counter_destroy; -- cgit v1.2.3-59-g8ed1b From 470a1396c25c27b4aff08b14d5c9cd9b3da15e09 Mon Sep 17 00:00:00 2001 From: Peter Zijlstra Date: Wed, 29 Jul 2009 10:50:09 +0200 Subject: tracing, perf_counter: Add help text to CONFIG_EVENT_PROFILE Explain what tracepoint profiling sources are about. Signed-off-by: Peter Zijlstra Acked-by: Jeff Garzik LKML-Reference: <1248856508.6987.3041.camel@twins> Signed-off-by: Ingo Molnar --- init/Kconfig | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) (limited to 'init') diff --git a/init/Kconfig b/init/Kconfig index cb2c09270226..823ee0a2d2a3 100644 --- a/init/Kconfig +++ b/init/Kconfig @@ -961,9 +961,17 @@ config PERF_COUNTERS Say Y if unsure. config EVENT_PROFILE - bool "Tracepoint profile sources" + bool "Tracepoint profiling sources" depends on PERF_COUNTERS && EVENT_TRACING default y + help + Allow the use of tracepoints as software performance counters. + + When this is enabled, you can create perf counters based on + tracepoints using PERF_TYPE_TRACEPOINT and the tracepoint ID + found in debugfs://tracing/events/*/*/id. (The -e/--events + option to the perf tool can parse and interpret symbolic + tracepoints, in the subsystem:tracepoint_name format.) endmenu -- cgit v1.2.3-59-g8ed1b From f26542600e605482a1231c44ddb2966d69bd09b0 Mon Sep 17 00:00:00 2001 From: Ingo Molnar Date: Mon, 29 Jun 2009 10:40:20 +0200 Subject: perf_counter: Set the CONFIG_PERF_COUNTERS default to y if CONFIG_PROFILING=y If user has already enabled profiling support in the kernel (for oprofile, old-style profiling of ftrace) then offer up perfcounters with a y default in interactive kconfig sessions. Still keep it off by default otherwise. Cc: Peter Zijlstra Cc: Linus Torvalds Signed-off-by: Ingo Molnar --- init/Kconfig | 1 + 1 file changed, 1 insertion(+) (limited to 'init') diff --git a/init/Kconfig b/init/Kconfig index 823ee0a2d2a3..3f7e60995c80 100644 --- a/init/Kconfig +++ b/init/Kconfig @@ -940,6 +940,7 @@ menu "Performance Counters" config PERF_COUNTERS bool "Kernel Performance Counters" + default y if PROFILING depends on HAVE_PERF_COUNTERS select ANON_INODES help -- cgit v1.2.3-59-g8ed1b