From: Josh Poimboeuf Date: Mon, 18 Apr 2022 16:50:28 +0000 (-0700) Subject: objtool: Don't print parentheses in function addresses X-Git-Url: http://git.maquefel.me/?a=commitdiff_plain;h=2bc3dec7055e34c2c2e497f109da6748544c0791;p=linux.git objtool: Don't print parentheses in function addresses The parentheses in the "func()+off" address output are inconsistent with how the kernel prints function addresses, breaking Peter's scripts. Remove them. Suggested-by: Peter Zijlstra Signed-off-by: Josh Poimboeuf Signed-off-by: Peter Zijlstra (Intel) Reviewed-by: Miroslav Benes Link: https://lkml.kernel.org/r/f2bec70312f62ef4f1ea21c134d9def627182ad3.1650300597.git.jpoimboe@redhat.com --- diff --git a/tools/objtool/include/objtool/warn.h b/tools/objtool/include/objtool/warn.h index 802cfda0a6f63..c4bde3e2a79c2 100644 --- a/tools/objtool/include/objtool/warn.h +++ b/tools/objtool/include/objtool/warn.h @@ -33,11 +33,7 @@ static inline char *offstr(struct section *sec, unsigned long offset) } str = malloc(strlen(name) + 20); - - if (func) - sprintf(str, "%s()+0x%lx", name, name_off); - else - sprintf(str, "%s+0x%lx", name, name_off); + sprintf(str, "%s+0x%lx", name, name_off); return str; }