Using Markers

What are markers?

Here is some text taken from the kernel documentation that describes markers:

What do markers in kernel code look like?

#include <linux/marker.h>
//...
int kernel_function(int mask)
{
        int rc = 0;        // return code
        trace_mark(kernel_function_entry, "mask %d", mask);
        //...
        trace_mark(kernel_function_exit, "rc %d", rc);
}

This function (named 'kernel_function'), has 2 markers present in it. The first one has a subsystem_event of "kernel_function_entry" and the second marker has a subsystem_event of "kernel_function_exit".