[Date Prev] | [Thread Prev] | [Thread Next] | [Date Next] -- [Date Index] | [Thread Index] | [List Home]
Subject: [RFC v3 6/7] Vhost-vsock: Avoid lockdep warning
From: Claudio Imbrenda <imbrenda@de.ibm.com> release the lock on the child socket before calling virtio_transport_send_response . Thid avoids complaints from lockdep, but I'm not sure it won't introduce race conditions. This patch should be considered more as a hint, unless someone more knowledgeable can confirm that it won't create problems. Signed-off-by: Claudio Imbrenda <imbrenda@de.ibm.com> --- net/vmw_vsock/virtio_transport_common.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/net/vmw_vsock/virtio_transport_common.c b/net/vmw_vsock/virtio_transport_common.c index 6698b61..ca42fa9 100644 --- a/net/vmw_vsock/virtio_transport_common.c +++ b/net/vmw_vsock/virtio_transport_common.c @@ -804,9 +804,10 @@ virtio_transport_recv_listen(struct sock *sk, struct virtio_vsock_pkt *pkt) vsock_insert_connected(vchild); vsock_enqueue_accept(sk, child); + release_sock(child); + virtio_transport_send_response(vchild, pkt); - release_sock(child); sk->sk_data_ready(sk); return 0; -- 1.9.1
[Date Prev] | [Thread Prev] | [Thread Next] | [Date Next] -- [Date Index] | [Thread Index] | [List Home]