trace: Modify timer_start and irq_handler_entry trace events.
The timer_start event now shows whether the timer is deferrable in case of a low-res timer. The debug_activate function now includes deferrable flag while calling trace_timer_start event. irq_handler_entry event includes the ISR function in the trace event. Change-Id: Ia2eeb4fa0fae34b301964144dad8bcef7632487c Signed-off-by: Badhri Jagan Sridharan <badhris@codeaurora.org> (cherry picked from commit a2cd6eaf5deaa40098eb6b692797519bc173381e)
This commit is contained in:
parent
f9c5c04903
commit
77202e52b3
|
@ -43,14 +43,17 @@ TRACE_EVENT(irq_handler_entry,
|
|||
TP_STRUCT__entry(
|
||||
__field( int, irq )
|
||||
__string( name, action->name )
|
||||
__field(void*, handler)
|
||||
),
|
||||
|
||||
TP_fast_assign(
|
||||
__entry->irq = irq;
|
||||
__assign_str(name, action->name);
|
||||
__entry->handler = action->handler;
|
||||
),
|
||||
|
||||
TP_printk("irq=%d name=%s", __entry->irq, __get_str(name))
|
||||
TP_printk("irq=%d name=%s handler=%pf",
|
||||
__entry->irq, __get_str(name), __entry->handler)
|
||||
);
|
||||
|
||||
/**
|
||||
|
|
|
@ -43,15 +43,17 @@ DEFINE_EVENT(timer_class, timer_init,
|
|||
*/
|
||||
TRACE_EVENT(timer_start,
|
||||
|
||||
TP_PROTO(struct timer_list *timer, unsigned long expires),
|
||||
TP_PROTO(struct timer_list *timer,
|
||||
unsigned long expires, char deferrable),
|
||||
|
||||
TP_ARGS(timer, expires),
|
||||
TP_ARGS(timer, expires, deferrable),
|
||||
|
||||
TP_STRUCT__entry(
|
||||
__field( void *, timer )
|
||||
__field( void *, function )
|
||||
__field( unsigned long, expires )
|
||||
__field( unsigned long, now )
|
||||
__field(char, deferrable)
|
||||
),
|
||||
|
||||
TP_fast_assign(
|
||||
|
@ -59,11 +61,12 @@ TRACE_EVENT(timer_start,
|
|||
__entry->function = timer->function;
|
||||
__entry->expires = expires;
|
||||
__entry->now = jiffies;
|
||||
__entry->deferrable = deferrable;
|
||||
),
|
||||
|
||||
TP_printk("timer=%p function=%pf expires=%lu [timeout=%ld]",
|
||||
TP_printk("timer=%p function=%pf expires=%lu [timeout=%ld] defer=%c",
|
||||
__entry->timer, __entry->function, __entry->expires,
|
||||
(long)__entry->expires - __entry->now)
|
||||
(long)__entry->expires - __entry->now, __entry->deferrable)
|
||||
);
|
||||
|
||||
/**
|
||||
|
|
|
@ -602,7 +602,8 @@ static inline void
|
|||
debug_activate(struct timer_list *timer, unsigned long expires)
|
||||
{
|
||||
debug_timer_activate(timer);
|
||||
trace_timer_start(timer, expires);
|
||||
trace_timer_start(timer, expires,
|
||||
tbase_get_deferrable(timer->base) > 0 ? 'y' : 'n');
|
||||
}
|
||||
|
||||
static inline void debug_deactivate(struct timer_list *timer)
|
||||
|
|
Loading…
Reference in New Issue