Re: [PATCH V9 4/4] fuse: Handle asynchronous read and write in passthrough

From: Alessio Balsini
Date: Thu Oct 22 2020 - 12:38:26 EST


On Wed, Sep 30, 2020 at 08:54:03PM +0200, Miklos Szeredi wrote:
> On Thu, Sep 24, 2020 at 3:13 PM Alessio Balsini <balsini@xxxxxxxxxxx> wrote:
> >
> > Extend the passthrough feature by handling asynchronous IO both for read
> > and write operations.
> >
> > When an AIO request is received, if the request targets a FUSE file with
> > the passthrough functionality enabled, a new identical AIO request is
> > created. The new request targets the lower file system file, and gets
> > assigned a special FUSE passthrough AIO completion callback.
> > When the lower file system AIO request is completed, the FUSE passthrough
> > AIO completion callback is executed and propagates the completion signal to
> > the FUSE AIO request by triggering its completion callback as well.
>
> This ends up with almost identical code in fuse and overlayfs, right?
> Maybe it's worth looking into moving these into common helpers.
>
> Thanks,
> Miklos
>

There are still a few differences between overlayfs and passthrough
read/write_iter(), so that merge wouldn't be straightforward. And I
would love to see this series merged before increasing its complexity,
hopefully in the next version if everything is all right.
I will anyway work on the cleanup patch you suggested right after FUSE
passthrough gets in, so that I have a solid code base to work on.

Would this work for you?

That cleanup patch would be handy also for the upcoming plan of having
something similar to FUSE passthrough extended to directories, as it was
mentioned in a previous discussion on this series with Amir.

Thanks!
Alessio