]> www.infradead.org Git - users/dwmw2/linux.git/commit
selftests/bpf: Increase verifier log limit in veristat
authorMykyta Yatsenko <yatsenko@meta.com>
Wed, 23 Oct 2024 15:53:14 +0000 (16:53 +0100)
committerAndrii Nakryiko <andrii@kernel.org>
Wed, 23 Oct 2024 17:48:14 +0000 (10:48 -0700)
commit1f7c33630724dfe47f99748bd2a9a56ec8bd337f
tree02c46f271696c26d9671fe98f247bb9521a23be3
parentefe7921927dc01cffdaff623ef51609e1be5058a
selftests/bpf: Increase verifier log limit in veristat

The current default buffer size of 16MB allocated by veristat is no
longer sufficient to hold the verifier logs of some production BPF
programs. To address this issue, we need to increase the verifier log
limit.
Commit 7a9f5c65abcc ("bpf: increase verifier log limit") has already
increased the supported buffer size by the kernel, but veristat users
need to explicitly pass a log size argument to use the bigger log.

This patch adds a function to detect the maximum verifier log size
supported by the kernel and uses that by default in veristat.
This ensures that veristat can handle larger verifier logs without
requiring users to manually specify the log size.

Signed-off-by: Mykyta Yatsenko <yatsenko@meta.com>
Signed-off-by: Andrii Nakryiko <andrii@kernel.org>
Link: https://lore.kernel.org/bpf/20241023155314.126255-1-mykyta.yatsenko5@gmail.com
tools/testing/selftests/bpf/veristat.c