summaryrefslogtreecommitdiffstats
path: root/fs/namei.c
diff options
context:
space:
mode:
authorAl Viro <viro@zeniv.linux.org.uk>2015-12-06 03:06:33 +0100
committerAl Viro <viro@zeniv.linux.org.uk>2015-12-07 03:18:27 +0100
commite1a63bbc40c00d5198b1c1d133b139e962f5e872 (patch)
tree0c139b3fed7a93e2ee97e1c4d7dd40ae77a5c84d /fs/namei.c
parentnamei.c: take "jump to root" into a new helper (diff)
downloadlinux-e1a63bbc40c00d5198b1c1d133b139e962f5e872.tar.xz
linux-e1a63bbc40c00d5198b1c1d133b139e962f5e872.zip
restore_nameidata(): no need to clear now->stack
microoptimization: in all callers *now is in the frame we are about to leave. Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
Diffstat (limited to 'fs/namei.c')
-rw-r--r--fs/namei.c4
1 files changed, 1 insertions, 3 deletions
diff --git a/fs/namei.c b/fs/namei.c
index 0baf64b116bd..9e102aca3480 100644
--- a/fs/namei.c
+++ b/fs/namei.c
@@ -534,10 +534,8 @@ static void restore_nameidata(void)
current->nameidata = old;
if (old)
old->total_link_count = now->total_link_count;
- if (now->stack != now->internal) {
+ if (now->stack != now->internal)
kfree(now->stack);
- now->stack = now->internal;
- }
}
static int __nd_alloc_stack(struct nameidata *nd)