Re: [PATCH 1/4] fix the softlockups in attach_recursive_mnt()

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Sat, Aug 16, 2025 at 12:34:14AM +0100, Al Viro wrote:
> In case when we mounting something on top of a large stack of overmounts,
> all of them being peers of each other, we get quadratic time by the
> depth of overmount stack.  Easily fixed by doing commit_tree() before
> reparenting the overmount; simplifies commit_tree() as well - it doesn't
> need to skip the already mounted stuff that had been reparented on top
> of the new mounts.
> 
> Since we are holding mount_lock through both reparenting and call of
> commit_tree(), the order does not matter from the mount hash point
> of view.
> 
> Reported-by: "Lai, Yi" <yi1.lai@xxxxxxxxxxxxxxx>
> Tested-by: "Lai, Yi" <yi1.lai@xxxxxxxxxxxxxxx>
> Fixes: 663206854f02 "copy_tree(): don't link the mounts via mnt_list"
> Signed-off-by: Al Viro <viro@xxxxxxxxxxxxxxxxxx>
> ---

Reviewed-by: Christian Brauner <brauner@xxxxxxxxxx>




[Index of Archives]     [Linux Ext4 Filesystem]     [Union Filesystem]     [Filesystem Testing]     [Ceph Users]     [Ecryptfs]     [NTFS 3]     [AutoFS]     [Kernel Newbies]     [Share Photos]     [Security]     [Netfilter]     [Bugtraq]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux Cachefs]     [Reiser Filesystem]     [Linux RAID]     [NTFS 3]     [Samba]     [Device Mapper]     [CEPH Development]

  Powered by Linux