linux/drivers/vhost
Jean-Philippe Brucker e3f787189e vhost: fix IOTLB locking
Commit 78139c94dc ("net: vhost: lock the vqs one by one") moved the vq
lock to improve scalability, but introduced a possible deadlock in
vhost-iotlb. vhost_iotlb_notify_vq() now takes vq->mutex while holding
the device's IOTLB spinlock. And on the vhost_iotlb_miss() path, the
spinlock is taken while holding vq->mutex.

Since calling vhost_poll_queue() doesn't require any lock, avoid the
deadlock by not taking vq->mutex.

Fixes: 78139c94dc ("net: vhost: lock the vqs one by one")
Acked-by: Jason Wang <jasowang@redhat.com>
Acked-by: Michael S. Tsirkin <mst@redhat.com>
Signed-off-by: Jean-Philippe Brucker <jean-philippe.brucker@arm.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
2018-12-03 15:52:30 -08:00
..
Kconfig vhost: allow vhost-scsi driver to be built-in 2018-08-22 01:01:32 +03:00
Kconfig.vringh vhost: split out vringh Kconfig 2016-08-02 16:54:28 +03:00
Makefile License cleanup: add SPDX GPL-2.0 license identifier to files with no license 2017-11-02 11:10:55 +01:00
net.c net: vhost: remove bad code line 2018-10-07 21:31:32 -07:00
scsi.c vhost/scsi: Use common handling code in request queue handler 2018-10-24 21:16:13 -04:00
test.c treewide: kmalloc() -> kmalloc_array() 2018-06-12 16:19:22 -07:00
test.h License cleanup: add SPDX GPL-2.0 license identifier to files with no license 2017-11-02 11:10:55 +01:00
vhost.c vhost: fix IOTLB locking 2018-12-03 15:52:30 -08:00
vhost.h vhost: switch to use new message format 2018-08-06 10:41:04 -07:00
vringh.c treewide: kmalloc() -> kmalloc_array() 2018-06-12 16:19:22 -07:00
vsock.c fw_cfg, vhost: features fixes 2018-04-06 19:21:41 -07:00