diff options
| author | Dmitry Torokhov <dmitry.torokhov@gmail.com> | 2019-05-10 11:43:46 -0700 |
|---|---|---|
| committer | Dmitry Torokhov <dmitry.torokhov@gmail.com> | 2019-05-10 11:43:46 -0700 |
| commit | 2a267e7c41aa88215de2b542de797d03d16ecdfd (patch) | |
| tree | b949270835e304c8b60a40cde1b2c2e19c13b33a /scripts/decode_stacktrace.sh | |
| parent | Input: libps2 - mark expected switch fall-through (diff) | |
| parent | Linux 5.1 (diff) | |
| download | linux-2a267e7c41aa88215de2b542de797d03d16ecdfd.tar.gz linux-2a267e7c41aa88215de2b542de797d03d16ecdfd.zip | |
Merge tag 'v5.1' into next
Sync up with mainline to bring in the latest APIs.
Diffstat (limited to 'scripts/decode_stacktrace.sh')
| -rwxr-xr-x | scripts/decode_stacktrace.sh | 11 |
1 files changed, 9 insertions, 2 deletions
diff --git a/scripts/decode_stacktrace.sh b/scripts/decode_stacktrace.sh index 64220e36ce3b..bcdd45df3f51 100755 --- a/scripts/decode_stacktrace.sh +++ b/scripts/decode_stacktrace.sh @@ -37,6 +37,13 @@ parse_symbol() { symbol=${symbol#\(} symbol=${symbol%\)} + # Strip segment + local segment + if [[ $symbol == *:* ]] ; then + segment=${symbol%%:*}: + symbol=${symbol#*:} + fi + # Strip the symbol name so that we could look it up local name=${symbol%+*} @@ -78,13 +85,13 @@ parse_symbol() { fi # Strip out the base of the path - code=${code//$basepath/""} + code=${code//^$basepath/""} # In the case of inlines, move everything to same line code=${code//$'\n'/' '} # Replace old address with pretty line numbers - symbol="$name ($code)" + symbol="$segment$name ($code)" } decode_code() { |
