mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Steven Rostedt <rostedt@goodmis.org>
To: Jan Kiszka <jan.kiszka@siemens.com>
Cc: Linux Kernel Mailing List <linux-kernel@vger.kernel.org>,
	Frederic Weisbecker <fweisbec@gmail.com>,
	Ingo Molnar <mingo@redhat.com>
Subject: Re: [PATCH] ftrace: Consistently restore trace function on sysctl enabling
Date: Tue, 26 Mar 2013 15:10:14 -0400	[thread overview]
Message-ID: <1364325014.6345.195.camel@gandalf.local.home> (raw)
In-Reply-To: <5151D26F.1070702@siemens.com>

On Tue, 2013-03-26 at 17:53 +0100, Jan Kiszka wrote:
> If we reenable ftrace via syctl, we currently set ftrace_trace_function
> based on the previous simplistic algorithm. This is inconsistent with
> what update_ftrace_function does. So better call that helper instead.
> 
> Signed-off-by: Jan Kiszka <jan.kiszka@siemens.com>
> ---
>  kernel/trace/ftrace.c |    8 ++------
>  1 files changed, 2 insertions(+), 6 deletions(-)
> 
> diff --git a/kernel/trace/ftrace.c b/kernel/trace/ftrace.c
> index 62b71f6..b9b90f0 100644
> --- a/kernel/trace/ftrace.c
> +++ b/kernel/trace/ftrace.c
> @@ -4538,12 +4538,8 @@ ftrace_enable_sysctl(struct ctl_table *table, int write,
>  		ftrace_startup_sysctl();
>  
>  		/* we are starting ftrace again */
> -		if (ftrace_ops_list != &ftrace_list_end) {
> -			if (ftrace_ops_list->next == &ftrace_list_end)
> -				ftrace_trace_function = ftrace_ops_list->func;
> -			else
> -				ftrace_trace_function = ftrace_ops_list_func;
> -		}

I remember there was a reason why I didn't update this, but I can't
remember why. Looking at it now, it doesn't look like there is a reason.

I'll have to think about this one more. Another score for not
commenting :-p

Thanks,

-- Steve

> +		if (ftrace_ops_list != &ftrace_list_end)
> +			update_ftrace_function();
>  
>  	} else {
>  		/* stopping ftrace calls (just send to ftrace_stub) */



  reply	other threads:[~2013-03-26 19:10 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2013-03-26 16:53 Jan Kiszka
2013-03-26 19:10 ` Steven Rostedt [this message]
2013-03-26 19:55   ` Steven Rostedt

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=1364325014.6345.195.camel@gandalf.local.home \
    --to=rostedt@goodmis.org \
    --cc=fweisbec@gmail.com \
    --cc=jan.kiszka@siemens.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=mingo@redhat.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

all inboxes | Powered by JetHome®