objtool: Fix ".cold" section suffix check for newer versions of GCC
authorJosh Poimboeuf <jpoimboe@redhat.com>
Thu, 21 Jan 2021 21:29:19 +0000 (15:29 -0600)
committerJosh Poimboeuf <jpoimboe@redhat.com>
Tue, 26 Jan 2021 17:11:59 +0000 (11:11 -0600)
commit34ca59e109bdf69704c33b8eeffaa4c9f71076e5
treea1e9d2a8bbb2873499f6dd86b5bc77f4fda3bd25
parent1f9a1b74942485a0a29e7c4a9a9f2fe8aea17766
objtool: Fix ".cold" section suffix check for newer versions of GCC

With my version of GCC 9.3.1 the ".cold" subfunctions no longer have a
numbered suffix, so the trailing period is no longer there.

Presumably this doesn't yet trigger a user-visible bug since most of the
subfunction detection logic is duplicated.   I only found it when
testing vmlinux.o validation.

Fixes: 54262aa28301 ("objtool: Fix sibling call detection")
Signed-off-by: Josh Poimboeuf <jpoimboe@redhat.com>
Link: https://lore.kernel.org/r/ca0b5a57f08a2fbb48538dd915cc253b5edabb40.1611263461.git.jpoimboe@redhat.com
tools/objtool/check.c