diff options
| author | Al Viro <[email protected]> | 2023-09-20 03:52:58 +0000 |
|---|---|---|
| committer | Al Viro <[email protected]> | 2024-02-25 07:10:32 +0000 |
| commit | 47458802f6606f652cd0f6dc38cd52ce60ec0145 (patch) | |
| tree | 6f3b9617c9b8cb9b649d1768938875fb6a6812ed /fs/proc/base.c | |
| parent | nfs: fix UAF on pathwalk running into umount (diff) | |
| download | kernel-47458802f6606f652cd0f6dc38cd52ce60ec0145.tar.gz kernel-47458802f6606f652cd0f6dc38cd52ce60ec0145.zip | |
procfs: move dropping pde and pid from ->evict_inode() to ->free_inode()
that keeps both around until struct inode is freed, making access
to them safe from rcu-pathwalk
Acked-by: Christian Brauner <[email protected]>
Signed-off-by: Al Viro <[email protected]>
Diffstat (limited to 'fs/proc/base.c')
| -rw-r--r-- | fs/proc/base.c | 2 |
1 files changed, 0 insertions, 2 deletions
diff --git a/fs/proc/base.c b/fs/proc/base.c index 98a031ac2648..18550c071d71 100644 --- a/fs/proc/base.c +++ b/fs/proc/base.c @@ -1878,8 +1878,6 @@ void proc_pid_evict_inode(struct proc_inode *ei) hlist_del_init_rcu(&ei->sibling_inodes); spin_unlock(&pid->lock); } - - put_pid(pid); } struct inode *proc_pid_make_inode(struct super_block *sb, |
