summaryrefslogtreecommitdiffstats
path: root/tools/perf/util/arm-spe-decoder
diff options
context:
space:
mode:
authorIlya Leoshkevich <iii@linux.ibm.com>2021-11-04 14:23:11 +0100
committerArnaldo Carvalho de Melo <acme@redhat.com>2021-11-07 16:27:38 +0100
commit4e88118c20fc5fa7890230da2d26f0235dd904f5 (patch)
treed29e1acd0c8976a23575cd859f842510d1261a12 /tools/perf/util/arm-spe-decoder
parentperf inject: Add vmlinux and ignore-vmlinux arguments (diff)
downloadlinux-4e88118c20fc5fa7890230da2d26f0235dd904f5.tar.xz
linux-4e88118c20fc5fa7890230da2d26f0235dd904f5.zip
perf tools: Use __BYTE_ORDER__
Switch from the libc-defined __BYTE_ORDER to the compiler-defined __BYTE_ORDER__ in order to make endianness detection more robust, like it was done for libbpf. Signed-off-by: Ilya Leoshkevich <iii@linux.ibm.com> Suggested-by: Arnaldo Carvalho de Melo <acme@redhat.com> Cc: Heiko Carstens <hca@linux.ibm.com> Cc: Thomas Richter <tmricht@linux.ibm.com> Cc: Vasily Gorbik <gor@linux.ibm.com> Link: https://lore.kernel.org/r/20211104132311.984703-1-iii@linux.ibm.com Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
Diffstat (limited to 'tools/perf/util/arm-spe-decoder')
-rw-r--r--tools/perf/util/arm-spe-decoder/arm-spe-pkt-decoder.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/tools/perf/util/arm-spe-decoder/arm-spe-pkt-decoder.c b/tools/perf/util/arm-spe-decoder/arm-spe-pkt-decoder.c
index 2e5eff4f8f03..2f311189c6e8 100644
--- a/tools/perf/util/arm-spe-decoder/arm-spe-pkt-decoder.c
+++ b/tools/perf/util/arm-spe-decoder/arm-spe-pkt-decoder.c
@@ -13,7 +13,7 @@
#include "arm-spe-pkt-decoder.h"
-#if __BYTE_ORDER == __BIG_ENDIAN
+#if __BYTE_ORDER__ == __ORDER_BIG_ENDIAN__
#define le16_to_cpu bswap_16
#define le32_to_cpu bswap_32
#define le64_to_cpu bswap_64