lkml.org 
[lkml]   [2011]   [Jul]   [14]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [PATCH 5/6] trace: Add tracepoints to call function interrupt handlers
On Thu, Jul 14, 2011 at 02:38:14PM -0700, Vaibhav Nagarnaik wrote:
> Add tracepoints to call function and call function single interrupt
> handlers.
>
> This is a part of overall effort to trace all the interrupts happening
> in a system to figure out what time is spent in kernel space versus user
> space.
>
> Signed-off-by: Vaibhav Nagarnaik <vnagarnaik@google.com>
> ---
> include/trace/events/irq.h | 73 ++++++++++++++++++++++++++++++++++++++++++++
> kernel/smp.c | 5 +++
> 2 files changed, 78 insertions(+), 0 deletions(-)
>
> diff --git a/include/trace/events/irq.h b/include/trace/events/irq.h
> index a2a0a49..40b19f4 100644
> --- a/include/trace/events/irq.h
> +++ b/include/trace/events/irq.h
> @@ -384,6 +384,79 @@ DEFINE_EVENT(reschedule_interrupt, reschedule_interrupt_exit,
> TP_ARGS(ignore)
> );
>
> +DECLARE_EVENT_CLASS(call_function,
> +
> + TP_PROTO(unsigned int ignore),
> +
> + TP_ARGS(ignore),
> +
> + TP_STRUCT__entry(
> + __field( unsigned int, ignore )
> + ),
> +
> + TP_fast_assign(
> + __entry->ignore = ignore;
> + ),
> +
> + TP_printk("%u", __entry->ignore)
> +);
> +
> +/**
> + * call_function_entry - called immediately after entering the
> + * call function interrupt handler
> + *
> + * When used in combination with the call_function_exit tracepoint
> + * we can determine the call function interrupt handler runtime.
> + */
> +DEFINE_EVENT(call_function, call_function_entry,
> +
> + TP_PROTO(unsigned int ignore),
> +
> + TP_ARGS(ignore)
> +);

Looks good. But perhaps we need some disambiguation on the names, call_function is perhaps
too generic.

What about trace_irq_call_function() ? Or may be something with ipi in the name, dunno.


\
 
 \ /
  Last update: 2011-07-15 00:07    [from the cache]
©2003-2011 Jasper Spaans