Skip to content

vsock: backport latest commits for RHEL-9.4

Merge Request Required Information

Summary of Changes

This is a set of vsock patches we have in Linux 6.7-rc3 that we are backporting into RHEL-9.4.

This MR contains several fixes (and tests) plus some new features for AF_VSOCK:

  • sockmap support
  • MSG_PEEK support for SOCK_SEQPACKET
  • MSG_ZEROCOPY support

Conflicts:

  • for sockmap support, recvmsg() still have noblock param since we don't have commit ec095263a965 ("net: remove noblock parameter from recvmsg() entities") downstream
  • iov_iter_init() calls still use READ/WRITE downstream
  • downstream only patch to fix issue with nitro enclaves (see !2863 (merged))
$ git backport-diff -u upstream-local/master -r main..HEAD
Key:
[----] : patches are identical
[####] : number of functional differences between upstream/downstream patch
[down] : patch is downstream-only
The flags [FC] indicate (F)unctional and (C)ontextual differences, respectively

001/37:[0011] [FC] 'vsock: support sockmap'
002/37:[----] [--] 'virtio/vsock: rework MSG_PEEK for SOCK_STREAM'
003/37:[----] [--] 'virtio/vsock: support MSG_PEEK for SOCK_SEQPACKET'
004/37:[----] [--] 'vsock/test: rework MSG_PEEK test for SOCK_STREAM'
005/37:[----] [--] 'vsock/test: MSG_PEEK test for SOCK_SEQPACKET'
006/37:[----] [--] 'vsock: Remove unused function declarations'
007/37:[----] [--] 'test/vsock: remove vsock_perf executable on `make clean`'
008/37:[----] [--] 'af_vsock: Remove unused declaration vsock_release_pending()/vsock_init_tap()'
009/37:[----] [--] 'vsock: send SIGPIPE on write to shutdowned socket'
010/37:[----] [--] 'test/vsock: shutdowned socket test'
011/37:[----] [--] 'vsock/test: add recv_buf() utility function'
012/37:[----] [--] 'vsock/test: use recv_buf() in vsock_test.c'
013/37:[----] [--] 'vsock/test: add send_buf() utility function'
014/37:[----] [--] 'vsock/test: use send_buf() in vsock_test.c'
015/37:[----] [--] 'vsock/test: track bytes in sk_buff merging test for SOCK_SEQPACKET'
016/37:[----] [-C] 'vsock/virtio/vhost: read data from non-linear skb'
017/37:[----] [--] 'vsock/virtio: support to send non-linear skb'
018/37:[----] [--] 'vsock/virtio: non-linear skb handling for tap'
019/37:[----] [--] 'vsock/virtio: MSG_ZEROCOPY flag support'
020/37:[----] [--] 'vsock: set EPOLLERR on non-empty error queue'
021/37:[----] [-C] 'vsock: read from socket's error queue'
022/37:[----] [--] 'vsock: check for MSG_ZEROCOPY support on send'
023/37:[----] [--] 'vsock: enable SOCK_SUPPORT_ZC bit'
024/37:[----] [--] 'vhost/vsock: support MSG_ZEROCOPY for transport'
025/37:[----] [--] 'vsock/virtio: support MSG_ZEROCOPY for transport'
026/37:[----] [--] 'vsock/loopback: support MSG_ZEROCOPY for transport'
027/37:[----] [--] 'vsock: enable setting SO_ZEROCOPY'
028/37:[----] [--] 'test/vsock: MSG_ZEROCOPY flag tests'
029/37:[----] [--] 'test/vsock: MSG_ZEROCOPY support for vsock_perf'
030/37:[----] [--] 'test/vsock: io_uring rx/tx tests'
031/37:[----] [-C] 'vsock/virtio: initialize the_virtio_vsock before using VQs'
032/37:[----] [--] 'vsock/virtio: remove socket from connected/bound list on shutdown'
033/37:[----] [--] 'test/vsock fix: add missing check on socket creation'
034/37:[----] [--] 'test/vsock: refactor vsock_accept'
035/37:[----] [--] 'test/vsock: add dobule bind connect test'
036/37:[----] [--] 'virtio/vsock: Fix uninit-value in virtio_transport_recv_pkt()'
037/37:[----] [--] 'vsock/test: fix SEQPACKET message bounds test'

Approved Development Ticket

All submissions to CentOS Stream must reference an approved ticket in Red Hat Jira. Please follow the CentOS Stream contribution documentation for how to file this ticket and have it approved.

JIRA: https://issues.redhat.com/browse/RHEL-17878

Signed-off-by: Stefano Garzarella sgarzare@redhat.com

Merge request reports