mirror of
https://github.com/Fishwaldo/Star64_linux.git
synced 2025-07-05 22:12:16 +00:00
procfs: Don't cache a pid in the root inode.
Now that we have s_fs_info pointing to our pid namespace the original reason for the proc root inode having a struct pid is gone. Caching a pid in the root inode has led to some complicated code. Now that we don't need the struct pid, just remove it. Signed-off-by: Eric W. Biederman <ebiederm@xmission.com>
This commit is contained in:
parent
e656d8a6f7
commit
ae06c7c83f
2 changed files with 1 additions and 18 deletions
|
@ -100,7 +100,6 @@ static struct dentry *proc_mount(struct file_system_type *fs_type,
|
|||
int err;
|
||||
struct super_block *sb;
|
||||
struct pid_namespace *ns;
|
||||
struct proc_inode *ei;
|
||||
char *options;
|
||||
|
||||
if (flags & MS_KERNMOUNT) {
|
||||
|
@ -130,13 +129,6 @@ static struct dentry *proc_mount(struct file_system_type *fs_type,
|
|||
sb->s_flags |= MS_ACTIVE;
|
||||
}
|
||||
|
||||
ei = PROC_I(sb->s_root->d_inode);
|
||||
if (!ei->pid) {
|
||||
rcu_read_lock();
|
||||
ei->pid = get_pid(find_pid_ns(1, ns));
|
||||
rcu_read_unlock();
|
||||
}
|
||||
|
||||
return dget(sb->s_root);
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue