All of lore.kernel.org
 help / color / mirror / Atom feed
From: Matthieu Baerts <matttbe@kernel.org>
To: Geliang Tang <geliang@kernel.org>, Mat Martineau <martineau@kernel.org>
Cc: mptcp@lists.linux.dev
Subject: Re: [PATCH bpf-next v4 3/3] selftests/bpf: Support nonblock for send_recv_data
Date: Mon, 22 Apr 2024 12:31:26 +0200	[thread overview]
Message-ID: <0017e477-3fcd-45de-917b-b58b3781ca9b@kernel.org> (raw)
In-Reply-To: <7732f129e5c1c2ff128878be9b865115e1319b85.camel@kernel.org>

On 22/04/2024 12:04, Geliang Tang wrote:> On Mon, 2024-04-22 at 11:45
+0200, Matthieu Baerts wrote:

(...)

>> I might be wrong, but with MPTCP schedulers, it is different: with
>> non-blocking IO, EAGAIN can be seen, and this case needs to be
>> handled.
>> Actively waiting by retrying directly in the loop in case of EAGAIN
>> is
>> not recommended, but probably OK for the tests (still, might be good
>> to
>> add a comment to recommend polling instead). So here as well, such
>> modifications can stay in our tree for the moment.
>>
>> Also, what is not clear to me is where we set the socket as the
>> non-blocking one. Is it only done for MPTCP servers/clients?
> 
> I didn't set the socket as non-block in the end.
> 
> EAGAIN will be got no matter non-block flag is set or not.

That's strange, no? When the userspace sends data with a blocking IO
socket, it should not get EAGAIN, no?

> In old version like "[mptcp-next,v7,0/5] setsockopt per subflow: BPF":
> 
> https://patchwork.kernel.org/project/mptcp/cover/cover.1712571740.git.tanggeliang@kylinos.cn/
> 
> "set_nonblock" is added in patch 2, and invoked in run_subflow() in
> patch 3.

I see, but the commit message of patch 2 doesn't explain why
set_nonblock() is needed for MPTCP. I see it is used in patch 3, but is
it really necessary? Maybe it was added for other reasons, that are no
longer valid today?

>>> I added a issue #487 to trace this issue.

Please also note that we didn't have this issue for a while. When we had
it, it is when KVM was not supported on the CI:

 $ /opt/virtme/virtme-run (...)
 Could not access KVM kernel module: No such file or directory
 qemu-system-x86_64: failed to initialize kvm: No such file or directory
 qemu-system-x86_64: falling back to tcg


Maybe we had this issue because the VM was abnormally too slow, and we
reached the 3 seconds timeout described by Martin in a previous message?
If this is due to the "abnormally slow setup", maybe we don't need to do
anything?

In other words, can you (easily) reproduce the issue on your side? With
or without KVM support?

Cheers,
Matt
-- 
Sponsored by the NGI0 Core fund.


  reply	other threads:[~2024-04-22 10:31 UTC|newest]

Thread overview: 16+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2024-04-10  6:13 [PATCH bpf-next v4 0/3] export send_recv_data Geliang Tang
2024-04-10  6:13 ` [PATCH bpf-next v4 1/3] selftests/bpf: Add struct send_recv_arg Geliang Tang
2024-04-10  6:13 ` [PATCH bpf-next v4 2/3] selftests/bpf: Export send_recv_data helper Geliang Tang
2024-04-10 21:20   ` Martin KaFai Lau
2024-04-10  6:13 ` [PATCH bpf-next v4 3/3] selftests/bpf: Support nonblock for send_recv_data Geliang Tang
2024-04-10 21:34   ` Martin KaFai Lau
2024-04-11  6:52     ` Geliang Tang
2024-04-22  6:50       ` Geliang Tang
2024-04-22  9:45         ` Matthieu Baerts
2024-04-22 10:04           ` Geliang Tang
2024-04-22 10:31             ` Matthieu Baerts [this message]
2024-04-22 10:34               ` Geliang Tang
2024-04-22 10:39                 ` Matthieu Baerts
2024-04-23  2:58                   ` Geliang Tang
2024-05-07  4:04     ` Geliang Tang
2024-04-10 17:53 ` [PATCH bpf-next v4 0/3] export send_recv_data MPTCP CI

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=0017e477-3fcd-45de-917b-b58b3781ca9b@kernel.org \
    --to=matttbe@kernel.org \
    --cc=geliang@kernel.org \
    --cc=martineau@kernel.org \
    --cc=mptcp@lists.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.