proc: delete unnecessary variable in proc_alloc_inode()
diff mbox series

Message ID 20181203164015.GA6904@avx2
State In Next
Commit 230f72e9f6dc7b22ee92dc03a393429447b4395c
Headers show
Series
  • proc: delete unnecessary variable in proc_alloc_inode()
Related show

Commit Message

Alexey Dobriyan Dec. 3, 2018, 4:40 p.m. UTC
Signed-off-by: Alexey Dobriyan <adobriyan@gmail.com>
---

 fs/proc/inode.c |    4 +---
 1 file changed, 1 insertion(+), 3 deletions(-)

Patch
diff mbox series

--- a/fs/proc/inode.c
+++ b/fs/proc/inode.c
@@ -59,7 +59,6 @@  static struct kmem_cache *pde_opener_cache __ro_after_init;
 static struct inode *proc_alloc_inode(struct super_block *sb)
 {
 	struct proc_inode *ei;
-	struct inode *inode;
 
 	ei = kmem_cache_alloc(proc_inode_cachep, GFP_KERNEL);
 	if (!ei)
@@ -71,8 +70,7 @@  static struct inode *proc_alloc_inode(struct super_block *sb)
 	ei->sysctl = NULL;
 	ei->sysctl_entry = NULL;
 	ei->ns_ops = NULL;
-	inode = &ei->vfs_inode;
-	return inode;
+	return &ei->vfs_inode;
 }
 
 static void proc_i_callback(struct rcu_head *head)