All of lore.kernel.org
 help / color / mirror / Atom feed
From: "Alexis Lothoré" <alexis.lothore@bootlin.com>
To: "Qiliang Yuan" <odys.yuan@gmail.com>,
	"Alexei Starovoitov" <ast@kernel.org>,
	"Daniel Borkmann" <daniel@iogearbox.net>,
	"Andrii Nakryiko" <andrii@kernel.org>,
	"Eduard Zingerman" <eddyz87@gmail.com>,
	"Kumar Kartikeya Dwivedi" <memxor@gmail.com>,
	"Martin KaFai Lau" <martin.lau@linux.dev>,
	"Song Liu" <song@kernel.org>,
	"Yonghong Song" <yonghong.song@linux.dev>,
	"Jiri Olsa" <jolsa@kernel.org>,
	"Emil Tsalapatis" <emil@etsalapatis.com>,
	"Ihor Solodrai" <ihor.solodrai@linux.dev>,
	"Shuah Khan" <shuah@kernel.org>,
	"Alexis Lothoré (eBPF Foundation)" <alexis.lothore@bootlin.com>
Cc: <bpf@vger.kernel.org>, <linux-kselftest@vger.kernel.org>,
	<linux-kernel@vger.kernel.org>
Subject: Re: [PATCH bpf-next] selftests/bpf: Run tc_edt serially
Date: Wed, 14 Oct 2026 10:55:40 +0200	[thread overview]
Message-ID: <DM4FOVA9PW2E.1WIY5HRJWA1QP@bootlin.com> (raw)
In-Reply-To: <20261009-selftests-bpf-tc-edt-serial-v1-1-f72e045f2465@gmail.com>

Hi Qiliang,

On Fri Oct 9, 2026 at 3:50 AM CEST, Qiliang Yuan wrote:
> tc_edt shapes the traffic of a TCP connection between two netns to
> 5Mbps with a BPF program, and checks that the rate it measures from the
> userspace sender and receiver is within 2% of the target.
>
> The measured time includes the time the sender and the receiver take to
> run. When test_progs runs other tests in parallel, the sender and the
> receiver compete with those for the CPUs, the transfer takes longer,
> and the measured rate falls outside of the 2% margin.
>
> Make tc_edt a serial test.
>
> Fixes: b0f82e7ab6fb ("selftests/bpf: integrate test_tc_edt into test_progs")
> Signed-off-by: Qiliang Yuan <odys.yuan@gmail.com>

I don't know how to feel about the proposed fix. As a test involving
bandwith measurement, I get that such things could happen, but:
- I did not see this failure in the recent CI runs (but I could have
  missed it)
- if you see it in your setup, how sure are we that it is due to high
  CPU usage ? I guess it is very likely, but worth asking
- any idea about how much we are missing the 2% margin ? If this is only
  by a little, I would rather increase the margin and keep the tests
  parallel, there's not much point being too restrictive on the target
  bandwith, if we get something close enough, this is a good proof that
  the BPF rate limiter is triggered and running correctly

Thanks,

Alexis
> ---
>  tools/testing/selftests/bpf/prog_tests/test_tc_edt.c | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/tools/testing/selftests/bpf/prog_tests/test_tc_edt.c b/tools/testing/selftests/bpf/prog_tests/test_tc_edt.c
> index 462512fb191f1..1e82d88c987a7 100644
> --- a/tools/testing/selftests/bpf/prog_tests/test_tc_edt.c
> +++ b/tools/testing/selftests/bpf/prog_tests/test_tc_edt.c
> @@ -127,7 +127,7 @@ static void run_test(void)
>  		  "rate error is lower than threshold");
>  }
>  
> -void test_tc_edt(void)
> +void serial_test_tc_edt(void)
>  {
>  	struct test_tc_edt *skel;
>  
>
> ---
> base-commit: e1d84a37cba984388988d2f1ddc84561413f0db2
> change-id: 20261009-selftests-bpf-tc-edt-serial-9c65af71f845
>
> Best regards,





-- 
Alexis Lothoré, Bootlin
Embedded Linux and Kernel engineering
https://bootlin.com


      reply	other threads:[~2026-10-14  8:55 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-10-09  1:50 [PATCH bpf-next] selftests/bpf: Run tc_edt serially Qiliang Yuan
2026-10-14  8:55 ` Alexis Lothoré [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=DM4FOVA9PW2E.1WIY5HRJWA1QP@bootlin.com \
    --to=alexis.lothore@bootlin.com \
    --cc=andrii@kernel.org \
    --cc=ast@kernel.org \
    --cc=bpf@vger.kernel.org \
    --cc=daniel@iogearbox.net \
    --cc=eddyz87@gmail.com \
    --cc=emil@etsalapatis.com \
    --cc=ihor.solodrai@linux.dev \
    --cc=jolsa@kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-kselftest@vger.kernel.org \
    --cc=martin.lau@linux.dev \
    --cc=memxor@gmail.com \
    --cc=odys.yuan@gmail.com \
    --cc=shuah@kernel.org \
    --cc=song@kernel.org \
    --cc=yonghong.song@linux.dev \
    /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.