linux-fsdevel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Miklos Szeredi <miklos@szeredi.hu>
To: Jan Kara <jack@suse.cz>
Cc: Kent Overstreet <kent.overstreet@linux.dev>,
	Josef Bacik <josef@toxicpanda.com>,
	 linux-kernel@vger.kernel.org, linux-bcachefs@vger.kernel.org,
	 linux-fsdevel@vger.kernel.org,
	lsf-pc@lists.linux-foundation.org,  linux-btrfs@vger.kernel.org
Subject: Re: [Lsf-pc] [LSF TOPIC] statx extensions for subvol/snapshot filesystems & more
Date: Mon, 26 Feb 2024 09:27:17 +0100	[thread overview]
Message-ID: <CAJfpegvvuzXUDusbsJ1VO0CQf5iZO=TZ8kK7V3-k738oi5RM5w@mail.gmail.com> (raw)
In-Reply-To: <20240222160823.pclx6isoyaf7l64r@quack3>

On Thu, 22 Feb 2024 at 17:08, Jan Kara <jack@suse.cz> wrote:

> > If we are going to start fixing userspace, then we better make sure to
> > use the right interfaces, that won't have issues in the future.
>
> I agree we should give this a good thought which identification of a
> filesystem is the best.

To find mount boundaries statx.stx_mnt_id (especially with
STATX_MNT_ID_UNIQUE) is perfect.

By supplying stx_mnt_id to statmount(2) it's possible to get the
device number associated with that filesystem (statmount.sb_dev_*).  I
think it's what Josef wants btrfs to return as st_dev.

And statx could return that in stx_dev_*, with an interface feature
flag, same as we've done with stx_mnt_id.  I.e. STATX_DEV_NOHACK would
force the vfs to replace anything the filesystem put in kstat.dev with
sb->s_dev.

Thanks,
Miklos

  reply	other threads:[~2024-02-26  8:27 UTC|newest]

Thread overview: 19+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2024-02-21  0:51 [LSF TOPIC] statx extensions for subvol/snapshot filesystems & more Kent Overstreet
2024-02-21 15:06 ` Miklos Szeredi
2024-02-21 21:04   ` Kent Overstreet
2024-02-21 21:08   ` Josef Bacik
2024-02-22  9:14     ` Miklos Szeredi
2024-02-22  9:42       ` Kent Overstreet
2024-02-22 10:25         ` Miklos Szeredi
2024-02-22 11:19           ` Kent Overstreet
2024-02-22 11:01         ` [Lsf-pc] " Jan Kara
2024-02-22 11:27           ` Kent Overstreet
2024-02-22 11:44             ` Jan Kara
2024-02-22 11:55               ` Kent Overstreet
2024-02-22 13:10                 ` Miklos Szeredi
2024-02-22 12:48           ` Miklos Szeredi
2024-02-22 16:08             ` Jan Kara
2024-02-26  8:27               ` Miklos Szeredi [this message]
2024-02-26 16:24                 ` Amir Goldstein
2024-02-22 15:48       ` Josef Bacik
2024-02-26  8:14         ` Miklos Szeredi

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='CAJfpegvvuzXUDusbsJ1VO0CQf5iZO=TZ8kK7V3-k738oi5RM5w@mail.gmail.com' \
    --to=miklos@szeredi.hu \
    --cc=jack@suse.cz \
    --cc=josef@toxicpanda.com \
    --cc=kent.overstreet@linux.dev \
    --cc=linux-bcachefs@vger.kernel.org \
    --cc=linux-btrfs@vger.kernel.org \
    --cc=linux-fsdevel@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=lsf-pc@lists.linux-foundation.org \
    /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).