BPF List
 help / color / mirror / Atom feed
From: "Alexis Lothoré" <alexis.lothore@bootlin.com>
To: Martin KaFai Lau <martin.lau@linux.dev>,
	Lorenzo Bianconi <lorenzo@kernel.org>
Cc: Alexei Starovoitov <ast@kernel.org>,
	Daniel Borkmann <daniel@iogearbox.net>,
	Andrii Nakryiko <andrii@kernel.org>,
	Jakub Kicinski <kuba@kernel.org>,
	Eduard Zingerman <eddyz87@gmail.com>, Song Liu <song@kernel.org>,
	Yonghong Song <yonghong.song@linux.dev>,
	John Fastabend <john.fastabend@gmail.com>,
	KP Singh <kpsingh@kernel.org>,
	Stanislav Fomichev <sdf@fomichev.me>, Hao Luo <haoluo@google.com>,
	Jiri Olsa <jolsa@kernel.org>, Mykola Lysenko <mykolal@fb.com>,
	Shuah Khan <shuah@kernel.org>,
	"David S. Miller" <davem@davemloft.net>,
	Jesper Dangaard Brouer <hawk@kernel.org>,
	Maxime Chevallier <maxime.chevallier@bootlin.com>,
	ebpf@linuxfoundation.org,
	Thomas Petazzoni <thomas.petazzoni@bootlin.com>,
	linux-kernel@vger.kernel.org, bpf@vger.kernel.org,
	linux-kselftest@vger.kernel.org, netdev@vger.kernel.org
Subject: Re: [PATCH bpf-next v2] selftests/bpf: convert test_xdp_features.sh to test_progs
Date: Thu, 26 Sep 2024 12:14:58 +0200	[thread overview]
Message-ID: <b4b2f589-19fd-4d22-abb7-545c7121fbba@bootlin.com> (raw)
In-Reply-To: <895a685b-7449-4bf1-b14d-00aee1d8f75b@linux.dev>

Hi Martin,

On 9/25/24 22:01, Martin KaFai Lau wrote:
> On 9/25/24 3:37 AM, Martin KaFai Lau wrote:
>> I am not sure which case in xdp_features.c does not have existing coverage in
>> test_progs. From a quick look, it seems only BPF_MAP_TYPE_CPUMAP is missing
>> (please check)?
> 
> Re: CPUMAP, I noticed there is a xdp_(cpu)map_attach.c test but it only does
> attach test. May be something similar can be done like
> https://lore.kernel.org/bpf/20240911-devel-koalo-fix-ingress-ifindex-v4-2-5c643ae10258@linutronix.de/ to exercise the xdp prog that does cpumap redirect.

Thanks for the guidance, I was not aware of the possibility to perform those
tests with BPF_PROG_RUN.
Indeed, the basic return values from XDP programs seem to be covered with this
method in other tests under prog_tests. For BPF_MAP_TYPE_CPUMAP, I can check and
try to apply the same logic as the series in progress you have pointed.

Once done, test_xdp_features.sh could be let as-is. Let me know if we should
stillmove it elsewhere instead of keeping it in selftests
(tools/bpf/xdp_features/ maybe ?)

And noted for the most relevant tests to convert after that, thanks :)

Alexis


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


  reply	other threads:[~2024-09-26 10:15 UTC|newest]

Thread overview: 13+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2024-09-10 18:10 [PATCH bpf-next v2] selftests/bpf: convert test_xdp_features.sh to test_progs Alexis Lothoré (eBPF Foundation)
2024-09-11 14:18 ` Simon Horman
2024-09-12 20:17   ` Alexis Lothoré
2024-09-13  7:26     ` Simon Horman
2024-09-13 22:22 ` Martin KaFai Lau
2024-09-14  9:25   ` Lorenzo Bianconi
2024-09-14 13:38     ` Jakub Kicinski
2024-09-22 10:04       ` Alexis Lothoré
2024-09-25  1:37         ` Martin KaFai Lau
2024-09-25 20:01           ` Martin KaFai Lau
2024-09-26 10:14             ` Alexis Lothoré [this message]
2024-10-04  4:44           ` Martin KaFai Lau
2024-10-04  6:23             ` Alexis Lothoré

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=b4b2f589-19fd-4d22-abb7-545c7121fbba@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=davem@davemloft.net \
    --cc=ebpf@linuxfoundation.org \
    --cc=eddyz87@gmail.com \
    --cc=haoluo@google.com \
    --cc=hawk@kernel.org \
    --cc=john.fastabend@gmail.com \
    --cc=jolsa@kernel.org \
    --cc=kpsingh@kernel.org \
    --cc=kuba@kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-kselftest@vger.kernel.org \
    --cc=lorenzo@kernel.org \
    --cc=martin.lau@linux.dev \
    --cc=maxime.chevallier@bootlin.com \
    --cc=mykolal@fb.com \
    --cc=netdev@vger.kernel.org \
    --cc=sdf@fomichev.me \
    --cc=shuah@kernel.org \
    --cc=song@kernel.org \
    --cc=thomas.petazzoni@bootlin.com \
    --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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox