tracing/filters: allow user-input to be integer-like string
authorLi Zefan <lizf@cn.fujitsu.com>
Tue, 21 Apr 2009 09:12:11 +0000 (17:12 +0800)
committerIngo Molnar <mingo@elte.hu>
Tue, 21 Apr 2009 09:58:28 +0000 (11:58 +0200)
commitf66578a7637b87810cbb9041c4e3a77fd2fa4706
tree13b4ac67791369daa1b9559f427e128a70e6b9aa
parente8082f3f5a17d7a7bfc7dd1050a3f958dc034e9a
tracing/filters: allow user-input to be integer-like string

Suppose we would like to trace all tasks named '123', but this
will fail:

 # echo 'parent_comm == 123' > events/sched/sched_process_fork/filter
 bash: echo: write error: Invalid argument

Don't guess the type of the filter pred in filter_parse(), but instead
we check it in __filter_add_pred().

[ Impact: extend allowed filter field string values ]

Signed-off-by: Li Zefan <lizf@cn.fujitsu.com>
Cc: Tom Zanussi <tzanussi@gmail.com>
Cc: Steven Rostedt <rostedt@goodmis.org>
Cc: Frederic Weisbecker <fweisbec@gmail.com>
LKML-Reference: <49ED8DEB.6000700@cn.fujitsu.com>
Signed-off-by: Ingo Molnar <mingo@elte.hu>
kernel/trace/trace_events_filter.c