mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Paul Bolle <pebolle@tiscali.nl>
To: Tom Zanussi <tom.zanussi@linux.intel.com>
Cc: rostedt@goodmis.org, masami.hiramatsu.pt@hitachi.com,
	namhyung@kernel.org, andi@firstfloor.org,
	linux-kernel@vger.kernel.org
Subject: Re: [PATCH v3 5/7] tracing: Add 'hist' event trigger command
Date: Sat, 04 Apr 2015 22:56:19 +0200	[thread overview]
Message-ID: <1428180979.2368.5.camel@tiscali.nl> (raw)
In-Reply-To: <1428178145.2610.13.camel@picadillo>

Tom Zanussi schreef op za 04-04-2015 om 15:09 [-0500]:
> [PATCH] kallsyms: Include module.h
> 
> KSYM_SYMBOL_LEN references MODULE_NAME_LEN, defined in module.h, so
> have kallsyms.h include module.h instead of expecting kallsysms users
> to do it.
> 
> Also fix up existing kallsyms users that apparently include module.h
> for only that reason.
> 
> Signed-off-by: Tom Zanussi <tom.zanussi@linux.intel.com>
> ---
>  include/linux/ftrace.h           | 1 -
>  include/linux/kallsyms.h         | 1 +
>  kernel/trace/trace_events_hist.c | 2 +-
>  kernel/trace/trace_kprobe.c      | 1 +
>  kernel/trace/trace_output.c      | 1 +
>  kernel/trace/trace_syscalls.c    | 2 +-
>  6 files changed, 5 insertions(+), 3 deletions(-)
> 
> diff --git a/include/linux/ftrace.h b/include/linux/ftrace.h
> index 1da6029..8554dd5 100644
> --- a/include/linux/ftrace.h
> +++ b/include/linux/ftrace.h
> @@ -7,7 +7,6 @@
>  #define _LINUX_FTRACE_H
>  
>  #include <linux/trace_clock.h>
> -#include <linux/kallsyms.h>
>  #include <linux/linkage.h>
>  #include <linux/bitops.h>
>  #include <linux/ptrace.h>

The commit explanation is silent about this change. Are you sure you
want to include it?

> diff --git a/include/linux/kallsyms.h b/include/linux/kallsyms.h
> index 6883e19..e1550a4 100644
> --- a/include/linux/kallsyms.h
> +++ b/include/linux/kallsyms.h
> @@ -8,6 +8,7 @@
>  #include <linux/errno.h>
>  #include <linux/kernel.h>
>  #include <linux/stddef.h>
> +#include <linux/module.h>
>  
>  #define KSYM_NAME_LEN 128
>  #define KSYM_SYMBOL_LEN (sizeof("%s+%#lx/%#lx [%s]") + (KSYM_NAME_LEN - 1) + \
> diff --git a/kernel/trace/trace_events_hist.c b/kernel/trace/trace_events_hist.c
> index 3d648ee..c290379 100644
> --- a/kernel/trace/trace_events_hist.c
> +++ b/kernel/trace/trace_events_hist.c
> @@ -20,7 +20,7 @@
>   * http://www.azulsystems.com/events/javaone_2007/2007_LockFreeHash.pdf
>   */
>  
> -#include <linux/module.h>
> +#include <linux/kallsyms.h>
>  #include <linux/ctype.h>
>  #include <linux/mutex.h>
>  #include <linux/slab.h>
> diff --git a/kernel/trace/trace_kprobe.c b/kernel/trace/trace_kprobe.c
> index 9ba3f43..39019ec 100644
> --- a/kernel/trace/trace_kprobe.c
> +++ b/kernel/trace/trace_kprobe.c
> @@ -19,6 +19,7 @@
>  
>  #include <linux/module.h>

Note to self: needed for "struct module". But this file has two
references to THIS_MODULE that look useless. 

>  #include <linux/uaccess.h>
> +#include <linux/kallsyms.h>
>  
>  #include "trace_probe.h"
>  
> diff --git a/kernel/trace/trace_output.c b/kernel/trace/trace_output.c
> index 692bf71..5ec310e 100644
> --- a/kernel/trace/trace_output.c
> +++ b/kernel/trace/trace_output.c
> @@ -8,6 +8,7 @@
>  #include <linux/module.h>

Can't this be dropped too?

>  #include <linux/mutex.h>
>  #include <linux/ftrace.h>
> +#include <linux/kallsyms.h>
>  
>  #include "trace_output.h"
>  
> diff --git a/kernel/trace/trace_syscalls.c b/kernel/trace/trace_syscalls.c
> index d137e0a..72af617 100644
> --- a/kernel/trace/trace_syscalls.c
> +++ b/kernel/trace/trace_syscalls.c
> @@ -3,7 +3,7 @@
>  #include <linux/syscalls.h>
>  #include <linux/slab.h>
>  #include <linux/kernel.h>
> -#include <linux/module.h>	/* for MODULE_NAME_LEN via KSYM_SYMBOL_LEN */
> +#include <linux/kallsyms.h>
>  #include <linux/ftrace.h>
>  #include <linux/perf_event.h>
>  #include <asm/syscall.h>

Thanks,


Paul Bolle


  reply	other threads:[~2015-04-04 20:56 UTC|newest]

Thread overview: 21+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2015-04-03 15:51 [PATCH v3 0/7] tracing: 'hist' triggers Tom Zanussi
2015-04-03 15:51 ` [PATCH v3 1/7] tracing: Make ftrace_event_field checking functions available Tom Zanussi
2015-04-03 15:51 ` [PATCH v3 2/7] tracing: Add event record param to trigger_ops.func() Tom Zanussi
2015-04-03 15:51 ` [PATCH v3 3/7] tracing: Add get_syscall_name() Tom Zanussi
2015-04-03 15:51 ` [PATCH v3 4/7] tracing: Add a per-event-trigger 'paused' field Tom Zanussi
2015-04-03 15:51 ` [PATCH v3 5/7] tracing: Add 'hist' event trigger command Tom Zanussi
2015-04-04 15:14   ` Paul Bolle
2015-04-04 20:09     ` Tom Zanussi
2015-04-04 20:56       ` Paul Bolle [this message]
2015-04-04 21:06         ` Tom Zanussi
2015-04-06 15:55       ` Steven Rostedt
2015-04-06 15:50     ` Steven Rostedt
2015-04-06 16:19       ` Paul Bolle
2015-04-06 16:25         ` Steven Rostedt
2015-04-06 18:07           ` Paul Bolle
2015-04-04 15:36   ` Alexei Starovoitov
2015-04-04 20:25     ` Tom Zanussi
2015-04-03 15:51 ` [PATCH v3 6/7] tracing: Add enable_hist/disable_hist triggers Tom Zanussi
2015-04-03 15:51 ` [PATCH v3 7/7] tracing: Add 'hist' trigger Documentation Tom Zanussi
2015-04-13 21:18 ` [PATCH v3 0/7] tracing: 'hist' triggers Steven Rostedt
2015-04-13 21:49   ` Tom Zanussi

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=1428180979.2368.5.camel@tiscali.nl \
    --to=pebolle@tiscali.nl \
    --cc=andi@firstfloor.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=masami.hiramatsu.pt@hitachi.com \
    --cc=namhyung@kernel.org \
    --cc=rostedt@goodmis.org \
    --cc=tom.zanussi@linux.intel.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox

Powered by JetHome