From: Michal Luczaj <mhal@rbox.co>
To: "Bobby Eshleman" <bobbyeshleman@meta.com>,
"Stefano Garzarella" <sgarzare@redhat.com>,
"David S. Miller" <davem@davemloft.net>,
"Jakub Kicinski" <kuba@kernel.org>,
"Paolo Abeni" <pabeni@redhat.com>,
"Simon Horman" <horms@kernel.org>,
"Jonathan Corbet" <corbet@lwn.net>,
"Shuah Khan" <skhan@linuxfoundation.org>,
"Stefan Hajnoczi" <stefanha@redhat.com>,
"Michael S. Tsirkin" <mst@redhat.com>,
"Jason Wang" <jasowangio@gmail.com>,
"Xuan Zhuo" <xuanzhuo@linux.alibaba.com>,
"Eugenio Pérez" <eperezma@redhat.com>,
"Shuah Khan" <shuah@kernel.org>,
"Randy Dunlap" <rdunlap@infradead.org>,
"Donald Hunter" <donald.hunter@gmail.com>,
"Eric Dumazet" <edumazet@kernel.org>,
"George Zhang" <georgezhang@vmware.com>,
"Andy King" <acking@vmware.com>,
"Dmitry Torokhov" <dtor@vmware.com>,
"Willem de Bruijn" <willemb@google.com>
Cc: virtualization@lists.linux.dev, netdev@vger.kernel.org,
linux-kernel@vger.kernel.org, linux-doc@vger.kernel.org,
kvm@vger.kernel.org, linux-kselftest@vger.kernel.org,
sargun@sargun.me, jlinbox@meta.com,
Bobby Eshleman <bobbyeshleman@gmail.com>
Subject: Re: [PATCH net-next v8 5/7] vsock/virtio: support guest device network namespace
Date: Fri, 4 Dec 2026 20:06:36 +0100 [thread overview]
Message-ID: <170b397a-0ccb-43d0-9405-a496f873309d@rbox.co> (raw)
In-Reply-To: <20261130-vsock-guest-ns-v8-5-5fff852d325b@meta.com>
On 12/1/26 02:06, Bobby Eshleman wrote:
> bool virtio_transport_stream_allow(struct vsock_sock *vsk, u32 cid, u32 port)
> {
> - return vsock_net_mode_global(vsk);
> + return vsock_g2h_net_reachable(sock_net(sk_vsock(vsk)));
> }
> @@ -616,7 +619,7 @@ virtio_transport_seqpacket_allow(struct vsock_sock *vsk, u32 remote_cid)
> struct virtio_vsock *vsock;
> bool seqpacket_allow;
>
> - if (!vsock_net_mode_global(vsk))
> + if (!vsock_g2h_net_reachable(sock_net(sk_vsock(vsk))))
> return false;
I was comparing this with other transports and noticed
static bool vsock_loopback_stream_allow(struct vsock_sock *vsk, u32 cid,
u32 port)
{
return true;
}
static bool
vsock_loopback_seqpacket_allow(struct vsock_sock *vsk, u32 remote_cid)
{
return vsock_net_mode_global(vsk);
}
If I'm not mistaken, local-mode same-ns loopback stream is allowed, but
seqpacket is not. Just checking, was this the intention?
thanks,
Michal
next prev parent reply other threads:[~2026-12-04 19:07 UTC|newest]
Thread overview: 19+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-12-01 1:06 [PATCH net-next v8 0/7] vsock: assign the guest vsock device to a network namespace Bobby Eshleman
2026-12-01 1:06 ` [PATCH net-next v8 1/7] vsock: constify the transport in vsock_for_each_connected_socket() Bobby Eshleman
2026-12-01 1:06 ` [PATCH net-next v8 2/7] vsock: rename the vsock pernet operations Bobby Eshleman
2026-12-01 1:06 ` [PATCH net-next v8 3/7] vsock: pass the netns to ->has_remote_cid() Bobby Eshleman
2026-12-01 1:06 ` [PATCH net-next v8 4/7] vsock: add a netlink command to assign the g2h device to a netns Bobby Eshleman
2026-12-01 16:19 ` Michal Luczaj
2026-12-01 21:05 ` Bobby Eshleman
2026-12-02 19:26 ` Michal Luczaj
2026-12-02 19:07 ` netdev-bot+sashiko
2026-12-04 15:53 ` Bobby Eshleman
2026-12-01 1:06 ` [PATCH net-next v8 5/7] vsock/virtio: support guest device network namespace Bobby Eshleman
2026-12-02 19:07 ` netdev-bot+sashiko
2026-12-04 19:06 ` Michal Luczaj [this message]
2026-12-01 1:06 ` [PATCH net-next v8 6/7] selftests/vsock: test the guest vsock " Bobby Eshleman
2026-12-02 19:07 ` netdev-bot+sashiko
2026-12-01 1:06 ` [PATCH net-next v8 7/7] selftests/vsock: test the netns assign privilege checks Bobby Eshleman
2026-12-02 19:07 ` netdev-bot+sashiko
2026-12-02 18:15 ` [PATCH net-next v8 0/7] vsock: assign the guest vsock device to a network namespace Stefano Garzarella
2026-12-03 2:06 ` Bobby Eshleman
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=170b397a-0ccb-43d0-9405-a496f873309d@rbox.co \
--to=mhal@rbox.co \
--cc=acking@vmware.com \
--cc=bobbyeshleman@gmail.com \
--cc=bobbyeshleman@meta.com \
--cc=corbet@lwn.net \
--cc=davem@davemloft.net \
--cc=donald.hunter@gmail.com \
--cc=dtor@vmware.com \
--cc=edumazet@kernel.org \
--cc=eperezma@redhat.com \
--cc=georgezhang@vmware.com \
--cc=horms@kernel.org \
--cc=jasowangio@gmail.com \
--cc=jlinbox@meta.com \
--cc=kuba@kernel.org \
--cc=kvm@vger.kernel.org \
--cc=linux-doc@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-kselftest@vger.kernel.org \
--cc=mst@redhat.com \
--cc=netdev@vger.kernel.org \
--cc=pabeni@redhat.com \
--cc=rdunlap@infradead.org \
--cc=sargun@sargun.me \
--cc=sgarzare@redhat.com \
--cc=shuah@kernel.org \
--cc=skhan@linuxfoundation.org \
--cc=stefanha@redhat.com \
--cc=virtualization@lists.linux.dev \
--cc=willemb@google.com \
--cc=xuanzhuo@linux.alibaba.com \
/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