mirror of
https://github.com/AuxXxilium/linux_dsm_epyc7002.git
synced 2024-12-22 19:03:28 +07:00
6f1ae8b662
Currently, the libbpf API function libbpf_set_print() takes three function pointer parameters for warning, info and debug printout respectively. This patch changes the API to have just one function pointer parameter and the function pointer has one additional parameter "debugging level". So if in the future, if the debug level is increased, the function signature won't change. Signed-off-by: Yonghong Song <yhs@fb.com> Signed-off-by: Alexei Starovoitov <ast@kernel.org>
19 lines
343 B
C++
19 lines
343 B
C++
/* SPDX-License-Identifier: (LGPL-2.1 OR BSD-2-Clause) */
|
|
#include "libbpf.h"
|
|
#include "bpf.h"
|
|
#include "btf.h"
|
|
|
|
/* do nothing, just make sure we can link successfully */
|
|
|
|
int main(int argc, char *argv[])
|
|
{
|
|
/* libbpf.h */
|
|
libbpf_set_print(NULL);
|
|
|
|
/* bpf.h */
|
|
bpf_prog_get_fd_by_id(0);
|
|
|
|
/* btf.h */
|
|
btf__new(NULL, 0);
|
|
}
|