linux-fsdevel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* Is fsmap supposed to use open or closed intervals?
@ 2024-10-22  1:47 Theodore Ts'o
  0 siblings, 0 replies; only message in thread
From: Theodore Ts'o @ 2024-10-22  1:47 UTC (permalink / raw)
  To: Linux Filesystem Development List, Ext4 Developers List,
	Darrick J. Wong

I was debugging ext4's failure with the new test generic/365, which
was testing the regressions fixed by commits 68415b349f3f ("xfs: Fix
the owner setting issue for rmap query in xfs fsmap") and ca6448aed4f1
("xfs: Fix missing interval for missing_owner in xfs fsmap").  It
appears that ext4 has a similar bug, but then when I started looking
at how XFS handles fsmap, it's a bit unclear whether the intervals
queried are supposed to be open, closed, or half-open.

Looking at how 6.11-rc4's xfs handles fsmap, these two results seem to
be a bit contradictory:

root@kvm-xfstests:~# xfs_io -i -c "fsmap -d 104 127" /vdd
        0: 254:48 [104..126]: free space 23

OK, so it looks like fsmap returns the half-open interval [104 127).

But then I tried this:

root@kvm-xfstests:~# xfs_io -i -c "fsmap -d 104 128" /vdd
        0: 254:48 [104..127]: free space 24
        1: 254:48 [128..191]: inodes 64

and the fact that this query returns the region between [128, 191] is
surprising.

Is this a bug?  Is it OK if we expand the interval and return more
blocks than what the application program queried?

Thanks,

						- Ted

^ permalink raw reply	[flat|nested] only message in thread

only message in thread, other threads:[~2024-10-22  1:48 UTC | newest]

Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2024-10-22  1:47 Is fsmap supposed to use open or closed intervals? Theodore Ts'o

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).