Skip to content
Commit 8daaf39f authored by Arseniy Krasnov's avatar Arseniy Krasnov Committed by David S. Miller
Browse files

virtio/vsock: don't drop skbuff on copy failure



This returns behaviour of SOCK_STREAM read as before skbuff usage. When
copying to user fails current skbuff won't be dropped, but returned to
sockets's queue. Technically instead of 'skb_dequeue()', 'skb_peek()' is
called and when skbuff becomes empty, it is removed from queue by
'__skb_unlink()'.

Fixes: 71dc9ec9 ("virtio/vsock: replace virtio_vsock_pkt with sk_buff")
Signed-off-by: default avatarArseniy Krasnov <AVKrasnov@sberdevices.ru>
Reviewed-by: default avatarStefano Garzarella <sgarzare@redhat.com>
Acked-by: default avatarBobby Eshleman <bobby.eshleman@bytedance.com>
Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
parent 6825e6b4
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment