perf tools: Fix unwind build on i386
authorBen Hutchings <ben@decadent.org.uk>
Sat, 22 Jul 2017 16:37:33 +0000 (17:37 +0100)
committerSalvatore Bonaccorso <carnil@debian.org>
Fri, 9 Apr 2021 18:17:58 +0000 (19:17 +0100)
commitd668a2ee0dd549a4f0e3c4a2ff9f81e6798107e4
tree9bddb4bf4fb7db6cb9141a3eecb66fc63086fe41
parent32dc45b4dfbc309e49505fe47bb64a3bb232b707
perf tools: Fix unwind build on i386

Forwarded: no

EINVAL may not be defined when building unwind-libunwind.c with
REMOTE_UNWIND_LIBUNWIND, resulting in a compiler error in
LIBUNWIND__ARCH_REG_ID().  Its only caller, access_reg(), only checks
for a negative return value and doesn't care what it is.  So change
-EINVAL to -1.

Fixes: 52ffe0ff02fc ("Support x86(32-bit) cross platform callchain unwind.")
Signed-off-by: Ben Hutchings <ben@decadent.org.uk>
Gbp-Pq: Topic bugfix/x86
Gbp-Pq: Name perf-tools-fix-unwind-build-on-i386.patch
tools/perf/arch/x86/util/unwind-libunwind.c