[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20090210152624.GH5836@nowhere>
Date: Tue, 10 Feb 2009 16:26:25 +0100
From: Frederic Weisbecker <fweisbec@...il.com>
To: Wenji Huang <wenji.huang@...cle.com>
Cc: linux-kernel@...r.kernel.org, rostedt@...dmis.org,
Ingo Molnar <mingo@...e.hu>
Subject: Re: [PATCH 1/1] trace: use the more accurate parameter.
On Mon, Feb 09, 2009 at 07:30:04PM -0500, Wenji Huang wrote:
> Pass tsk to __update_max_tr instead of current to avoid latent hazard.
>
> Impact: clean up
>
> Signed-off-by: Wenji Huang <wenji.huang@...cle.com>
> ---
> kernel/trace/trace.c | 2 +-
> 1 files changed, 1 insertions(+), 1 deletions(-)
>
> diff --git a/kernel/trace/trace.c b/kernel/trace/trace.c
> index 5b1e9a9..c1592f1 100644
> --- a/kernel/trace/trace.c
> +++ b/kernel/trace/trace.c
> @@ -335,7 +335,7 @@ __update_max_tr(struct trace_array *tr, struct task_struct *tsk, int cpu)
> data->rt_priority = tsk->rt_priority;
>
> /* record this tasks comm */
> - tracing_record_cmdline(current);
> + tracing_record_cmdline(tsk);
> }
Indeed. At this stage, tsk is the next task in the middle of a context
switch. So I guess current is right, but this is more proper to use tsk.
> static void
> --
> 1.5.6
>
> --
> 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/
--
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