summaryrefslogtreecommitdiff
path: root/net/vmw_vsock/Kconfig
diff options
context:
space:
mode:
authorStefano Garzarella <sgarzare@redhat.com>2021-04-20 13:07:27 +0200
committerDavid S. Miller <davem@davemloft.net>2021-04-20 17:07:21 -0700
commit8432b8114957235f42e070a16118a7f750de9d39 (patch)
tree4bdc098a6897f572515e2d2aaa4481113058f9b6 /net/vmw_vsock/Kconfig
parenteeddfd8e8d392bc94968d87e7a408ba9e9be4722 (diff)
vsock/virtio: free queued packets when closing socket
As reported by syzbot [1], there is a memory leak while closing the socket. We partially solved this issue with commit ac03046ece2b ("vsock/virtio: free packets during the socket release"), but we forgot to drain the RX queue when the socket is definitely closed by the scheduled work. To avoid future issues, let's use the new virtio_transport_remove_sock() to drain the RX queue before removing the socket from the af_vsock lists calling vsock_remove_sock(). [1] https://syzkaller.appspot.com/bug?extid=24452624fc4c571eedd9 Fixes: ac03046ece2b ("vsock/virtio: free packets during the socket release") Reported-and-tested-by: syzbot+24452624fc4c571eedd9@syzkaller.appspotmail.com Signed-off-by: Stefano Garzarella <sgarzare@redhat.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'net/vmw_vsock/Kconfig')
0 files changed, 0 insertions, 0 deletions