]> git.baikalelectronics.ru Git - kernel.git/commit
tracing: Embed replace_filter_string() helper function
authorSteven Rostedt (VMware) <rostedt@goodmis.org>
Fri, 23 Feb 2018 14:45:27 +0000 (09:45 -0500)
committerSteven Rostedt (VMware) <rostedt@goodmis.org>
Sat, 10 Mar 2018 21:06:07 +0000 (16:06 -0500)
commit08f894b1f7af68ccc84add0d41825d630609b867
treee72d5197552f85dacc92b0f9de917abe3679904a
parent421271636736c1055674704b29869b67e2880881
tracing: Embed replace_filter_string() helper function

The replace_filter_string() frees the current string and then copies a given
string. But in the two locations that it was used, the allocation happened
right after the filter was allocated (nothing to replace). There's no need
for this to be a helper function. Embedding the allocation in the two places
where it was called will make changing the code in the future easier.

Also make the variable consistent (always use "filter_string" as the name,
as it was used in one instance as "filter_str")

Signed-off-by: Steven Rostedt (VMware) <rostedt@goodmis.org>
kernel/trace/trace_events_filter.c