3

I want to trace 2 functions in some kernel module that are called during suspend/resume.

These functions do appear in "available_filter_functions".

This is how I am configuring ftrace:

echo nop > current_tracer
echo fun_suspend > set_ftrace_filter
echo fun_resume > set_ftrace_filter
echo function_graph > current_tracer

When I suspend/resume the machine, these functions are called for sure (I see logs) yet do not appear in cat trace

Does anyone have any idea?

Thanks,

Matti

buratino
  • 1,408
  • 2
  • 17
  • 40
user690936
  • 985
  • 5
  • 13
  • 23
  • Possible duplicate of [How to make a linux kernel function available to ftrace function\_graph tracer?](https://stackoverflow.com/questions/15271551/how-to-make-a-linux-kernel-function-available-to-ftrace-function-graph-tracer) – Ciro Santilli OurBigBook.com Jun 24 '17 at 20:32

1 Answers1

3

The functions that i wanted to measure were in a suspend resume flow. And apparently suspend & resume are very problematic for tracing functions(dynamic tracing), and ftrace disables the tracing during this process. So for now you cannot trace those functions.

user690936
  • 985
  • 5
  • 13
  • 23
  • Am I correct in guessing that "ftrace disables the tracing during this process" means that `trace_printk()` calls that you add to the module are not added to the trace log? – buratino Jun 07 '16 at 15:30