Re: [PATCH 3/5] fuse: move the passthrough-specific code back to passthrough.c

Amir Goldstein
2025-09-19T09:37:10Z

On Fri, Sep 19, 2025 at 9:34 AM Miklos Szeredi <miklos@szeredi.hu> wrote:
>
> On Thu, 18 Sept 2025 at 20:02, Darrick J. Wong <djwong@kernel.org> wrote:
> >
> > On Wed, Sep 17, 2025 at 04:47:19AM +0200, Amir Goldstein wrote:
>
> > > I think at this point in time FUSE_PASSTHROUGH and
> > > FUSE_IOMAP should be mutually exclusive and
> > > fuse_backing_ops could be set at fc level.
> > > If we want to move them for per fuse_backing later
> > > we can always do that when the use cases and tests arrive.
> >
> > With Miklos' ok I'll constrain fuse not to allow passthrough and iomap
> > files on the same filesystem, but as it is now there's no technical
> > reason to make it so that they can't coexist.
>
> Is there a good reason to add the restriction? If restricting it

I guess "good reason" is subjective.
I do not like to have never tested code, but it's your fs, so up to you.

> doesn't simplify anything or even makes it more complex, then I'd opt
> for leaving it more general, even if it doesn't seem to make sense.

I don't think either restricting or not is more complex.
It's just a matter of whether fuse_backing_ops are per fuse_backing
or per fuse_conn.

It may come handy to limit the number of backing ids per fuse_conn
so that can be negotiated on FUSE_INIT, but that is independent
on the question of mutually excluding the two features.

Thanks,
Amir.