lkml.org 
[lkml]   [2009]   [May]   [5]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [PATCH v3] ftrace: add a tracepoint for __raise_softirq_irqoff()
> +TRACE_EVENT(irq_softirq_raise,

I think 'softirq_raise' is better.

> +
> + TP_PROTO(unsigned int nr),
> +
> + TP_ARGS(nr),
> +
> + TP_STRUCT__entry(
> + __field( unsigned int, nr )
> + ),
> +
> + TP_fast_assign(
> + __entry->nr = nr;
> + ),
> +
> + TP_printk("softirq=%d action=%s is raised",
> + __entry->nr, softirq_to_name[__entry->nr])

"softirq=%d action=%s" is sufficient.

Please see TRACE_EVENT(softirq_entry) and TRACE_EVENT(softirq_exit).


> +);
> +
> #endif /* _TRACE_IRQ_H */
>
> /* This part must be outside protection */
> diff --git a/kernel/softirq.c b/kernel/softirq.c
> index b41fb71..bd0546b 100644
> --- a/kernel/softirq.c
> +++ b/kernel/softirq.c
> @@ -310,6 +310,14 @@ void irq_exit(void)
> preempt_enable_no_resched();
> }
>
> +#ifdef CONFIG_TRACEPOINTS
> +inline void __raise_softirq_irqoff(unsigned int nr)
> +{
> + trace_irq_softirq_raise(nr);
> + or_softirq_pending(1UL << (nr));
> +}
> +#endif
> +
> /*
> * This function must run with irqs disabled!
> */



\
 
 \ /
  Last update: 2009-05-05 08:55    [W:0.102 / U:9.040 seconds]
©2003-2018 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site