Thomas,

Are you OK with this change?

-- Steve


On Wed, 21 Aug 2013 11:44:21 +0800
Li Fei <[email protected]> wrote:

> At present, irq handler function name is not printed out when
> irq_handler_entry is added into trace event, which is inconvenient
> for debugging.
> In order to improve the debugging efficiency, print out the handler
> function name in irq_handler_entry.
> 
> Signed-off-by: Li Fei <[email protected]>
> Acked-by: Liu Chuansheng <[email protected]>
> ---
>  Documentation/trace/ftrace.txt |    8 ++++----
>  include/trace/events/irq.h     |    5 ++++-
>  2 files changed, 8 insertions(+), 5 deletions(-)
> 
> diff --git a/Documentation/trace/ftrace.txt b/Documentation/trace/ftrace.txt
> index b937c6e..907ecbd 100644
> --- a/Documentation/trace/ftrace.txt
> +++ b/Documentation/trace/ftrace.txt
> @@ -2701,10 +2701,10 @@ CPU:2 [LOST 11745 EVENTS]
>              bash-1998  [000] ..s2   138.733106: softirq_exit: vec=1 
> [action=TIMER]
>              bash-1998  [000] ..s2   138.733106: softirq_entry: vec=9 
> [action=RCU]
>              bash-1998  [000] ..s2   138.733109: softirq_exit: vec=9 
> [action=RCU]
> -            sshd-1995  [001] d.h1   138.733278: irq_handler_entry: irq=21 
> name=uhci_hcd:usb4
> -            sshd-1995  [001] d.h1   138.733280: irq_handler_exit: irq=21 
> ret=unhandled
> -            sshd-1995  [001] d.h1   138.733281: irq_handler_entry: irq=21 
> name=eth0
> -            sshd-1995  [001] d.h1   138.733283: irq_handler_exit: irq=21 
> ret=handled
> +            kworker/0:2-161  [001] d.h1   138.733278: irq_handler_entry: 
> irq=17 name=i2c-designware-pci-7 func=i2c_dw_isr
> +            kworker/0:2-161  [001] d.h1   138.733280: irq_handler_exit: 
> irq=17 ret=unhandled
> +            kworker/0:2-161  [001] d.h1   138.733281: irq_handler_entry: 
> irq=17 name=mmc0 func=sdhci_irq
> +            kworker/0:2-161  [001] d.h1   138.733283: irq_handler_exit: 
> irq=17 ret=handled
>  [...]
>  
>   # cat instances/zoot/trace
> diff --git a/include/trace/events/irq.h b/include/trace/events/irq.h
> index 1c09820..3497eb3 100644
> --- a/include/trace/events/irq.h
> +++ b/include/trace/events/irq.h
> @@ -43,14 +43,17 @@ TRACE_EVENT(irq_handler_entry,
>       TP_STRUCT__entry(
>               __field(        int,    irq             )
>               __string(       name,   action->name    )
> +             __field(irq_handler_t, func)
>       ),
>  
>       TP_fast_assign(
>               __entry->irq = irq;
>               __assign_str(name, action->name);
> +             __entry->func = action->handler;
>       ),
>  
> -     TP_printk("irq=%d name=%s", __entry->irq, __get_str(name))
> +     TP_printk("irq=%d name=%s func=%pf",
> +             __entry->irq, __get_str(name), __entry->func)
>  );
>  
>  /**

--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to [email protected]
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Reply via email to