From: stsp <stsp2@yandex.ru>
To: Arseny Krasnov <arseny.krasnov@kaspersky.com>,
Stefan Hajnoczi <stefanha@redhat.com>,
Stefano Garzarella <sgarzare@redhat.com>,
"Michael S. Tsirkin" <mst@redhat.com>,
Jason Wang <jasowang@redhat.com>,
"David S. Miller" <davem@davemloft.net>,
Jakub Kicinski <kuba@kernel.org>,
Colin Ian King <colin.king@canonical.com>,
Jorgen Hansen <jhansen@vmware.com>,
Arseniy Krasnov <oxffffaa@gmail.com>,
Andra Paraschiv <andraprs@amazon.com>,
Jeff Vander Stoep <jeffv@google.com>
Cc: kvm@vger.kernel.org, virtualization@lists.linux-foundation.org,
netdev@vger.kernel.org, linux-kernel@vger.kernel.org
Subject: Re: [PATCH 0/5] virtio/vsock: introduce SOCK_SEQPACKET support.
Date: Mon, 4 Jan 2021 00:18:44 +0300 [thread overview]
Message-ID: <b93e36c7-fd0b-6c5c-f598-234520b9fe01@yandex.ru> (raw)
In-Reply-To: <20210103195454.1954169-1-arseny.krasnov@kaspersky.com>
Hi Arseny, thanks for your work on this!
I did a small review in a hope it helps.
Also it may be cool to have the driver feature
for that (so that the host can see if its supported).
But I guess this was already said by Michael. :)
03.01.2021 22:54, Arseny Krasnov пишет:
> As SOCK_SEQPACKET guarantees to save record boundaries, so to
> do it, new packet operation was added: it marks start of record (with
> record length in header). To send record, packet with start marker is
> sent first, then all data is transmitted as 'RW' packets. On receiver's
> side, length of record is known from packet with start record marker.
> Now as packets of one socket are not reordered neither on vsock nor on
> vhost transport layers, these marker allows to restore original record
> on receiver's side. When each 'RW' packet is inserted to rx queue of
> receiver, user is woken up, data is copied to user's buffer and credit
> update message is sent. If there is no user waiting for data, credit
> won't be updated and sender will wait. Also, if user's buffer is full,
> and record is bigger, all unneeded data will be dropped (with sending of
> credit update message).
> 'MSG_EOR' flag is implemented with special value of 'flags' field
> in packet header. When record is received with such flags, 'MSG_EOR' is
> set in 'recvmsg()' flags. 'MSG_TRUNC' flag is also supported.
> In this implementation maximum length of datagram is not limited
> as in stream socket.
>
> drivers/vhost/vsock.c | 6 +-
> include/linux/virtio_vsock.h | 7 +
> include/net/af_vsock.h | 4 +
> include/uapi/linux/virtio_vsock.h | 9 +
> net/vmw_vsock/af_vsock.c | 457 +++++++++++++++++++-----
> net/vmw_vsock/virtio_transport.c | 3 +
> net/vmw_vsock/virtio_transport_common.c | 323 ++++++++++++++---
> 7 files changed, 673 insertions(+), 136 deletions(-)
>
next prev parent reply other threads:[~2021-01-03 21:19 UTC|newest]
Thread overview: 16+ messages / expand[flat|nested] mbox.gz Atom feed top
2021-01-03 19:54 [PATCH 0/5] virtio/vsock: introduce SOCK_SEQPACKET support Arseny Krasnov
2021-01-03 19:57 ` [PATCH 1/5] vsock/virtio: support for SOCK_SEQPACKET socket Arseny Krasnov
2021-01-03 21:07 ` stsp
2021-01-06 19:24 ` Arseny Krasnov
2021-01-08 10:19 ` Stefano Garzarella
2021-01-03 20:03 ` [PATCH 2/5] vhost/vsock: " Arseny Krasnov
2021-01-03 20:03 ` [PATCH 3/5] af_vsock: send/receive loops for SOCK_SEQPACKET Arseny Krasnov
2021-01-03 20:49 ` stsp
2021-01-11 6:44 ` Arseny Krasnov
2021-01-03 20:04 ` [PATCH 4/5] af_vsock: add socket ops " Arseny Krasnov
2021-01-03 21:15 ` stsp
2021-01-06 19:29 ` Arseny Krasnov
2021-01-03 20:04 ` [PATCH 5/5] af_vsock: update comments for stream sockets Arseny Krasnov
2021-01-03 21:18 ` stsp [this message]
2021-01-06 19:33 ` [PATCH 0/5] virtio/vsock: introduce SOCK_SEQPACKET support Arseny Krasnov
2021-01-08 10:33 ` Stefano Garzarella
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=b93e36c7-fd0b-6c5c-f598-234520b9fe01@yandex.ru \
--to=stsp2@yandex.ru \
--cc=andraprs@amazon.com \
--cc=arseny.krasnov@kaspersky.com \
--cc=colin.king@canonical.com \
--cc=davem@davemloft.net \
--cc=jasowang@redhat.com \
--cc=jeffv@google.com \
--cc=jhansen@vmware.com \
--cc=kuba@kernel.org \
--cc=kvm@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=mst@redhat.com \
--cc=netdev@vger.kernel.org \
--cc=oxffffaa@gmail.com \
--cc=sgarzare@redhat.com \
--cc=stefanha@redhat.com \
--cc=virtualization@lists.linux-foundation.org \
/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;
as well as URLs for NNTP newsgroup(s).