]> git.baikalelectronics.ru Git - kernel.git/commit
proc: Remove the now unnecessary internal mount of proc
authorEric W. Biederman <ebiederm@xmission.com>
Thu, 20 Feb 2020 14:08:20 +0000 (08:08 -0600)
committerEric W. Biederman <ebiederm@xmission.com>
Fri, 28 Feb 2020 18:06:14 +0000 (12:06 -0600)
commit5cf49498f396cfb245aad1a9e1f7914ccb5f2b24
tree1da3b3be89a43a37d06797ffbc5720ed116fad25
parent0769af4c413966b2232c70ba8f7af3457abe7542
proc: Remove the now unnecessary internal mount of proc

There remains no more code in the kernel using pids_ns->proc_mnt,
therefore remove it from the kernel.

The big benefit of this change is that one of the most error prone and
tricky parts of the pid namespace implementation, maintaining kernel
mounts of proc is removed.

In addition removing the unnecessary complexity of the kernel mount
fixes a regression that caused the proc mount options to be ignored.
Now that the initial mount of proc comes from userspace, those mount
options are again honored.  This fixes Android's usage of the proc
hidepid option.

Reported-by: Alistair Strachan <astrachan@google.com>
Fixes: 75920887dfd3 ("proc: Convert proc_mount to use mount_ns.")
Signed-off-by: "Eric W. Biederman" <ebiederm@xmission.com>
fs/proc/root.c
include/linux/pid_namespace.h
include/linux/proc_ns.h
kernel/pid.c
kernel/pid_namespace.c