aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/vhost/tcm_vhost.c
diff options
context:
space:
mode:
authorMichael S. Tsirkin <mst@redhat.com>2012-12-06 07:03:34 -0500
committerMichael S. Tsirkin <mst@redhat.com>2012-12-06 10:09:18 -0500
commit935cdee7ee159569b0aaa10bd9244660f6672b08 (patch)
tree366e06bee572c2578fcce51926a8ae25e04ce66d /drivers/vhost/tcm_vhost.c
parent4a7d6455b07845d92e025da222f11de519f90def (diff)
vhost: avoid backend flush on vring ops
vring changes already do a flush internally where appropriate, so we do not need a second flush. It's currently not very expensive but a follow-up patch makes flush more heavy-weight, so remove the extra flush here to avoid regressing performance if call or kick fds are changed on data path. Signed-off-by: Michael S. Tsirkin <mst@redhat.com>
Diffstat (limited to 'drivers/vhost/tcm_vhost.c')
-rw-r--r--drivers/vhost/tcm_vhost.c5
1 files changed, 4 insertions, 1 deletions
diff --git a/drivers/vhost/tcm_vhost.c b/drivers/vhost/tcm_vhost.c
index ef8884482439..33e5f90dfcf5 100644
--- a/drivers/vhost/tcm_vhost.c
+++ b/drivers/vhost/tcm_vhost.c
@@ -970,7 +970,10 @@ static long vhost_scsi_ioctl(struct file *f, unsigned int ioctl,
970 return vhost_scsi_set_features(vs, features); 970 return vhost_scsi_set_features(vs, features);
971 default: 971 default:
972 mutex_lock(&vs->dev.mutex); 972 mutex_lock(&vs->dev.mutex);
973 r = vhost_dev_ioctl(&vs->dev, ioctl, arg); 973 r = vhost_dev_ioctl(&vs->dev, ioctl, argp);
974 /* TODO: flush backend after dev ioctl. */
975 if (r == -ENOIOCTLCMD)
976 r = vhost_vring_ioctl(&vs->dev, ioctl, argp);
974 mutex_unlock(&vs->dev.mutex); 977 mutex_unlock(&vs->dev.mutex);
975 return r; 978 return r;
976 } 979 }