aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/tools/testing/selftests/ftrace/test.d/trigger/inter-event/trigger-synthetic_event_syntax_errors.tc
diff options
context:
space:
mode:
authorTom Zanussi <zanussi@kernel.org>2021-02-01 13:48:14 -0600
committerSteven Rostedt (VMware) <rostedt@goodmis.org>2021-02-09 12:52:15 -0500
commit8b5ab6bd0b293408ed8c9450831f879ce9903ea2 (patch)
tree9181d0ffc9bc5333bea7a52da4584c74e4dbc8a5 /tools/testing/selftests/ftrace/test.d/trigger/inter-event/trigger-synthetic_event_syntax_errors.tc
parenttracing: Update synth command errors (diff)
downloadwireguard-linux-8b5ab6bd0b293408ed8c9450831f879ce9903ea2.tar.xz
wireguard-linux-8b5ab6bd0b293408ed8c9450831f879ce9903ea2.zip
tracing: Add a backward-compatibility check for synthetic event creation
The synthetic event parsing rework now requires semicolons between synthetic event fields. That requirement breaks existing users who might already have used the old synthetic event command format, so this adds an inner loop that can parse more than one field, if present, between semicolons. For each field, parse_synth_field() checks in which version that field was introduced, using check_field_version(). The caller, __create_synth_event() can then use that version information to determine whether or not to enforce the requirement on the command as a whole. In the future, if/when new features are added, the requirement will be that any field/string containing the new feature must use semicolons, and the check_field_version() check can then check for those and enforce it. Using a version number allows this scheme to be extended if necessary. Link: https://lkml.kernel.org/r/74fcc500d561b40ce91c5ee94818c70c6b0c9330.1612208610.git.zanussi@kernel.org [ zanussi: added check_field_version() comment from rostedt@goodmis.org ] Signed-off-by: Tom Zanussi <zanussi@kernel.org> Signed-off-by: Steven Rostedt (VMware) <rostedt@goodmis.org>
Diffstat (limited to 'tools/testing/selftests/ftrace/test.d/trigger/inter-event/trigger-synthetic_event_syntax_errors.tc')
0 files changed, 0 insertions, 0 deletions