Re: [PATCH bpf v3 2/2] selftests/bpf: Add regression test for kfunc implicit arg injection

From: bot+bpf-ci

Date: Tue Jun 02 2026 - 05:51:40 EST


> diff --git a/tools/testing/selftests/bpf/progs/struct_ops_assoc.c b/tools/testing/selftests/bpf/progs/struct_ops_assoc.c
> index 68842e3f936b..ed0084453d56 100644
> --- a/tools/testing/selftests/bpf/progs/struct_ops_assoc.c
> +++ b/tools/testing/selftests/bpf/progs/struct_ops_assoc.c
> @@ -103,3 +103,43 @@ SEC(".struct_ops.link")

[ ... ]

> +int test_err_inject;
> +
> +SEC("tp_btf/sys_enter")
> +int BPF_PROG(sys_enter_prog_test_aux_inject, struct pt_regs *regs, long id)
> +{

This was raised on v2 by Yonghong Song, and it looks like it may still be
open:

Not sure whether this patch makes sense or not. The CI has pahole 1.31
so the test will always succeed.

https://lore.kernel.org/bpf/9cc9ce47-c45e-4878-ad3a-6e6967399ab9@xxxxxxxxx/

The underlying bug only manifests with pahole 1.30, where module BTF is
inconsistent with vmlinux. Under CI's pahole 1.31 the injection always
works, so does this test pass whether or not the fix is present?

In v3 the only change was an added paragraph in the commit message
acknowledging the pahole 1.30 scenario cannot be reproduced under CI, and
no code change was made to gate the test on the bug. Yonghong has not
replied to v3.

Is there a way to make the test meaningfully exercise the regression rather
than always succeeding under the CI toolchain?

---
AI reviewed your patch. Please fix the bug or email reply why it's not a bug.
See: https://github.com/kernel-patches/vmtest/blob/master/ci/claude/README.md

CI run summary: https://github.com/kernel-patches/bpf/actions/runs/26810234837