Skip to content

Commit

Permalink
change loading btf warning log to debugging level
Browse files Browse the repository at this point in the history
Signed-off-by: Shuyi Cheng <chengshuyi@linux.alibaba.com>
  • Loading branch information
chengshuyi committed Dec 5, 2023
1 parent 43214c5 commit 667dbb3
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
4 changes: 2 additions & 2 deletions third/libbpf/src/btf.c
Original file line number Diff line number Diff line change
Expand Up @@ -1161,9 +1161,9 @@ int btf__load_into_kernel(struct btf *btf)
}

err = -errno;
pr_warn("Error loading BTF: %s(%d)\n", strerror(errno), errno);
pr_debug("Error loading BTF: %s(%d)\n", strerror(errno), errno);
if (*log_buf)
pr_warn("%s\n", log_buf);
pr_debug("%s\n", log_buf);
goto done;
}

Expand Down
2 changes: 1 addition & 1 deletion third/libbpf/src/libbpf.c
Original file line number Diff line number Diff line change
Expand Up @@ -3022,7 +3022,7 @@ static int bpf_object__sanitize_and_load_btf(struct bpf_object *obj)
report:
if (err) {
btf_mandatory = kernel_needs_btf(obj);
pr_warn("Error loading .BTF into kernel: %d. %s\n", err,
pr_debug("Error loading .BTF into kernel: %d. %s\n", err,
btf_mandatory ? "BTF is mandatory, can't proceed."
: "BTF is optional, ignoring.");
if (!btf_mandatory)
Expand Down

0 comments on commit 667dbb3

Please sign in to comment.