[PATCH bpf-next 2/2] selftests/bpf: Use at least 10 args in stack argument tests

Yonghong Song yonghong.song at linux.dev
Thu May 28 13:55:43 PDT 2026



On 5/28/26 9:17 AM, Puranjay Mohan wrote:
> On arm64, the first 8 arguments are passed in registers (x0-x7), so
> tests with 8 or fewer arguments never exercise the native stack argument
> path in the JIT. Increase argument counts to at least 10 across all
> BPF-to-BPF subprog and kfunc stack argument tests so that at least 2
> arguments land on the arm64 stack.
>
> For the two-callees test, bump foo1 from 8 to 10 and foo2 from 10 to 12
> args to preserve the different-stack-depth flavor of the test.
>
> The bpf_kfunc_call_stack_arg_mem kfunc is left unchanged at 7 args to
> avoid breaking the precision backtracking test which relies on hardcoded
> verifier log instruction indices.
>
> Suggested-by: Will Deacon <will at kernel.org>
> Signed-off-by: Puranjay Mohan <puranjay at kernel.org>

Acked-by: Yonghong Song <yonghong.song at linux.dev>




More information about the linux-arm-kernel mailing list