dutil: Move DW_TAG_LLVM_annotation definition to dutil.h

Move DW_TAG_LLVM_annotation definition from dwarf_load.c to dutil.h as
it will be used later for btf_encoder.c.  There is no functionality
change for this patch.

Signed-off-by: Yonghong Song <yhs@fb.com>
Acked-by: Andrii Nakryiko <andrii@kernel.org>
Cc: Alexei Starovoitov <ast@kernel.org>
Cc: Daniel Borkmann <daniel@iogearbox.net>
Cc: bpf@vger.kernel.org
Cc: dwarves@vger.kernel.org
Cc: kernel-team@fb.com
Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
This commit is contained in:
Yonghong Song 2021-11-17 12:22:24 -08:00 committed by Arnaldo Carvalho de Melo
parent 76401e9e46
commit a0cc68687f
2 changed files with 4 additions and 4 deletions

View File

@ -31,6 +31,10 @@
#define roundup(x,y) ((((x) + ((y) - 1)) / (y)) * (y))
#ifndef DW_TAG_LLVM_annotation
#define DW_TAG_LLVM_annotation 0x6000
#endif
static inline __attribute__((const)) bool is_power_of_2(unsigned long n)
{
return (n != 0 && ((n & (n - 1)) == 0));

View File

@ -52,10 +52,6 @@
#define DW_OP_addrx 0xa1
#endif
#ifndef DW_TAG_LLVM_annotation
#define DW_TAG_LLVM_annotation 0x6000
#endif
static pthread_mutex_t libdw__lock = PTHREAD_MUTEX_INITIALIZER;
static uint32_t hashtags__bits = 12;