Linux 4.10 introduced some format changes for oopses; one of the changes
was removing memory addresses from each stack frame.
This commit adds support for the new format and retains compatibility
for the previous format (4.9 and earlier).
Signed-off-by: Patrick McCarty <patrick.mccarty@intel.com>
The former skip_spaces() function only skipped a single space, so rename
it to skip_space(), and make skip_spaces() greedily consume spaces.
Signed-off-by: Patrick McCarty <patrick.mccarty@intel.com>
There are some filters in place that prevent probes from collecting
specific types of data. In particular, the oops probe will report "zero"
or "non-zero" for register values in oopses instead of the actual
values. And the crash probe does not send backtraces if binaries live
outside of /usr or under /usr/local.
This commit keeps these filters in place but offers the capability to
disable the filters by creating a file named
/etc/telemetrics/opt-in-no-privacy-filters
Any future telemetry privacy filters can check for this file to alter
the reporting level.
Signed-off-by: Patrick McCarty <patrick.mccarty@intel.com>
When frame addresses detected during the stack scan were not previously
found by unwinding, the string "? " is added as a prefix to the function
name.
However, the current oops parsing code strips "? " if encountered, so
the backtraces from kernel oopses are missing vital information; the
presence of "? " provides a hint for debugging a stack trace and
indicates that the frame info is "unreliable".
This commit removes the "? " strip code, ensuring the prefix is retained
by the function name, and updates unit tests that check for oops lines
that should contain the prefix.
Signed-off-by: Patrick McCarty <patrick.mccarty@intel.com>