remarkable-linux/drivers/vhost
Asias He 4f7f46d32c tcm_vhost: Use vq->private_data to indicate if the endpoint is setup
Currently, vs->vs_endpoint is used indicate if the endpoint is setup or
not. It is set or cleared in vhost_scsi_set_endpoint() or
vhost_scsi_clear_endpoint() under the vs->dev.mutex lock. However, when
we check it in vhost_scsi_handle_vq(), we ignored the lock.

Instead of using the vs->vs_endpoint and the vs->dev.mutex lock to
indicate the status of the endpoint, we use per virtqueue
vq->private_data to indicate it. In this way, we can only take the
vq->mutex lock which is per queue and make the concurrent multiqueue
process having less lock contention. Further, in the read side of
vq->private_data, we can even do not take the lock if it is accessed in
the vhost worker thread, because it is protected by "vhost rcu".

(nab: Do s/VHOST_FEATURES/~VHOST_SCSI_FEATURES)

Signed-off-by: Asias He <asias@redhat.com>
Acked-by: Michael S. Tsirkin <mst@redhat.com>
Signed-off-by: Nicholas Bellinger <nab@linux-iscsi.org>
2013-04-08 14:07:00 -07:00
..
Kconfig drivers/vhost: remove depends on CONFIG_EXPERIMENTAL 2013-01-21 14:52:45 -08:00
Kconfig.tcm drivers/vhost: remove depends on CONFIG_EXPERIMENTAL 2013-01-21 14:52:45 -08:00
Makefile tcm_vhost: Initial merge for vhost level target fabric driver 2012-07-29 13:49:10 -07:00
net.c vhost_net: handle polling errors when setting backend 2013-01-29 15:43:03 -05:00
tcm_vhost.c tcm_vhost: Use vq->private_data to indicate if the endpoint is setup 2013-04-08 14:07:00 -07:00
tcm_vhost.h tcm_vhost: Multi-queue support 2013-02-13 11:30:14 -08:00
test.c
test.h
vhost.c vhost_net: handle polling errors when setting backend 2013-01-29 15:43:03 -05:00
vhost.h vhost_net: handle polling errors when setting backend 2013-01-29 15:43:03 -05:00