lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <1288232716.18238.140.camel@gandalf.stny.rr.com>
Date:	Wed, 27 Oct 2010 22:25:16 -0400
From:	Steven Rostedt <rostedt@...dmis.org>
To:	Mathieu Desnoyers <mathieu.desnoyers@...icios.com>
Cc:	linux-kernel@...r.kernel.org
Subject: Re: [PATCH] tracing: fix TRACE_EVENT power tracepoint creation

On Wed, 2010-10-27 at 22:16 -0400, Mathieu Desnoyers wrote:
> DEFINE_TRACE should also exist when CONFIG_EVENT_TRACING=n. Otherwise, setting
> only TRACEPOINTS=y is broken.

NAK, DEFINE_TRACE is deprecated from use outside the tracing
infrastructure.

> 
> Signed-off-by: Mathieu Desnoyers <mathieu.desnoyers@...icios.com>
> ---
>  kernel/Makefile             |    1 +
>  kernel/trace/Makefile       |    2 +-
>  kernel/trace/power-traces.c |    6 ++++++
>  3 files changed, 8 insertions(+), 1 deletion(-)
> 
> Index: linux-2.6-lttng/kernel/Makefile
> ===================================================================
> --- linux-2.6-lttng.orig/kernel/Makefile
> +++ linux-2.6-lttng/kernel/Makefile
> @@ -93,6 +93,7 @@ obj-$(CONFIG_TASKSTATS) += taskstats.o t
>  obj-$(USE_IMMEDIATE) += immediate.o
>  obj-$(CONFIG_MARKERS) += marker.o
>  obj-$(CONFIG_TRACEPOINTS) += tracepoint.o
> +obj-$(CONFIG_TRACEPOINTS) += trace/
>  obj-$(CONFIG_LATENCYTOP) += latencytop.o
>  obj-$(CONFIG_BINFMT_ELF) += elfcore.o
>  obj-$(CONFIG_COMPAT_BINFMT_ELF) += elfcore.o
> Index: linux-2.6-lttng/kernel/trace/Makefile
> ===================================================================
> --- linux-2.6-lttng.orig/kernel/trace/Makefile
> +++ linux-2.6-lttng/kernel/trace/Makefile
> @@ -52,7 +52,7 @@ obj-$(CONFIG_EVENT_TRACING) += trace_eve
>  endif
>  obj-$(CONFIG_EVENT_TRACING) += trace_events_filter.o
>  obj-$(CONFIG_KPROBE_EVENT) += trace_kprobe.o
> -obj-$(CONFIG_EVENT_TRACING) += power-traces.o
> +obj-$(CONFIG_TRACEPOINTS) += power-traces.o
>  ifeq ($(CONFIG_TRACING),y)
>  obj-$(CONFIG_KGDB_KDB) += trace_kdb.o
>  endif
> Index: linux-2.6-lttng/kernel/trace/power-traces.c
> ===================================================================
> --- linux-2.6-lttng.orig/kernel/trace/power-traces.c
> +++ linux-2.6-lttng/kernel/trace/power-traces.c
> @@ -10,8 +10,14 @@
>  #include <linux/sched.h>
>  #include <linux/module.h>
>  
> +#ifdef CONFIG_EVENT_TRACING
>  #define CREATE_TRACE_POINTS
>  #include <trace/events/power.h>
> +#else
> +DEFINE_TRACE(power_start);
> +DEFINE_TRACE(power_end);
> +DEFINE_TRACE(power_frequency);
> +#endif

The trace/events/power.h file should handle the DEFINE_TRACE() when
CONFIG_EVENT_TRACING is not set. Thus, this is the wrong fix.

-- Steve

>  
>  EXPORT_TRACEPOINT_SYMBOL_GPL(power_frequency);
>  


--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