[PATCHES][RFC][CFR] mount-related stuff

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

 



	The next pile of mount massage; it will grow - there will be
further modifications, as well as fixes and documentation, but this is
the subset I've got in more or less settled form right now.

	Review and testing would be very welcome.

	This series (-rc1-based) sits in
git://git.kernel.org/pub/scm/linux/kernel/git/viro/vfs.git #work.mount
individual patches in followups.

	Rough overview:

Part 1: trivial cleanups and helpers:

1) copy_tree(): don't set ->mnt_mountpoint on the root of copy
	Ancient bogosity, fortunately harmless, but confusing.
2) constify mnt_has_parent()
3) pnode: lift peers() into pnode.h
4) new predicate: mount_is_ancestor()
	Incidentally, I wonder if the "early bail out on move
of anon into the same anon" was not due to (now eliminated)
corner case in loop detection...  Christian?
5) constify is_local_mountpoint()
6) new predicate: anon_ns_root(mount)
7) dissolve_on_fput(): use anon_ns_root()
8) don't set MNT_LOCKED on parentless mounts
	Simplify the rules for MNT_LOCKED
9) clone_mnt(): simplify the propagation-related logics
	... making it somewhat easier to verify correctness wrt
propagation graph invariants.
10) do_umount(): simplify the "is it still mounted" checks
	it needs to check that mount is ours and it has gradually
grown an equivalent of such check, but it's badly obfuscated.

Part 2: (somewhat of a side story) restore the machinery for long-term
mounts from accumulated bitrot.

11) sanitize handling of long-term internal mounts

Part 3: propagate_umount() rewrite (posted last cycle)

12) Rewrite of propagate_umount()

Part 4: untangling do_move_mount()/attach_recursive_mnt().  This is one area that
will definitely grow - reliable avoidance of having multiple mounts with the same
parent/mountpoint pair will go in there.

13) attach_mnt(): expand in attach_recursive_mnt(), then lose the flag argument
14) do_move_mount(): take dropping the old mountpoint into attach_recursive_mnt()
15) get rid of mnt_set_mountpoint_beneath()
16) make commit_tree() usable in same-namespace move case
17) attach_recursive_mnt(): unify the mnt_change_mountpoint() logics
18) attach_recursive_mnt(): pass destination mount in all cases
19) attach_recursive_mnt(): get rid of flags entirely
20) do_move_mount(): get rid of 'attached' flag

Part 5: change locking for expiry lists.
21) attach_recursive_mnt(): remove from expiry list on move
22) take ->mnt_expire handling under mount_lock [read_seqlock_excl]

Part 6: struct mountpoint massage.
23) pivot_root(): reorder tree surgeries, collapse unhash_mnt() and put_mountpoint()
24) combine __put_mountpoint() with unhash_mnt()
25) get rid of mountpoint->m_count

Part 7: regularize mount refcounting a bit
26) don't have mounts pin their parents




[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