Linux Kernel Selftest development
 help / color / mirror / Atom feed
From: "Alexis Lothoré" <alexis.lothore@bootlin.com>
To: Daniel Borkmann <daniel@iogearbox.net>,
	Alexei Starovoitov <ast@kernel.org>,
	"David S. Miller" <davem@davemloft.net>,
	Jakub Kicinski <kuba@kernel.org>,
	Jesper Dangaard Brouer <hawk@kernel.org>,
	John Fastabend <john.fastabend@gmail.com>,
	Andrii Nakryiko <andrii@kernel.org>,
	Martin KaFai Lau <martin.lau@linux.dev>,
	Eduard Zingerman <eddyz87@gmail.com>, Song Liu <song@kernel.org>,
	Yonghong Song <yonghong.song@linux.dev>,
	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>, Simon Horman <horms@kernel.org>
Cc: ebpf@linuxfoundation.org, netdev@vger.kernel.org,
	bpf@vger.kernel.org, linux-kselftest@vger.kernel.org,
	linux-kernel@vger.kernel.org,
	Thomas Petazzoni <thomas.petazzoni@bootlin.com>
Subject: Re: [PATCH v3 2/2] selftests/bpf: integrate test_xdp_veth into test_progs
Date: Sun, 21 Jul 2024 21:25:05 +0200	[thread overview]
Message-ID: <a348aa4d-d2c2-48f5-a1ed-4f97ffd093d7@bootlin.com> (raw)
In-Reply-To: <3b1949b9-775a-8093-6a14-16dec843a446@iogearbox.net>

Hello Daniel,

On 7/19/24 17:14, Daniel Borkmann wrote:
> On 7/16/24 12:13 PM, Alexis Lothoré (eBPF Foundation) wrote:

[...]

>> +    nstoken = open_netns(config[index].namespace);
>> +    if (!ASSERT_OK_PTR(nstoken, "switch to remote veth namespace"))
>> +        return -1;
>> +    interface = if_nametoindex(config[index].remote_veth);
>> +    if (!ASSERT_NEQ(interface, 0, "non zero interface index"))
>> +        return -1;
> 
> Missing `close_netns(nstoken);` in error path here, otherwise looks reasonable
> to me.
Ah yes, good catch, thanks. v4 incoming with the corresponding fix.

Thanks,
Alexis

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


      reply	other threads:[~2024-07-21 19:25 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2024-07-16 10:13 [PATCH v3 0/2] selftests/bpf: convert test_xdp_veth to test_progs framework Alexis Lothoré (eBPF Foundation)
2024-07-16 10:13 ` [PATCH v3 1/2] selftests/bpf: update xdp_redirect_map prog sections for libbpf Alexis Lothoré (eBPF Foundation)
2024-07-16 10:13 ` [PATCH v3 2/2] selftests/bpf: integrate test_xdp_veth into test_progs Alexis Lothoré (eBPF Foundation)
2024-07-19 15:14   ` Daniel Borkmann
2024-07-21 19:25     ` 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=a348aa4d-d2c2-48f5-a1ed-4f97ffd093d7@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=horms@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=martin.lau@linux.dev \
    --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