On Tue, May 27, 2025 at 10:57:05AM +0200, Amir Goldstein wrote: > On Sun, May 25, 2025 at 8:27 PM Kent Overstreet > <kent.overstreet@xxxxxxxxx> wrote: > > > > On Sat, May 24, 2025 at 03:01:44PM +0200, Amir Goldstein wrote: > > > On Fri, May 23, 2025 at 11:10 PM Kent Overstreet > > > <kent.overstreet@xxxxxxxxx> wrote: > > > > > > > > On Fri, May 23, 2025 at 10:30:16PM +0200, Amir Goldstein wrote: > > > > > > > > That makes fstests generic/631 pass. > > > > > > Yes, that is not very surprising. > > > I meant if you could help test that: > > > > > > 1. mounting case folder upperdir/lowerdir fails > > > 2. lookup a case folder subdir fails > > > 3. lookup in a dir that was empty and became case folder while ovl was > > > mounted fails > > > > > > For me, I do not have any setup with case folding subtrees > > > so testing those use cases would take me time and > > > I think that you must have tested all those scenarios with your patch set? > > > and maybe already have some fstests for them? > > > > Unmount fauls after I test an overlayfs with a casefold subdir: > > > > Testing an overlayfs on a casefold fs with non-casefolded dirs > > Test using casefolded dir - should fail > > overlayfs: failed to resolve '/mnt/casefold': -2 > > mount: /mnt/merged: special device overlay does not exist. > > dmesg(1) may have more information after failed mount system call. > > Test is using the wrong path: > > > + echo "Test using casefolded dir - should fail" > + ! mount -t overlay -o > lowerdir=/mnt/lower,upperdir=/mnt/upper,workdir=/mnt/work overlay > /mnt/merged > + ! mount -t overlay -o > lowerdir=/mnt/casefold,upperdir=/mnt/casefold,workdir=/mnt/work > overlay /mnt/merged > > There is no "/mnt/casefold" *nod* > > Test using a dir with a casefold subdir - should mount > > overlayfs: upperdir is in-use as upperdir/workdir of another mount, accessing files from both mounts will result in undefined behavior. > > overlayfs: workdir is in-use as upperdir/workdir of another mount, accessing files from both mounts will result in undefined behavior. > > Those warnings are because you have a stray mount command above: > + echo "Test using casefolded dir - should fail" > + ! mount -t overlay -o > lowerdir=/mnt/lower,upperdir=/mnt/upper,workdir=/mnt/work overlay > /mnt/merged > > So a mount already exists. leftover? *snort* - -ENOCAFFEINE, I presume. The new warning doesn't fire after the last mount. ls: cannot access '/mnt/merged/casefold': Object is remote But nothing in dmesg. Adding a printk to ovl_mount_dir_check() shows that it's never called for the 'ls /mnt/merged/casefold' call.