[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <20130211091938.GC525@linux.vnet.ibm.com>
Date: Mon, 11 Feb 2013 14:49:38 +0530
From: Srikar Dronamraju <srikar@...ux.vnet.ibm.com>
To: Oleg Nesterov <oleg@...hat.com>
Cc: Ingo Molnar <mingo@...e.hu>, Steven Rostedt <rostedt@...dmis.org>,
Anton Arapov <anton@...hat.com>,
Frank Eigler <fche@...hat.com>,
Josh Stone <jistone@...hat.com>,
Masami Hiramatsu <masami.hiramatsu.pt@...achi.com>,
"Suzuki K. Poulose" <suzuki@...ibm.com>,
linux-kernel@...r.kernel.org
Subject: Re: [PATCH 6/6] uprobes/perf: Always increment trace_uprobe->nhit
* Oleg Nesterov <oleg@...hat.com> [2013-01-31 20:18:32]:
> Move tu->nhit++ from uprobe_trace_func() to uprobe_dispatcher().
>
> ->nhit counts how many time we hit the breakpoint inserted by this
> uprobe, we do not want to loose this info if uprobe was enabled by
> sys_perf_event_open().
>
> Signed-off-by: Oleg Nesterov <oleg@...hat.com>
Acked-by: Srikar Dronamraju <srikar@...ux.vnet.ibm.com>
> ---
> kernel/trace/trace_uprobe.c | 3 +--
> 1 files changed, 1 insertions(+), 2 deletions(-)
>
> diff --git a/kernel/trace/trace_uprobe.c b/kernel/trace/trace_uprobe.c
> index 55cdc14..0a9a8de 100644
> --- a/kernel/trace/trace_uprobe.c
> +++ b/kernel/trace/trace_uprobe.c
> @@ -473,8 +473,6 @@ static void uprobe_trace_func(struct trace_uprobe *tu, struct pt_regs *regs)
> unsigned long irq_flags;
> struct ftrace_event_call *call = &tu->call;
>
> - tu->nhit++;
> -
> local_save_flags(irq_flags);
> pc = preempt_count();
>
> @@ -698,6 +696,7 @@ static int uprobe_dispatcher(struct uprobe_consumer *con, struct pt_regs *regs)
> struct trace_uprobe *tu;
>
> tu = container_of(con, struct trace_uprobe, consumer);
> + tu->nhit++;
>
> if (tu->flags & TP_FLAG_TRACE)
> uprobe_trace_func(tu, regs);
> --
> 1.5.5.1
>
--
Thanks and Regards
Srikar Dronamraju
--
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