perf beauty: Add socket level scnprintf that handles ARCH specific SOL_SOCKET
authorArnaldo Carvalho de Melo <acme@redhat.com>
Tue, 9 Nov 2021 12:23:07 +0000 (09:23 -0300)
committerArnaldo Carvalho de Melo <acme@redhat.com>
Fri, 12 Nov 2021 13:40:34 +0000 (10:40 -0300)
commit66aee54ba42c72d594076f1de2d97fe0933836e8
treee2f369f29d41df8a95dcc95bd7eccb668e88f81e
parent0826b7fd0a0188d9f8388ff031dd0b3e3beb77a6
perf beauty: Add socket level scnprintf that handles ARCH specific SOL_SOCKET

SOL_SOCKET has a different value according to the architecture, some
have it as 0xffff while all the others have it as 1, so a simple string
array isn't usable, add a scnprintf routine that treats it as a special
case, using the array for other values.

Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
tools/perf/trace/beauty/beauty.h
tools/perf/trace/beauty/socket.c