From: Steven Rostedt <rostedt@goodmis.org>
To: linux-kernel@vger.kernel.org
Cc: Ingo Molnar <mingo@kernel.org>,
Andrew Morton <akpm@linux-foundation.org>,
Al Viro <viro@ZenIV.linux.org.uk>,
Masami Hiramatsu <mhiramat@kernel.org>,
Dmitry Safonov <0x7f454c46@gmail.com>,
Shuah Khan <shuah@kernel.org>
Subject: [RFC][PATCH 5/6] selftests/ftrace: Add some missing glob checks
Date: Tue, 06 Feb 2018 17:43:43 -0500 [thread overview]
Message-ID: <20180206224541.667281142@goodmis.org> (raw)
In-Reply-To: 20180206224338.446477232@goodmis.org
[-- Attachment #1: 0005-selftests-ftrace-Add-some-missing-glob-checks.patch --]
[-- Type: text/plain, Size: 1415 bytes --]
From: "Steven Rostedt (VMware)" <rostedt@goodmis.org>
Al Viro discovered a bug in the glob ftrace filtering code where "*a*b" is
treated the same as "a*b", and functions that would be selected by "*a*b"
but not "a*b" are not selected with "*a*b".
Add tests for patterns "*a*b" and "a*b*" to the glob selftest.
Link: http://lkml.kernel.org/r/20180127170748.GF13338@ZenIV.linux.org.uk
Cc: Shuah Khan <shuah@kernel.org>
Signed-off-by: Steven Rostedt (VMware) <rostedt@goodmis.org>
---
tools/testing/selftests/ftrace/test.d/ftrace/func-filter-glob.tc | 6 ++++++
1 file changed, 6 insertions(+)
diff --git a/tools/testing/selftests/ftrace/test.d/ftrace/func-filter-glob.tc b/tools/testing/selftests/ftrace/test.d/ftrace/func-filter-glob.tc
index 589d52b211b7..27a54a17da65 100644
--- a/tools/testing/selftests/ftrace/test.d/ftrace/func-filter-glob.tc
+++ b/tools/testing/selftests/ftrace/test.d/ftrace/func-filter-glob.tc
@@ -29,6 +29,12 @@ ftrace_filter_check '*schedule*' '^.*schedule.*$'
# filter by *, end match
ftrace_filter_check 'schedule*' '^schedule.*$'
+# filter by *mid*end
+ftrace_filter_check '*aw*lock' '.*aw.*lock$'
+
+# filter by start*mid*
+ftrace_filter_check 'mutex*try*' '^mutex.*try.*'
+
# Advanced full-glob matching feature is recently supported.
# Skip the tests if we are sure the kernel does not support it.
if grep -q 'accepts: .* glob-matching-pattern' README ; then
--
2.15.1
next prev parent reply other threads:[~2018-02-06 22:45 UTC|newest]
Thread overview: 11+ messages / expand[flat|nested] mbox.gz Atom feed top
2018-02-06 22:43 [RFC][PATCH 0/6] tracing: Fix bogus parsing of probes and set_ftrace_filter Steven Rostedt
2018-02-06 22:43 ` [RFC][PATCH 1/6] ftrace: Remove incorrect setting of glob search field Steven Rostedt
2018-02-07 14:35 ` Dmitry Safonov
2018-02-08 14:00 ` Masami Hiramatsu
2018-02-06 22:43 ` [RFC][PATCH 2/6] tracing: Fix parsing of globs with a wildcard at the beginning Steven Rostedt
2018-02-08 14:01 ` Masami Hiramatsu
2018-02-06 22:43 ` [RFC][PATCH 3/6] selftests/ftrace: Have reset_ftrace_filter handle modules Steven Rostedt
2018-02-06 22:43 ` [RFC][PATCH 4/6] selftests/ftrace: Have reset_ftrace_filter handle multiple instances Steven Rostedt
2018-02-06 22:43 ` Steven Rostedt [this message]
2018-02-08 14:07 ` [RFC][PATCH 5/6] selftests/ftrace: Add some missing glob checks Masami Hiramatsu
2018-02-06 22:43 ` [RFC][PATCH 6/6] selftests/ftrace: Add more tests for removing of function probes Steven Rostedt
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20180206224541.667281142@goodmis.org \
--to=rostedt@goodmis.org \
--cc=0x7f454c46@gmail.com \
--cc=akpm@linux-foundation.org \
--cc=linux-kernel@vger.kernel.org \
--cc=mhiramat@kernel.org \
--cc=mingo@kernel.org \
--cc=shuah@kernel.org \
--cc=viro@ZenIV.linux.org.uk \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.