From: Al Viro Date: Fri, 30 Mar 2012 18:39:15 +0000 (-0400) Subject: untangling do_lookup() - merge d_alloc_and_lookup() callers X-Git-Tag: upstream/snapshot3+hdmi~7779^2~4 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=a6ecdfcfba9392f469992dd6016ceafb3ea62123;p=platform%2Fadaptation%2Frenesas_rcar%2Frenesas_kernel.git untangling do_lookup() - merge d_alloc_and_lookup() callers Signed-off-by: Al Viro --- diff --git a/fs/namei.c b/fs/namei.c index a0f9a02..1d60fdf 100644 --- a/fs/namei.c +++ b/fs/namei.c @@ -1188,12 +1188,12 @@ retry: } if (!d_invalidate(dentry)) { dput(dentry); - dentry = d_alloc_and_lookup(parent, name, nd); + dentry = NULL; } } - } else if (!dentry) { - dentry = d_alloc_and_lookup(parent, name, nd); } + if (!dentry) + dentry = d_alloc_and_lookup(parent, name, nd); l: mutex_unlock(&dir->i_mutex); if (IS_ERR(dentry))