[Devel] [PATCH RH7 4/4] vfs: Remove second variable named error in __dentry_path
Pavel Tikhomirov
ptikhomirov at virtuozzo.com
Wed Jun 17 07:05:13 PDT 2015
From: "Eric W. Biederman" <ebiederm at xmission.com>
Port mainstream patch:
commit a8323da0366d3398eda62741d2ac1130c8a172ed
Author: Eric W. Biederman <ebiederm at xmission.com>
Date: Mon Jan 20 15:43:25 2014 -0800
vfs: Remove second variable named error in __dentry_path
In commit 232d2d60aa5469bb097f55728f65146bd49c1d25
Author: Waiman Long <Waiman.Long at hp.com>
Date: Mon Sep 9 12:18:13 2013 -0400
dcache: Translating dentry into pathname without taking rename_lock
The __dentry_path locking was changed and the variable error was
intended to be moved outside of the loop. Unfortunately the inner
declaration of error was not removed. Resulting in a version of
__dentry_path that will never return an error.
Remove the problematic inner declaration of error and allow
__dentry_path to return errors once again.
Cc: stable at vger.kernel.org
Cc: Waiman Long <Waiman.Long at hp.com>
Signed-off-by: "Eric W. Biederman" <ebiederm at xmission.com>
Signed-off-by: Al Viro <viro at zeniv.linux.org.uk>
Signed-off-by: Pavel Tikhomirov <ptikhomirov at virtuozzo.com>
---
fs/dcache.c | 1 -
1 file changed, 1 deletion(-)
diff --git a/fs/dcache.c b/fs/dcache.c
index ad4acc4..da460df 100644
--- a/fs/dcache.c
+++ b/fs/dcache.c
@@ -3121,7 +3121,6 @@ static char *__dentry_path(struct dentry *d, char *buf, int buflen)
read_seqbegin_or_lock(&rename_lock, &seq);
while (!IS_ROOT(dentry)) {
struct dentry *parent = dentry->d_parent;
- int error;
prefetch(parent);
error = prepend_name(&end, &len, &dentry->d_name);
--
1.9.3
More information about the Devel
mailing list