Re: [PATCH 2/2] selftests/bpf: Skip bpffs debug iter checks when unavailable in test_bpffs
From: sun jian
Date: Wed Mar 11 2026 - 04:15:55 EST
On Tue, Mar 10, 2026 at 8:32 PM Viktor Malik <vmalik@xxxxxxxxxx> wrote:
>
> I don't think this is a good approach as it will mask genuine bugs that
> would cause the files to be missing/inaccessible with one of the above
> error codes.
>
Hi Viktor,
I don't think this change masks bugs in a silent way. It prints an explicit
INFO line when maps.debug/progs.debug are unavailable due to
EPERM/EACCES/ENOENT, and it still fails on other errors or unexpected
iterator output.
> If you really need to execute the rest of the test cases in the file,
> how about you split the test into subtests and then just add the failing
> subtest to your DENYLIST?
Proper subtests would require reworking the current fork-based flow to
report SKIP/FAIL to the harness, which would be a larger refactor than
intended here.
My goal is to keep this as a minimal change while still achieving the main
purpose of this test: exercising the core bpffs operations (pinning and
renameat2 semantics), which are independent of the debug iterator files,
and clearly reporting when the iterator checks couldn't be performed.
Regards,
Sun Jian