From: sashiko-bot@kernel.org
To: "Kang Chen" <k.chen@smail.nju.edu.cn>
Cc: bpf@vger.kernel.org, tj@kernel.org, hannes@cmpxchg.org, mkoutny@suse.com
Subject: Re: [PATCH bpf v2 2/2] selftests/bpf: Test that a drained css iterator keeps returning NULL
Date: Fri, 13 Nov 2026 02:51:47 +0000 [thread overview]
Message-ID: <sashiko-outbox-212098@kernel.org> (raw)
In-Reply-To: <20261113024453.922726-2-k.chen@smail.nju.edu.cn>
Thank you for your contribution! Sashiko AI review found 1 potential
issue to consider:
- [Low] selftests/bpf: standalone css_iter files duplicate existing
iters_css tests
--
commit 2e186e543b0b323cd0fe5abfcf3d4268a7d8d9cd
Author: Kang Chen <k.chen@smail.nju.edu.cn>
selftests/bpf: Test that a drained css iterator keeps returning NULL
This commit adds a BPF selftest verifying that calling bpf_iter_css_next()
on an already drained css iterator continues to return NULL.
> diff --git a/tools/testing/selftests/bpf/prog_tests/css_iter.c b/tools/testing/selftests/bpf/prog_tests/css_iter.c
> new file mode 100644
> index 0000000000000..9bf8f056d3cd0
> --- /dev/null
> +++ b/tools/testing/selftests/bpf/prog_tests/css_iter.c
> @@ -0,0 +1,35 @@
> +// SPDX-License-Identifier: GPL-2.0
> +#include <test_progs.h>
> +#include <bpf/libbpf.h>
> +#include "css_iter.skel.h"
[ ... ]
> +void test_css_iter(void)
> +{
> + if (test__start_subtest("next_after_drain"))
> + test_css_iter_next_after_drain();
> +}
[Severity: Low]
This isn't a bug, but could this test case be added to the existing css
iterator test suite in tools/testing/selftests/bpf/prog_tests/iters.c
(subtest_css_iters()) and tools/testing/selftests/bpf/progs/iters_css.c
instead of introducing new standalone files? iters_css.c already exercises
bpf_iter_css_new(), bpf_iter_css_next(), and bpf_iter_css_destroy() with
the same ksym declarations and cgroup/RCU setup.
--
Sashiko AI review · https://sashiko.dev/#/patchset/20261113024453.922726-1-k.chen@smail.nju.edu.cn?part=2
prev parent reply other threads:[~2026-11-13 2:51 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-11-10 12:51 [PATCH] bpf: make css iterator stay drained after NULL Kang Chen
2026-11-10 19:40 ` Tejun Heo
2026-11-13 2:44 ` [PATCH bpf v2 1/2] " Kang Chen
2026-11-13 2:44 ` [PATCH bpf v2 2/2] selftests/bpf: Test that a drained css iterator keeps returning NULL Kang Chen
2026-11-13 2:51 ` sashiko-bot [this message]
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=sashiko-outbox-212098@kernel.org \
--to=sashiko-bot@kernel.org \
--cc=bpf@vger.kernel.org \
--cc=hannes@cmpxchg.org \
--cc=k.chen@smail.nju.edu.cn \
--cc=mkoutny@suse.com \
--cc=sashiko-reviews@lists.linux.dev \
--cc=tj@kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.