lkml.org 
[lkml]   [2023]   [Aug]   [20]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
From
SubjectRe: [PATCH bpf-next v5] selftests/bpf: trace_helpers.c: optimize kallsyms cache
Date
Sorry Song, I did not state clear.

libbpf_ensure_mem() is declared in libbpf_internal.h, we want to use
libbpf_ensure_mem() in trace_helpers.c, Unforturnately, we could only include
the headers 'install_headers:' defined in tools/lib/bpf/Makefile, the
'install_headers:' target does not include libbpf_internal.h, like:

tools/testing/selftests/bpf/trace_helpers.c:17:10:
fatal error: libbpf_internal.h: No such file or directory
17 | #include "libbpf_internal.h"
| ^~~~~~~~~~~~~~~~~~~

tools/testing/selftests/bpf/trace_helpers.c:17:10:
fatal error: bpf/libbpf_internal.h: No such file or directory
17 | #include "bpf/libbpf_internal.h"
| ^~~~~~~~~~~~~~~~~~~~~~~

How about

1. dup-declare libbpf_ensure_mem() in trace_helpers.c
2. move libbpf_ensure_mem() declare into libbpf_common.h

Which one do you like best.

Best wishes,
Rong Tao

\
 
 \ /
  Last update: 2023-08-21 04:04    [W:0.066 / U:0.252 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site