diff options
author | Andrii Nakryiko <andrii@kernel.org> | 2023-11-17 19:46:16 -0800 |
---|---|---|
committer | Alexei Starovoitov <ast@kernel.org> | 2023-11-18 11:39:58 -0800 |
commit | db840d389bad60ce6f3aadc1079da13e7e993a16 (patch) | |
tree | e9a49caa3606ba2d29c27cc6fc891be2b1656187 /include/linux/bpf_verifier.h | |
parent | ff8867af01daa7ea770bebf5f91199b7434b74e5 (diff) | |
download | linux-db840d389bad60ce6f3aadc1079da13e7e993a16.tar.gz linux-db840d389bad60ce6f3aadc1079da13e7e993a16.tar.bz2 linux-db840d389bad60ce6f3aadc1079da13e7e993a16.zip |
bpf: move verbose_linfo() into kernel/bpf/log.c
verifier.c is huge. Let's try to move out parts that are logging-related
into log.c, as we previously did with bpf_log() and other related stuff.
This patch moves line info verbose output routines: it's pretty
self-contained and isolated code, so there is no problem with this.
Acked-by: Eduard Zingerman <eddyz87@gmail.com>
Acked-by: Stanislav Fomichev <sdf@google.com>
Signed-off-by: Andrii Nakryiko <andrii@kernel.org>
Link: https://lore.kernel.org/r/20231118034623.3320920-2-andrii@kernel.org
Signed-off-by: Alexei Starovoitov <ast@kernel.org>
Diffstat (limited to 'include/linux/bpf_verifier.h')
-rw-r--r-- | include/linux/bpf_verifier.h | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/include/linux/bpf_verifier.h b/include/linux/bpf_verifier.h index 52a4012b8255..d896f3db6a22 100644 --- a/include/linux/bpf_verifier.h +++ b/include/linux/bpf_verifier.h @@ -680,6 +680,10 @@ int bpf_vlog_init(struct bpf_verifier_log *log, u32 log_level, void bpf_vlog_reset(struct bpf_verifier_log *log, u64 new_pos); int bpf_vlog_finalize(struct bpf_verifier_log *log, u32 *log_size_actual); +__printf(3, 4) void verbose_linfo(struct bpf_verifier_env *env, + u32 insn_off, + const char *prefix_fmt, ...); + static inline struct bpf_func_state *cur_func(struct bpf_verifier_env *env) { struct bpf_verifier_state *cur = env->cur_state; |