From: Miklos Szeredi <miklos@szeredi.hu>
To: lepton <ytht.net@gmail.com>
Cc: linux-fsdevel@vger.kernel.org
Subject: Re: [PATCH] fuse: Add filesystem attribute in sysfs control dir.
Date: Wed, 31 Aug 2022 15:12:39 +0200 [thread overview]
Message-ID: <CAJfpegvZMS=P82E2t_BLOhxbiwLZNyFH1U1moAdHEjgU89wT_w@mail.gmail.com> (raw)
In-Reply-To: <CALqoU4wtPnMPqWZF=DjHApZRA58Vruwa3X3sQxR9UkugZJOgwg@mail.gmail.com>
On Wed, 24 Aug 2022 at 21:00, lepton <ytht.net@gmail.com> wrote:
>
> On Mon, Aug 22, 2022 at 6:37 AM Miklos Szeredi <miklos@szeredi.hu> wrote:
> >
> > On Wed, 29 Jul 2020 at 01:45, Lepton Wu <ytht.net@gmail.com> wrote:
> > >
> > > With this, user space can have more control to just abort some kind of
> > > fuse connections. Currently, in Android, it will write to abort file
> > > to abort all fuse connections while in some cases, we'd like to keep
> > > some fuse connections. This can help that.
> >
> > You can grep the same info from /proc/self/mountinfo. Why does that not work?
> Hi Miklos, thanks for this hint. That will work. But the code in user
> space will be more complicated and not straightforward.
> For now, I can see 2 issues with mountinfo:
> 1. one connection could have multiple entries under
> /proc/self/mountinfo if there are bind mounts, user space code needs
> to handle that.
Using the first match should be okay, bind mounts will have the same
filesystem type.
> 2. /proc/self/mountinfo is limited by namespace, so in theory, some
> connection under /sys/fs/fuse/connections could be missed in it.
True. OTOH this could be a security issue as well, since the point of
namespaces is to hide information.
> While this isn't an issue
> for the current android code, maybe it could get broken in the future.
>
> Overall, I am feeling my kernel patch is a straightforward and simple
> solution and it's just one more attribute under
> /sys/fs/fuse/connections, may I know if there are any downsides to
> doing this?
Your patch adds an ad-hoc interface for a very specific purpose with
likely no other users. As long as this information can be gotten in
other ways there's no compelling reason to add a new interface.
Thanks,
Miklos
prev parent reply other threads:[~2022-08-31 13:12 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2020-07-28 23:45 [PATCH] fuse: Add filesystem attribute in sysfs control dir Lepton Wu
2022-08-15 22:54 ` lepton
2022-08-22 13:36 ` Miklos Szeredi
2022-08-24 19:00 ` lepton
2022-08-31 13:12 ` Miklos Szeredi [this message]
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to='CAJfpegvZMS=P82E2t_BLOhxbiwLZNyFH1U1moAdHEjgU89wT_w@mail.gmail.com' \
--to=miklos@szeredi.hu \
--cc=linux-fsdevel@vger.kernel.org \
--cc=ytht.net@gmail.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
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).