From: Chen Gang <gang.chen@asianux.com>
To: Steven Rostedt <rostedt@goodmis.org>,
Frederic Weisbecker <fweisbec@gmail.com>
Cc: "mingo@redhat.com" <mingo@redhat.com>,
"linux-kernel@vger.kernel.org" <linux-kernel@vger.kernel.org>
Subject: [PATCH] kernel: trace: remove __init from race_selftest_startup_function() and trace_selftest_startup_function_graph()
Date: Thu, 11 Jul 2013 08:31:52 +0800 [thread overview]
Message-ID: <51DDFCF8.2090808@asianux.com> (raw)
Like other trace_selftest_startup_*, trace_selftest_startup_function()
and trace_selftest_startup_function_graph() need in normal section, or
may cause section mismatch.
The related warnings:
LD kernel/trace/built-in.o
WARNING: kernel/trace/built-in.o(.data+0x154c): Section mismatch in reference from the variable function_trace to the function .init.text:trace_selftest_startup_function()
The variable function_trace references
the function __init trace_selftest_startup_function()
If the reference is valid then annotate the
variable with __init* or __refdata (see linux/init.h) or name the variable:
*_template, *_timer, *_sht, *_ops, *_probe, *_probe_one, *_console
Signed-off-by: Chen Gang <gang.chen@asianux.com>
---
kernel/trace/trace_selftest.c | 4 ++--
1 files changed, 2 insertions(+), 2 deletions(-)
diff --git a/kernel/trace/trace_selftest.c b/kernel/trace/trace_selftest.c
index a7329b7..e341b9d 100644
--- a/kernel/trace/trace_selftest.c
+++ b/kernel/trace/trace_selftest.c
@@ -640,7 +640,7 @@ out:
* Enable ftrace, sleep 1/10 second, and then read the trace
* buffer to see if all is in order.
*/
-__init int
+int
trace_selftest_startup_function(struct tracer *trace, struct trace_array *tr)
{
int save_ftrace_enabled = ftrace_enabled;
@@ -734,7 +734,7 @@ static int trace_graph_entry_watchdog(struct ftrace_graph_ent *trace)
* Pretty much the same than for the function tracer from which the selftest
* has been borrowed.
*/
-__init int
+int
trace_selftest_startup_function_graph(struct tracer *trace,
struct trace_array *tr)
{
--
1.7.7.6
next reply other threads:[~2013-07-11 0:32 UTC|newest]
Thread overview: 12+ messages / expand[flat|nested] mbox.gz Atom feed top
2013-07-11 0:31 Chen Gang [this message]
2013-07-11 16:47 ` [PATCH] kernel: trace: remove __init from race_selftest_startup_function() and trace_selftest_startup_function_graph() Steven Rostedt
2013-07-11 23:51 ` Chen Gang
2013-07-12 1:41 ` Steven Rostedt
2013-07-12 1:58 ` Chen Gang
2013-07-12 2:38 ` Steven Rostedt
2013-07-12 3:04 ` Chen Gang
2013-07-12 7:20 ` Chen Gang
2013-07-15 2:12 ` Chen Gang
2013-07-15 16:20 ` Steven Rostedt
2013-07-16 0:22 ` Chen Gang
2013-07-17 0:52 ` Chen Gang
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=51DDFCF8.2090808@asianux.com \
--to=gang.chen@asianux.com \
--cc=fweisbec@gmail.com \
--cc=linux-kernel@vger.kernel.org \
--cc=mingo@redhat.com \
--cc=rostedt@goodmis.org \
/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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.