'ftrace not able to trace ubi related functions in linux kernel

I am on kernel 5.4 LTS and not able to trace UBI related kernel calls.

I am doing ubiattach -m 3 -d 3 and want to trace all corresponding kernel internal calls. There are certain kernel functions e.g. ubi_attach() and scan_all() which I am sure are getting called in my case because I can see the corresponding dmesg logs. I have done the following

$ echo 0 > tracing_on
$ echo function_graph > current_tracer
$ echo ubi* > set_graph_function
$ cat enabled_functions | grep ubi_attach
ubi_attach_mtd_dev
ubi_attach
$ echo 1 > tracing_on
$ ubiattach -m 3 -d 3
UBI device number 3, total 144 LEBs (18855936 bytes, 18.0 MiB), available 0 LEBs (0 bytes), LEB size 130944 bytes (127.9 KiB)
$ echo 0 > tracing_on
$ cat trace | grep -i ubi
$ head trace
# tracer: function_graph
#
# CPU  DURATION                  FUNCTION CALLS
# |     |   |                     |   |   |   |
  6)   0.059 us    |      } /* dput */
  6)   0.055 us    |      mntput();
  6)   1.238 us    |    } /* path_put */
  6)   0.072 us    |    unroll_tree_refs();
  6)   0.056 us    |    kfree();
  6)   2.833 us    |  } /* __audit_syscall_exit */

What am I missing? Why i do not see the UBI kernel calls in the ftrace?



Sources

This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.

Source: Stack Overflow

Solution Source