All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH] overlay/071: Don't compare inode numbers in lower overlay and nested overlay
@ 2020-10-03  3:37 Xiao Yang
  2020-10-03  9:57 ` Amir Goldstein
  0 siblings, 1 reply; 2+ messages in thread
From: Xiao Yang @ 2020-10-03  3:37 UTC (permalink / raw)
  To: fstests; +Cc: amir73il, Xiao Yang

1) If underlying filesystem is ext4, the lower overlay inodes do not
   have the MSB set (e.g. file ino 8590721028 = 0x2000C0004) because
   ext4 has a known inode number limit of 32bit (see ovl_can_decode_fh).
2) With nested xino feature, the nested overlay inodes have the MSB set
   (e.g. file ino 9223372045445496836  = 0x80000002000C0004).
It is expected different inode numbers which casue the failure of
overlay/071, so fix this failure by removing the unneeded comparision.

Suggested-by: Amir Goldstein <amir73il@gmail.com>
Signed-off-by: Xiao Yang <yangx.jy@cn.fujitsu.com>
---
 tests/overlay/071 | 6 +-----
 1 file changed, 1 insertion(+), 5 deletions(-)

diff --git a/tests/overlay/071 b/tests/overlay/071
index ac2324c8..90770936 100755
--- a/tests/overlay/071
+++ b/tests/overlay/071
@@ -194,12 +194,8 @@ mount_dirs
 record_inode_numbers $SCRATCH_MNT/lowertestdir $tmp.lower.lo
 record_inode_numbers $SCRATCH_MNT/uppertestdir $tmp.lower.up
 
-# Compare inode numbers in lower overlay vs. nested overlay
-# With nested xino lower/lower, all inode numbers overflow xino bits and
-# d_ino/i_ino in nested overlay are the same as in lower overlay.
-check_inode_numbers $lowertestdir $tmp.lower.lo $tmp.before.lo
-
 # Record inode numbers before copy up from nested upper
+record_inode_numbers $lowertestdir $tmp.before.lo
 record_inode_numbers $uppertestdir $tmp.before.up
 
 # Copy up all files
-- 
2.25.1




^ permalink raw reply related	[flat|nested] 2+ messages in thread

* Re: [PATCH] overlay/071: Don't compare inode numbers in lower overlay and nested overlay
  2020-10-03  3:37 [PATCH] overlay/071: Don't compare inode numbers in lower overlay and nested overlay Xiao Yang
@ 2020-10-03  9:57 ` Amir Goldstein
  0 siblings, 0 replies; 2+ messages in thread
From: Amir Goldstein @ 2020-10-03  9:57 UTC (permalink / raw)
  To: Xiao Yang; +Cc: fstests

On Sat, Oct 3, 2020 at 6:57 AM Xiao Yang <yangx.jy@cn.fujitsu.com> wrote:
>
> 1) If underlying filesystem is ext4, the lower overlay inodes do not
>    have the MSB set (e.g. file ino 8590721028 = 0x2000C0004) because
>    ext4 has a known inode number limit of 32bit (see ovl_can_decode_fh).
> 2) With nested xino feature, the nested overlay inodes have the MSB set
>    (e.g. file ino 9223372045445496836  = 0x80000002000C0004).
> It is expected different inode numbers which casue the failure of
> overlay/071, so fix this failure by removing the unneeded comparision.
>
> Suggested-by: Amir Goldstein <amir73il@gmail.com>
> Signed-off-by: Xiao Yang <yangx.jy@cn.fujitsu.com>

Reviewed-by: Amir Goldstein <amir73il@gmail.com>

In case someone is wondering why I added this comparison
to the test in the first place - I have no idea.
Maybe it is a remnant of a sanity test while debugging.
There is no comparison between "lower" to "overlay" inode numbers
in any of the variants of test overlay/017 this test is forked from.
There is no requirement for those inode numbers to be the same.

> ---
>  tests/overlay/071 | 6 +-----
>  1 file changed, 1 insertion(+), 5 deletions(-)
>
> diff --git a/tests/overlay/071 b/tests/overlay/071
> index ac2324c8..90770936 100755
> --- a/tests/overlay/071
> +++ b/tests/overlay/071
> @@ -194,12 +194,8 @@ mount_dirs
>  record_inode_numbers $SCRATCH_MNT/lowertestdir $tmp.lower.lo
>  record_inode_numbers $SCRATCH_MNT/uppertestdir $tmp.lower.up
>
> -# Compare inode numbers in lower overlay vs. nested overlay
> -# With nested xino lower/lower, all inode numbers overflow xino bits and
> -# d_ino/i_ino in nested overlay are the same as in lower overlay.
> -check_inode_numbers $lowertestdir $tmp.lower.lo $tmp.before.lo
> -
>  # Record inode numbers before copy up from nested upper
> +record_inode_numbers $lowertestdir $tmp.before.lo
>  record_inode_numbers $uppertestdir $tmp.before.up
>
>  # Copy up all files
> --
> 2.25.1
>
>
>

^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2020-10-03  9:57 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-10-03  3:37 [PATCH] overlay/071: Don't compare inode numbers in lower overlay and nested overlay Xiao Yang
2020-10-03  9:57 ` Amir Goldstein

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.