android_kernel_motorola_sm6375/include
Repository files (latest commit first)
Filename Latest commit message Latest commit date
Pavel Tikhomirov ce750f697c move_mount: allow to add a mount into an existing group
[ Upstream commit 9ffb14ef61bab83fa818736bf3e7e6b6e182e8e2 ]

Previously a sharing group (shared and master ids pair) can be only
inherited when mount is created via bindmount. This patch adds an
ability to add an existing private mount into an existing sharing group.

With this functionality one can first create the desired mount tree from
only private mounts (without the need to care about undesired mount
propagation or mount creation order implied by sharing group
dependencies), and next then setup any desired mount sharing between
those mounts in tree as needed.

This allows CRIU to restore any set of mount namespaces, mount trees and
sharing group trees for a container.

We have many issues with restoring mounts in CRIU related to sharing
groups and propagation:
- reverse sharing groups vs mount tree order requires complex mounts
  reordering which mostly implies also using some temporary mounts
(please see https://lkml.org/lkml/2021/3/23/569 for more info)

- mount() syscall creates tons of mounts due to propagation
- mount re-parenting due to propagation
- "Mount Trap" due to propagation
- "Non Uniform" propagation, meaning that with different tricks with
  mount order and temporary children-"lock" mounts one can create mount
  trees which can't be restored without those tricks
(see https://www.linuxplumbersconf.org/event/7/contributions/640/)

With this new functionality we can resolve all the problems with
propagation at once.

Link: https://lore.kernel.org/r/20210715100714.120228-1-ptikhomirov@virtuozzo.com
Cc: Eric W. Biederman <ebiederm@xmission.com>
Cc: Alexander Viro <viro@zeniv.linux.org.uk>
Cc: Christian Brauner <christian.brauner@ubuntu.com>
Cc: Mattias Nissler <mnissler@chromium.org>
Cc: Aleksa Sarai <cyphar@cyphar.com>
Cc: Andrei Vagin <avagin@gmail.com>
Cc: linux-fsdevel@vger.kernel.org
Cc: linux-api@vger.kernel.org
Cc: lkml <linux-kernel@vger.kernel.org>
Co-developed-by: Andrei Vagin <avagin@gmail.com>
Acked-by: Christian Brauner <christian.brauner@ubuntu.com>
Signed-off-by: Pavel Tikhomirov <ptikhomirov@virtuozzo.com>
Signed-off-by: Andrei Vagin <avagin@gmail.com>
Signed-off-by: Christian Brauner <christian.brauner@ubuntu.com>
Stable-dep-of: cffd0441872e ("use uniform permission checks for all mount propagation changes")
Signed-off-by: Sasha Levin <sashal@kernel.org>
2025-08-28 16:21:32 +02:00
..
acpi ACPICA: Avoid sequence overread in call to strncmp() 2025-06-27 11:02:52 +01:00
asm-generic
clocksource
crypto
drm drm/sched: Increment job count before swapping tail spsc queue 2025-07-17 18:25:03 +02:00
dt-bindings
keys
kvm
linux net: vlan: Replace BUG() with WARN_ON_ONCE() in vlan_dev_* stubs 2025-08-28 16:21:27 +02:00
math-emu
media
misc
net wifi: cfg80211: Fix interface type validation 2025-08-28 16:21:26 +02:00
pcmcia
ras
rdma RDMA/core: Create and destroy counters in the ib_core 2025-07-17 18:24:59 +02:00
scsi
soc
sound ALSA: pcm: Fix race of buffer access at PCM OSS layer 2025-06-04 14:32:35 +02:00
target
trace erofs: remove unused trace event erofs_destroy_inode 2025-06-27 11:02:57 +01:00
uapi move_mount: allow to add a mount into an existing group 2025-08-28 16:21:32 +02:00
vdso
video
xen xen/mcelog: Add __nonstring annotations for unterminated strings 2025-05-02 07:39:09 +02:00