aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/vhost/net.c
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/vhost/net.c')
-rw-r--r--drivers/vhost/net.c5
1 files changed, 3 insertions, 2 deletions
diff --git a/drivers/vhost/net.c b/drivers/vhost/net.c
index 4b4da5b86ff9..f442668a1e52 100644
--- a/drivers/vhost/net.c
+++ b/drivers/vhost/net.c
@@ -129,8 +129,9 @@ static void handle_tx(struct vhost_net *net)
129 size_t hdr_size; 129 size_t hdr_size;
130 struct socket *sock; 130 struct socket *sock;
131 131
132 sock = rcu_dereference_check(vq->private_data, 132 /* TODO: check that we are running from vhost_worker?
133 lockdep_is_held(&vq->mutex)); 133 * Not sure it's worth it, it's straight-forward enough. */
134 sock = rcu_dereference_check(vq->private_data, 1);
134 if (!sock) 135 if (!sock)
135 return; 136 return;
136 137