From 311c31aed8a4208d3a0d2d68ea9b833e262bc8a9 Mon Sep 17 00:00:00 2001 From: Linus Torvalds Date: Fri, 22 Mar 2013 11:44:04 -0700 Subject: [PATCH] --- yaml --- r: 361607 b: refs/heads/master c: 51f0885e5415b4cc6535e9cdcc5145bfbc134353 h: refs/heads/master i: 361605: 39a03bdb35d7ba9be570d368c59df266a73987ab 361603: 15917f66bc7822be67f51a72f0962f4587bef3fc 361599: 445f1b17339f46853e985191abfbc3f09f065cd8 v: v3 --- [refs] | 2 +- trunk/fs/proc/inode.c | 6 +++--- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/[refs] b/[refs] index a0f297555549..001d503f6ea2 100644 --- a/[refs] +++ b/[refs] @@ -1,2 +1,2 @@ --- -refs/heads/master: 9217cbb8df31c10efc96362227b2ebdbb9fe996c +refs/heads/master: 51f0885e5415b4cc6535e9cdcc5145bfbc134353 diff --git a/trunk/fs/proc/inode.c b/trunk/fs/proc/inode.c index a86aebc9ba7c..869116c2afbe 100644 --- a/trunk/fs/proc/inode.c +++ b/trunk/fs/proc/inode.c @@ -446,9 +446,10 @@ static const struct file_operations proc_reg_file_ops_no_compat = { struct inode *proc_get_inode(struct super_block *sb, struct proc_dir_entry *de) { - struct inode *inode = iget_locked(sb, de->low_ino); + struct inode *inode = new_inode_pseudo(sb); - if (inode && (inode->i_state & I_NEW)) { + if (inode) { + inode->i_ino = de->low_ino; inode->i_mtime = inode->i_atime = inode->i_ctime = CURRENT_TIME; PROC_I(inode)->pde = de; @@ -476,7 +477,6 @@ struct inode *proc_get_inode(struct super_block *sb, struct proc_dir_entry *de) inode->i_fop = de->proc_fops; } } - unlock_new_inode(inode); } else pde_put(de); return inode;