linux-fsdevel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH 00/18] virtiofs: Fix various races and cleanups round 1
@ 2019-09-05 19:48 Vivek Goyal
  2019-09-05 19:48 ` [PATCH 01/18] virtiofs: Remove request from processing list before calling end Vivek Goyal
                   ` (19 more replies)
  0 siblings, 20 replies; 62+ messages in thread
From: Vivek Goyal @ 2019-09-05 19:48 UTC (permalink / raw)
  To: linux-fsdevel, virtualization, miklos
  Cc: linux-kernel, virtio-fs, vgoyal, stefanha, dgilbert, mst

Hi,

Michael Tsirkin pointed out issues w.r.t various locking related TODO
items and races w.r.t device removal. 

In this first round of cleanups, I have taken care of most pressing
issues.

These patches apply on top of following.

git://git.kernel.org/pub/scm/linux/kernel/git/mszeredi/fuse.git#virtiofs-v4

I have tested these patches with mount/umount and device removal using
qemu monitor. For example.

virsh qemu-monitor-command --hmp vm9-f28 device_del myvirtiofs

Now a mounted device can be removed and file system will return errors
-ENOTCONN and one can unmount it.

Miklos, if you are fine with the patches, I am fine if you fold these
all into existing patch. I kept them separate so that review is easier.

Any feedback or comments are welcome.

Thanks
Vivek


Vivek Goyal (18):
  virtiofs: Remove request from processing list before calling end
  virtiofs: Check whether hiprio queue is connected at submission time
  virtiofs: Pass fsvq instead of vq as parameter to
    virtio_fs_enqueue_req
  virtiofs: Check connected state for VQ_REQUEST queue as well
  Maintain count of in flight requests for VQ_REQUEST queue
  virtiofs: ->remove should not clean virtiofs fuse devices
  virtiofs: Stop virtiofs queues when device is being removed
  virtiofs: Drain all pending requests during ->remove time
  virtiofs: Add an helper to start all the queues
  virtiofs: Do not use device managed mem for virtio_fs and virtio_fs_vq
  virtiofs: stop and drain queues after sending DESTROY
  virtiofs: Use virtio_fs_free_devs() in error path
  virtiofs: Do not access virtqueue in request submission path
  virtiofs: Add a fuse_iqueue operation to put() reference
  virtiofs: Make virtio_fs object refcounted
  virtiofs: Use virtio_fs_mutex for races w.r.t ->remove and mount path
  virtiofs: Remove TODO to quiesce/end_requests
  virtiofs: Remove TODO item from virtio_fs_free_devs()

 fs/fuse/fuse_i.h    |   5 +
 fs/fuse/inode.c     |   6 +
 fs/fuse/virtio_fs.c | 259 ++++++++++++++++++++++++++++++++------------
 3 files changed, 198 insertions(+), 72 deletions(-)

-- 
2.20.1


^ permalink raw reply	[flat|nested] 62+ messages in thread

end of thread, other threads:[~2019-09-09 23:52 UTC | newest]

