summaryrefslogtreecommitdiffstats
path: root/kernel/workqueue_internal.h
diff options
context:
space:
mode:
authorSteven Rostedt (Red Hat) <rostedt@goodmis.org>2015-09-30 17:11:15 +0200
committerSteven Rostedt <rostedt@goodmis.org>2015-09-30 21:22:56 +0200
commit9a38a8856f41f90cc7e57798c544e3fe77033196 (patch)
tree346a947988b62983e0619223b96f84bc5b238152 /kernel/workqueue_internal.h
parenttracing: Move trace_flags from global to a trace_array field (diff)
downloadlinux-9a38a8856f41f90cc7e57798c544e3fe77033196.tar.xz
linux-9a38a8856f41f90cc7e57798c544e3fe77033196.zip
tracing: Add a method to pass in trace_array descriptor to option files
In preparation of having the multi buffer instances having their own trace option flags, the trace option files needs a way to not only pass in the flag they represent, but also the trace_array descriptor. A new field is added to the trace_array descriptor called trace_flags_index, which is a 32 byte character array representing a bit. This array is simply filled with the index of the array, where index_array[n] = n; Then the address of this array is passed to the file callbacks instead of the index of the flag index. Then to retrieve both the flag index and the trace_array descriptor: data is the passed in argument. index = *(unsigned char *)data; data -= index; /* Now data points to the address of the array in the trace_array */ tr = container_of(data, struct trace_array, trace_flags_index); Suggested-by: Johannes Berg <johannes.berg@intel.com> Signed-off-by: Steven Rostedt <rostedt@goodmis.org>
Diffstat (limited to 'kernel/workqueue_internal.h')
0 files changed, 0 insertions, 0 deletions