aboutsummaryrefslogtreecommitdiff
path: root/tools/perf/scripts/python/exported-sql-viewer.py
diff options
context:
space:
mode:
authorSteven Rostedt (VMware) <[email protected]>2021-02-25 12:49:58 -0500
committerSteven Rostedt (VMware) <[email protected]>2021-02-25 12:49:58 -0500
commitd814567942ff6ac73869052bdb8ca911364e5eb0 (patch)
treeb6bc74d8536cacfc502403a1417f7c0673b11104 /tools/perf/scripts/python/exported-sql-viewer.py
parent3544de8ee6e4817278b15fe08658de49abf58954 (diff)
mm, tracing: Fix kmem_cache_free trace event to not print stale pointers
The update to kmem_cache_free trace event added printing of the slab name in the trace event. But it only stores the pointer of the name which will be printed as a string when the event is read some time in the future. This is dangerous because the name could be freed in the mean time and when reading the trace event it would try to dereference the string name by the pointer to the name that has been freed. Instead, use the trace event helper macros __string(), __assign_str(), and __get_str() that are for this very case. Cc: Jacob Wen <[email protected]> Fixes: 3544de8ee6e4 ("mm, tracing: record slab name for kmem_cache_free()") Signed-off-by: Steven Rostedt (VMware) <[email protected]>
Diffstat (limited to 'tools/perf/scripts/python/exported-sql-viewer.py')
0 files changed, 0 insertions, 0 deletions