vsock/virtio: fix skb overhead accounting to preserve full buf_alloc
Status from this message: This series was applied to netdev/net.git (main)
Get series with b4
b4 am [email protected]Versions newest first · linked by author and title
- v4 Latest2 patches 2 repliesApplied 2/2
- v32 patches 9 repliesSuperseded
- v21 patch 3 repliesSuperseded
Earlier versions · 1
| Version | Posted | Patches | Replies | Status |
|---|---|---|---|---|
| v1 | 1 patch | 9 replies | Superseded |
Changes in v4 from the cover letter
- Split the buf_alloc check to be sure the credit is still respected and to avoid overflow of buf_used [sashiko]
- call virtio_transport_do_close() and vsock_remove_sock() to properly close the connection and remove the socket from the connect table [sashiko]
Patches in v4 All 2 applied
| # | Subject and files | Size | Replies | Applied |
|---|---|---|---|---|
| 1/2 | vsock/virtio: reset connection on receiving queue overflownet/ | +15 | 0 replies | Applied |
| 2/2 | vsock/virtio: fix skb overhead accounting to preserve full buf_allocnet/ | +8 | 0 replies | Applied |
Reviews trailers per patch
No Reviewed-by, Acked-by or Tested-by trailers for v4 yet.
Cover letter [PATCH net v4 0/2] vsock/virtio: fix skb overhead accounting to preserve full buf_alloc
Patch 1 resets the connection when we can no longer queue packets, this prevents silent data loss, and both peers are notified.
Patch 2 increases the total budget to buf_alloc * 2 for payload plus skb overhead similar to how SO_RCVBUF is doubled to reserve space for sk_buff metadata. This preserves the full buf_alloc for payload under normal operation, while still bounding the skb queue growth.
In the future, we plan to improve how we handle the merging of packets to minimize overhead and avoid closing connections.
v4:
- Split the buf_alloc check to be sure the credit is still respected and to avoid overflow of buf_used [sashiko]
- call virtio_transport_do_close() and vsock_remove_sock() to properly close the connection and remove the socket from the connect table [sashiko]
v3: https://lore.kernel.org/netdev/[email protected]/
- Split in 2 patches [MST]
v2: https://lore.kernel.org/netdev/[email protected]/
- Close the connection when we can no longer queue new packets instead of losing data.
- No longer announce the reduced buf_alloc to avoid violating the spec. [MST]
v1: https://lore.kernel.org/netdev/[email protected]/
Stefano Garzarella (2):
vsock/virtio: reset connection on receiving queue overflow vsock/virtio: fix skb overhead accounting to preserve full buf_alloc
net/vmw_vsock/virtio_transport_common.c | 29 ++++++++++++++++++++----- 1 file changed, 23 insertions(+), 6 deletions(-)
Signature · 1 line
2.54.0