Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 8feedc45 authored by qctecmdr Service's avatar qctecmdr Service Committed by Gerrit - the friendly Code Review server
Browse files

Merge "trace: Add trace points for tasklet entry/exit"

parents 68e04e47 cfd8eead
Loading
Loading
Loading
Loading
+45 −0
Original line number Diff line number Diff line
@@ -160,6 +160,51 @@ DEFINE_EVENT(softirq, softirq_raise,
	TP_ARGS(vec_nr)
);

DECLARE_EVENT_CLASS(tasklet,

	TP_PROTO(void *func),

	TP_ARGS(func),

	TP_STRUCT__entry(
		__field( void *,	func)
	),

	TP_fast_assign(
		__entry->func = func;
	),

	TP_printk("function=%pf", __entry->func)
);

DEFINE_EVENT(tasklet, tasklet_entry,

	TP_PROTO(void *func),

	TP_ARGS(func)
);

DEFINE_EVENT(tasklet, tasklet_exit,

	TP_PROTO(void *func),

	TP_ARGS(func)
);

DEFINE_EVENT(tasklet, tasklet_hi_entry,

	TP_PROTO(void *func),

	TP_ARGS(func)
);

DEFINE_EVENT(tasklet, tasklet_hi_exit,

	TP_PROTO(void *func),

	TP_ARGS(func)
);

#endif /*  _TRACE_IRQ_H */

/* This part must be outside protection */
+4 −0
Original line number Diff line number Diff line
@@ -514,7 +514,9 @@ static __latent_entropy void tasklet_action(struct softirq_action *a)
				if (!test_and_clear_bit(TASKLET_STATE_SCHED,
							&t->state))
					BUG();
				trace_tasklet_entry(t->func);
				t->func(t->data);
				trace_tasklet_exit(t->func);
				tasklet_unlock(t);
				continue;
			}
@@ -550,7 +552,9 @@ static __latent_entropy void tasklet_hi_action(struct softirq_action *a)
				if (!test_and_clear_bit(TASKLET_STATE_SCHED,
							&t->state))
					BUG();
				trace_tasklet_hi_entry(t->func);
				t->func(t->data);
				trace_tasklet_hi_exit(t->func);
				tasklet_unlock(t);
				continue;
			}