Thread overview: 62+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2019-09-05 19:48 [PATCH 00/18] virtiofs: Fix various races and cleanups round 1 Vivek Goyal
2019-09-05 19:48 ` [PATCH 01/18] virtiofs: Remove request from processing list before calling end Vivek Goyal
2019-09-06 10:40   ` Stefan Hajnoczi
2019-09-05 19:48 ` [PATCH 02/18] virtiofs: Check whether hiprio queue is connected at submission time Vivek Goyal
2019-09-06 10:43   ` Stefan Hajnoczi
2019-09-05 19:48 ` [PATCH 03/18] virtiofs: Pass fsvq instead of vq as parameter to virtio_fs_enqueue_req Vivek Goyal
2019-09-06 10:44   ` Stefan Hajnoczi
2019-09-05 19:48 ` [PATCH 04/18] virtiofs: Check connected state for VQ_REQUEST queue as well Vivek Goyal
2019-09-06 10:45   ` Stefan Hajnoczi
2019-09-05 19:48 ` [PATCH 05/18] Maintain count of in flight requests for VQ_REQUEST queue Vivek Goyal
2019-09-06 10:46   ` Stefan Hajnoczi
2019-09-05 19:48 ` [PATCH 06/18] virtiofs: ->remove should not clean virtiofs fuse devices Vivek Goyal
2019-09-06 10:47   ` Stefan Hajnoczi
2019-09-05 19:48 ` [PATCH 07/18] virtiofs: Stop virtiofs queues when device is being removed Vivek Goyal
2019-09-06 10:47   ` Stefan Hajnoczi
2019-09-05 19:48 ` [PATCH 08/18] virtiofs: Drain all pending requests during ->remove time Vivek Goyal
2019-09-06 10:52   ` Stefan Hajnoczi
2019-09-06 14:17     ` Vivek Goyal
2019-09-06 14:18       ` Michael S. Tsirkin
2019-09-09 16:10         ` Stefan Hajnoczi
2019-09-08 10:11   ` [Virtio-fs] " piaojun
2019-09-05 19:48 ` [PATCH 09/18] virtiofs: Add an helper to start all the queues Vivek Goyal
2019-09-06 10:54   ` Stefan Hajnoczi
2019-09-05 19:48 ` [PATCH 10/18] virtiofs: Do not use device managed mem for virtio_fs and virtio_fs_vq Vivek Goyal
2019-09-06 10:56   ` Stefan Hajnoczi
2019-09-05 19:48 ` [PATCH 11/18] virtiofs: stop and drain queues after sending DESTROY Vivek Goyal
2019-09-06 11:50   ` Stefan Hajnoczi
2019-09-05 19:48 ` [PATCH 12/18] virtiofs: Use virtio_fs_free_devs() in error path Vivek Goyal
2019-09-06 11:51   ` Stefan Hajnoczi
2019-09-05 19:48 ` [PATCH 13/18] virtiofs: Do not access virtqueue in request submission path Vivek Goyal
2019-09-06 11:52   ` Stefan Hajnoczi
2019-09-05 19:48 ` [PATCH 14/18] virtiofs: Add a fuse_iqueue operation to put() reference Vivek Goyal
2019-09-06 12:00   ` Stefan Hajnoczi
2019-09-06 13:35     ` Vivek Goyal
2019-09-05 19:48 ` [PATCH 15/18] virtiofs: Make virtio_fs object refcounted Vivek Goyal
2019-09-06 12:03   ` Stefan Hajnoczi
2019-09-06 13:50     ` Vivek Goyal
2019-09-09 16:12       ` Stefan Hajnoczi
2019-09-08 11:10   ` [Virtio-fs] " piaojun
2019-09-09 15:35     ` Vivek Goyal
2019-09-05 19:48 ` [PATCH 16/18] virtiofs: Use virtio_fs_mutex for races w.r.t ->remove and mount path Vivek Goyal
2019-09-06 12:05   ` Stefan Hajnoczi
2019-09-06 13:51     ` Vivek Goyal
2019-09-09 16:13       ` Stefan Hajnoczi
2019-09-08 11:19   ` [Virtio-fs] " piaojun
2019-09-05 19:48 ` [PATCH 17/18] virtiofs: Remove TODO to quiesce/end_requests Vivek Goyal
2019-09-06 12:06   ` Stefan Hajnoczi
2019-09-05 19:48 ` [PATCH 18/18] virtiofs: Remove TODO item from virtio_fs_free_devs() Vivek Goyal
2019-09-06 12:06   ` Stefan Hajnoczi
2019-09-06  8:15 ` [PATCH 00/18] virtiofs: Fix various races and cleanups round 1 Miklos Szeredi
2019-09-06 10:36   ` Stefan Hajnoczi
2019-09-06 11:52     ` Miklos Szeredi
2019-09-06 12:08       ` Vivek Goyal
2019-09-06 13:55         ` Miklos Szeredi
2019-09-06 13:57         ` Michael S. Tsirkin
2019-09-06 14:11           ` Miklos Szeredi
2019-09-06 14:17             ` Michael S. Tsirkin
2019-09-08 11:53       ` [Virtio-fs] " piaojun
2019-09-09 16:14         ` Stefan Hajnoczi
2019-09-09 16:18           ` Michael S. Tsirkin
2019-09-09 23:52           ` piaojun
2019-09-06 13:37 ` Michael S. Tsirkin

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).